Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add blank '--prefix=' option to protect '--home' specification to fix #49 #50

Merged
merged 2 commits into from Sep 9, 2015
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
6 changes: 5 additions & 1 deletion lib/eupspkg.sh
Expand Up @@ -1122,7 +1122,11 @@ PRODUCTS_ROOT=${PRODUCTS_ROOT:-"$(eups path 0)/$(eups flavor)"} # Root director
PREFIX=${PREFIX:-"$PRODUCTS_ROOT/$PRODUCT/$VERSION"} # Directory to which the product will be installed

CONFIGURE_OPTIONS=${CONFIGURE_OPTIONS:-"--prefix $PREFIX"} # Options passed to ./configure. Note that --prefix is NOT passed separately!
PYSETUP_INSTALL_OPTIONS=${PYSETUP_INSTALL_OPTIONS:-"--home $PREFIX"} # Options passed to setup.py install. Note that --home is NOT passed separately!
# The following '--prefix=' is meant to clear any pre-set 'prefix' from a distutils.cfg or ~/.pydistutils.cfg
# We can only specify a value for either --home XOR --prefix, not both.
# So if we specify --home, we have to blank out --prefix:
# See, e.g., http://stackoverflow.com/questions/4495120/combine-user-with-prefix-error-with-setup-py-install
PYSETUP_INSTALL_OPTIONS=${PYSETUP_INSTALL_OPTIONS:-"--home $PREFIX --prefix="} # Options passed to setup.py install. Note that --home is NOT passed separately!
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a strange looking construct. I think it deserves a comment explanating why this is nessicary and/or a link back to the SO topic.


export CC=${CC:-cc} # Autoconf prefers to look for gcc first, and the proper thing is to default to cc. This helps on Darwin.
export CXX=${CXX:-c++} # Autoconf prefers to look for gcc first, and the proper thing is to default to c++. This helps on Darwin.
Expand Down