1
0
mirror of https://github.com/ansible/awx.git synced 2024-11-02 09:51:09 +03:00

Merge pull request #372 from jlaska/makefile_requirements_adjustments

Simplify Makefile requirements targets
This commit is contained in:
James Laska 2015-08-12 13:34:25 -04:00
commit 94c2906810

View File

@ -82,7 +82,8 @@ RPM_NVR = $(NAME)-$(VERSION)-$(RELEASE)$(RPM_DIST)
MOCK_BIN ?= mock MOCK_BIN ?= mock
MOCK_CFG ?= MOCK_CFG ?=
.PHONY: clean rebase push requirements requirements_dev requirements_jenkins requirements_post \ .PHONY: clean rebase push requirements requirements_dev requirements_jenkins \
real-requirements real-requirements_dev real-requirements_jenkins \
develop refresh adduser syncdb migrate dbchange dbshell runserver celeryd \ develop refresh adduser syncdb migrate dbchange dbshell runserver celeryd \
receiver test test_coverage coverage_html ui_analysis_report test_jenkins dev_build \ receiver test test_coverage coverage_html ui_analysis_report test_jenkins dev_build \
release_build release_clean sdist rpmtar mock-rpm mock-srpm rpm-sign \ release_build release_clean sdist rpmtar mock-rpm mock-srpm rpm-sign \
@ -138,32 +139,23 @@ rebase:
push: push:
git push origin master git push origin master
requirements_post: # Install runtime, development and jenkins requirements
touch awx/lib/site-packages/oslo/__init__.py requirements requirements_dev requirements_jenkins: %: real-% awx/lib/site-packages/oslo/__init__.py awx/lib/site-packages/dogpile/__init__.py
touch awx/lib/site-packages/dogpile/__init__.py
# Create missing __init__.py files
awx/lib/site-packages/%/__init__.py:
touch $@
# Install third-party requirements needed for development environment. # Install third-party requirements needed for development environment.
requirements: real-requirements:
(pip install -r requirements/requirements.txt -t awx/lib/site-packages/); pip install -r requirements/requirements.txt --target awx/lib/site-packages/ --ignore-installed
@if [ "$(VIRTUAL_ENV)" ]; then \
$(PYTHON) fix_virtualenv_setuptools.py; \
fi
$(MAKE) requirements_post
requirements_dev: real-requirements_dev: real-requirements
(cat requirements/requirements.txt requirements/requirements_dev.txt > /tmp/req_dev.txt); pip install -r requirements/requirements_dev.txt --target awx/lib/site-packages/ --ignore-installed
(pip install -r /tmp/req_dev.txt -t awx/lib/site-packages/);
@if [ "$(VIRTUAL_ENV)" ]; then \
$(PYTHON) fix_virtualenv_setuptools.py; \
fi
$(MAKE) requirements_post
# Install third-party requirements needed for running unittests in jenkins # Install third-party requirements needed for running unittests in jenkins
requirements_jenkins: requirements real-requirements_jenkins: real-requirements
(pip install -r requirements/requirements_jenkins.txt); pip install -r requirements/requirements_jenkins.txt
@if [ "$(VIRTUAL_ENV)" ]; then \
$(PYTHON) fix_virtualenv_setuptools.py; \
fi
npm install csslint jshint npm install csslint jshint
# "Install" ansible-tower package in development mode. # "Install" ansible-tower package in development mode.