forked from pycassa/pycassa
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request pycassa#127 from caruccio/bb29fe65d1421cfff613dbbf…
…a8ffa0fbe2e01f89 RPM Install script to build under CentOS
- Loading branch information
Showing
2 changed files
with
46 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
python setup.py install --single-version-externally-managed --root="$RPM_BUILD_ROOT" --record=INSTALLED_FILES | ||
|
||
# Add .pyo files generated on CentOS 5.x | ||
# This is a workaround until someone comes with a better fix, like avoiding | ||
# /usr/lib/rpm/brp-python-bytecompile to run or convincing people that CentOS is pure evil. | ||
rm -f INSTALLED_PYO_FILES | ||
(cd "$RPM_BUILD_ROOT" | ||
find -type f -name '*.pyc' | cut -b2-|sed -e 's/pyc$/pyo/' | while read pyo | ||
do | ||
if [ -e "$pyo" ]; then | ||
echo "$pyo" >> INSTALLED_PYO_FILES | ||
fi | ||
done) | ||
|
||
if [ -e INSTALLED_PYO_FILES ]; then | ||
sort -u INSTALLED_PYO_FILES >> INSTALLED_FILES | ||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters