Commit 0f6f00e7 authored by gsell's avatar gsell

refactor variable names according to changes in Pmodules/0.99.15 in...

refactor variable names according to changes in Pmodules/0.99.15 in build-scripts of group 'Programming'
parent b674162f
......@@ -8,7 +8,7 @@ pbuild::configure() {
export LDFLAGS="-L${OPENSSL_LIBRARY_DIR}"
export CPPFLAGS="-fPIC -I${OPENSSL_INCLUDE_DIR} -I${OPENSSL_INCLUDE_DIR}/openssl"
export LD_LIBRARY_PATH+=":${PREFIX}/lib"
"${MODULE_SRCDIR}"/configure \
"${SRC_DIR}"/configure \
--prefix="${PREFIX}" \
--enable-shared \
|| exit 1
......@@ -22,7 +22,7 @@ pbuild::post_install() {
ln -fs "${PREFIX}/include/python${V%.*}m" "${PREFIX}/include/python"
ln -fs "${PREFIX}/include/python${V%.*}m" "${PREFIX}/include/python${V%.*}"
PATH+=":${PREFIX}/bin"
cd "${BUILD_BLOCK_DIR}"
cd "${BUILDBLOCK_DIR}"
"${PREFIX}/bin/python" 'get-pip.py'
pip${V_MAJOR} install numpy
pip${V_MAJOR} install scipy
......
......@@ -5,10 +5,10 @@ SOURCE_URL="ftp://ftp.tcl.tk/pub/tcl/tcl8_6/tcl$V-src.tar.gz"
pbuild::configure() {
case ${OS} in
Linux )
srcdir="${MODULE_SRCDIR}/unix"
srcdir="${SRC_DIR}/unix"
;;
Darwin )
srcdir="${MODULE_SRCDIR}/macosx"
srcdir="${SRC_DIR}/macosx"
;;
esac
"${srcdir}"/configure \
......
......@@ -5,10 +5,10 @@ SOURCE_URL="ftp://ftp.tcl.tk/pub/tcl/tcl8_6/tk$V-src.tar.gz"
pbuild::configure() {
case ${OS} in
Linux )
srcdir="${MODULE_SRCDIR}/unix"
srcdir="${SRC_DIR}/unix"
;;
Darwin )
srcdir="${MODULE_SRCDIR}/macosx"
srcdir="${SRC_DIR}/macosx"
C_INCLUDE_PATH+=":/opt/local/include"
LIBRARY_PATH+=":/opt/local/lib"
;;
......
......@@ -3,7 +3,7 @@
SOURCE_URL="https://ftp.gnu.org/gnu/$P/$P-$V.tar.gz"
pbuild::configure() {
"${MODULE_SRCDIR}"/configure \
"${SRC_DIR}"/configure \
--prefix="${PREFIX}" \
|| exit 1
}
......
......@@ -3,7 +3,7 @@
SOURCE_URL="https://ftp.gnu.org/gnu/$P/$P-$V.tar.gz"
pbuild::configure() {
"${MODULE_SRCDIR}"/configure \
"${SRC_DIR}"/configure \
--prefix="${PREFIX}" \
|| exit 1
}
......
......@@ -3,7 +3,7 @@
SOURCE_URL="http://ftp.gnu.org/gnu/binutils/$P-$V.tar.gz"
pbuild::configure() {
"${MODULE_SRCDIR}"/configure \
"${SRC_DIR}"/configure \
--prefix="${PREFIX}" \
|| exit 1
}
......
......@@ -11,7 +11,7 @@ Darwin )
esac
pbuild::configure() {
"${MODULE_SRCDIR}/bootstrap" --prefix="${PREFIX}" ${bootstrap_flags} --verbose
"${SRC_DIR}/bootstrap" --prefix="${PREFIX}" ${bootstrap_flags} --verbose
}
pbuild::add_to_group 'Programming'
......
......@@ -5,11 +5,11 @@ SOURCE_URL="https://ftp.gnu.org/gnu/gcc/$P-$V/$P-$V.tar.gz"
pbuild::patch_sources_Darwin() {
if (( V_MAJOR == 4 && V_MINOR <= 8 )) || \
(( V_MAJOR == 4 && V_MINOR == 9 && V_PATCHLVL < 4)); then
patch -p1 < "${BUILD_BLOCK_DIR}/${V_MAJOR}/non-dead-strip.patch"
patch -p1 < "${BUILD_BLOCK_DIR}/${V_MAJOR}/configure-as.patch"
patch -p1 < "${BUILDBLOCK_DIR}/${V_MAJOR}/non-dead-strip.patch"
patch -p1 < "${BUILDBLOCK_DIR}/${V_MAJOR}/configure-as.patch"
fi
if (( V_MAJOR == 5 )) || (( V_MAJOR == 6 )); then
patch -p1 < "${BUILD_BLOCK_DIR}/${V_MAJOR}/PR57438_avoiding_empty_function_bodies_and_trailing_labels.patch"
patch -p1 < "${BUILDBLOCK_DIR}/${V_MAJOR}/PR57438_avoiding_empty_function_bodies_and_trailing_labels.patch"
fi
}
......@@ -45,7 +45,7 @@ pbuild::configure() {
echo "Unsupported OS '${OS}'!"
;;
esac
"${MODULE_SRCDIR}"/configure \
"${SRC_DIR}"/configure \
--prefix="${PREFIX}" \
"${conf_args[@]}" \
|| exit 1
......
......@@ -11,12 +11,12 @@ DYLD_SOURCE_URL="http://opensource.apple.com/tarballs/dyld/dyld-${DYLD_VERSION}.
pbuild::patch_sources () {
find_patchdir() {
local -a patchdirs=()
patchdirs+=( "${BUILD_BLOCK_DIR}/${V}/patches.${OS}" )
patchdirs+=( "${BUILD_BLOCK_DIR}/${V}/patches" )
patchdirs+=( "${BUILD_BLOCK_DIR}/${V%.*}/patches.${OS}" )
patchdirs+=( "${BUILD_BLOCK_DIR}/${V%.*}/patches" )
patchdirs+=( "${BUILD_BLOCK_DIR}/${V%.*.*}/patches.${OS}" )
patchdirs+=( "${BUILD_BLOCK_DIR}/${V%.*.*}/patches" )
patchdirs+=( "${BUILDBLOCK_DIR}/${V}/patches.${OS}" )
patchdirs+=( "${BUILDBLOCK_DIR}/${V}/patches" )
patchdirs+=( "${BUILDBLOCK_DIR}/${V%.*}/patches.${OS}" )
patchdirs+=( "${BUILDBLOCK_DIR}/${V%.*}/patches" )
patchdirs+=( "${BUILDBLOCK_DIR}/${V%.*.*}/patches.${OS}" )
patchdirs+=( "${BUILDBLOCK_DIR}/${V%.*.*}/patches" )
for patchdir in "${patchdirs[@]}"; do
[[ -e "${patchdir}" ]] && return 0;
......@@ -32,8 +32,8 @@ pbuild::patch_sources () {
}
pbuild::post_prep() {
local -r DYLD_SRC_DIR="${PMODULES_TMPDIR}/dyld-${DYLD_VERSION}/src"
local -r CCTOOLS_SRC_DIR="${PMODULES_TMPDIR}/cctools-${CCTOOLS_VERSION}/src"
local -r DYLD_SRC_DIR="${TEMP_DIR}/dyld-${DYLD_VERSION}/src"
local -r CCTOOLS_SRC_DIR="${TEMP_DIR}/cctools-${CCTOOLS_VERSION}/src"
local source_file=''
pbuild::get_source source_file "${DYLD_SOURCE_URL}" "${PMODULES_DISTFILESDIR}" ||
......@@ -44,21 +44,21 @@ pbuild::post_prep() {
std::die 4 "cctools/${CCTOOLS_VERSION}: sourcecode not found."
pbuild::unpack "${source_file}" "${CCTOOLS_SRC_DIR}"
cd "${MODULE_SRCDIR}"
cd "${SRC_DIR}"
mkdir -p "include/mach-o"
rsync --archive "../../cctools-${CCTOOLS_VERSION}/src/include/mach-o/" "include/mach-o/"
rsync --archive "../../dyld-${DYLD_VERSION}/src/include/mach-o/" "include/mach-o/"
mkdir -p "include/llvm-c"
cp -v "${BUILD_BLOCK_DIR}/files/Disassembler.h" "include/llvm-c/"
cp -v "${BUILD_BLOCK_DIR}/files/lto.h" "include/llvm-c/"
cp -v "${BUILDBLOCK_DIR}/files/Disassembler.h" "include/llvm-c/"
cp -v "${BUILDBLOCK_DIR}/files/lto.h" "include/llvm-c/"
}
pbuild::configure() {
cp -v "${BUILD_BLOCK_DIR}/files/Makefile-${V_MAJOR}" "${MODULE_SRCDIR}/Makefile"
cp -v "${BUILDBLOCK_DIR}/files/Makefile-${V_MAJOR}" "${SRC_DIR}/Makefile"
}
pbuild::build() {
cd "${MODULE_SRCDIR}"
cd "${SRC_DIR}"
which $CC
make OTHER_CXXFLAGS="-std=c++11 -I$PWD/include" OTHER_LDFLAGS="-L/Applications/Xcode.app/Contents/Frameworks -lLTO"
}
......
......@@ -3,7 +3,7 @@
SOURCE_URL="https://ftp.gnu.org/gnu/$P/$P-$V.tar.gz"
pbuild::configure() {
"${MODULE_SRCDIR}"/configure \
"${SRC_DIR}"/configure \
--prefix="${PREFIX}" \
|| exit 1
}
......
......@@ -3,7 +3,7 @@
SOURCE_URL="https://ftp.gnu.org/gnu/$P/$P-$V.tar.bz2"
pbuild::configure() {
"${MODULE_SRCDIR}"/configure \
"${SRC_DIR}"/configure \
--prefix="${PREFIX}" \
|| exit 1
}
......
......@@ -3,7 +3,7 @@
SOURCE_URL="http://www.cpan.org/src/5.0/$P-$V.tar.gz"
pbuild::configure() {
"${MODULE_SRCDIR}"/configure.gnu \
"${SRC_DIR}"/configure.gnu \
--prefix="${PREFIX}" \
|| exit 1
}
......
......@@ -9,7 +9,7 @@ pbuild::build() {
}
pbuild::install() {
cd "${MODULE_SRCDIR}"
cd "${SRC_DIR}"
rsync --exclude=".info" --delete --verbose --archive . "${PREFIX}"
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment