-
-
Save int128/4498801 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
topdir="${WORKSPACE}/rpmbuild" | |
rpmdir="${topdir}/RPMS/$(uname -m)" | |
echo "%_topdir ${topdir}" > "${HOME}/.rpmmacros" | |
case "${TARGET}" in | |
*/httpd-*) | |
# patch for httpd-2.4.3 | |
tarball="${TARGET##*/}" | |
module="${tarball%.tar.*}" | |
curl -O "${TARGET}" | |
tar jxf "${tarball}" | |
sed -e 's,%{epoch}:,,g' -i "${module}/httpd.spec" | |
tar jcf "${tarball}" "${module}" | |
rpmbuild -tb "${tarball}" | |
;; | |
*.src.rpm) curl -O "${TARGET}" && rpmbuild --rebuild "${TARGET##*/}";; | |
*.tar.bz2) curl -O "${TARGET}" && rpmbuild -tb "${TARGET##*/}";; | |
*) echo 'environment variable TARGET must be set.'; exit 1;; | |
esac |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment