summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--remote/modules/systemd/systemd.build84
-rw-r--r--remote/modules/systemd/systemd.conf.scientific7
2 files changed, 62 insertions, 29 deletions
diff --git a/remote/modules/systemd/systemd.build b/remote/modules/systemd/systemd.build
index a5f9ef3b..358c59a6 100644
--- a/remote/modules/systemd/systemd.build
+++ b/remote/modules/systemd/systemd.build
@@ -5,7 +5,12 @@ fetch_source () {
download_untar "$REQUIRED_LIBKMOD_URL" "src/"
# Another nice hack for Scientific Linux - experimental.
- [ "$SYS_DISTRIBUTION" == "scientific" ] && download_untar "$REQUIRED_UTILLINUX_URL" "src/"
+ if [ "$SYS_DISTRIBUTION" == "scientific" ]; then
+ download_untar "$REQUIRED_UTILLINUX_URL" "src/" || perror "Cannot download util-linux!"
+ download_untar "$REQUIRED_M4_URL" "src/" || perror "Cannot download m4 version $REQUIRED_AUTOMAKE_VERSION!"
+ download_untar "$REQUIRED_AUTOCONF_URL" "src/" || perror "Cannot download autoconf version $REQUIRED_AUTOCONF_VERSION!"
+ download_untar "$REQUIRED_AUTOMAKE_URL" "src/" || perror "Cannot download automake version $REQUIRED_AUTOMAKE_VERSION!"
+ fi
# Patch PATH environment
sed -s -i -r 's#"/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin(:/sbin:/bin)?"#& ":/opt/openslx/usr/sbin:/opt/openslx/usr/bin:/opt/openslx/sbin:/opt/openslx/bin"#g' src/systemd-*/src/core/main.c
@@ -23,10 +28,12 @@ build () {
# Scientific Linux specials
if [ "$SYS_DISTRIBUTION" == "scientific" ]; then
+ pinfo "Scientific Linux detected ..."
+
# Utillinux stuff
- penfo "Building util-linux"
+ pinfo "Building util-linux"
cd "${MODULE_DIR}/src/util-linux-$REQUIRED_UTILLINUX_VERSION"
- ./configure --prefix=${MODULE_DIR}/build --exec-prefix=${MODULE_DIR}/build --disable-libuuid --disable-libmount \
+ ./configure --disable-libuuid --disable-libmount --without-ncurses \
--disable-mount --disable-losetup --disable-cytune --disable-fsck --disable-partx --disable-uuidd \
--disable-mountpoint --disable-fallocate --disable-unshare --disable-nsenter --disable-setpriv \
--disable-eject --disable-agetty --disable-cramfs --disable-bfs --disable-fdformat --disable-hwclock \
@@ -35,9 +42,36 @@ build () {
--disable-pg --disable-schedutils --disable-wall --disable-bash-completion \
|| perror "./configure util-linux failed."
make || perror "util-linux make failed."
- make install || perror "util-linux make install failed."
+ DESTDIR="${MODULE_BUILD_DIR}" make install || perror "util-linux make install failed."
+ cd - &> /dev/null
+
+ # Let's have some starting fun with m4, as we want systemd, which wants automake 1.13, which wants autoconf,
+ # which wants m4 ...
+ pinfo "Building m4 Version $REQUIRED_M4_VERSION."
+ cd "${MODULE_DIR}/src/m4-$REQUIRED_M4_VERSION"
+ ./configure || perror "./configure m4 failed."
+ make || perror "m4 make failed."
+ DESTDIR="${MODULE_BUILD_DIR}" make install || perror "m4 make install failed."
cd - &> /dev/null
+ # Let's have some starting fun with autoconf, as we want systemd, which wants automake 1.13, which wants
+ # autoconf 2.65 or better...
+ pinfo "Building autoconf Version $REQUIRED_AUTOCONF_VERSION."
+ cd "${MODULE_DIR}/src/autoconf-$REQUIRED_AUTOCONF_VERSION"
+ ./configure || perror "./configure autoconf failed."
+ make || perror "autoconf make failed."
+ DESTDIR="${MODULE_BUILD_DIR}" make install || perror "autoconf make install failed."
+ cd - &> /dev/null
+
+ # Now let's have some fun with automake, as config.log/systemd will whine later about SL's automake 1.11:
+ # AUTOMAKE='${SHELL} /root/tm-scripts/remote/modules/systemd/src/systemd-206/build-aux/missing automake-1.13'
+ pinfo "Building automake Version $REQUIRED_AUTOMAKE_VERSION."
+ cd "${MODULE_DIR}/src/automake-$REQUIRED_AUTOMAKE_VERSION"
+ ./configure || perror "./configure automake failed."
+ make || perror "automake make failed."
+ DESTDIR="${MODULE_BUILD_DIR}" make install || perror "automake make install failed."
+ cd - &> /dev/null
+exit
# patching configure for Scientific Linux - cave - ugly hack!
pinfo "Scientific Linux detected; patching systemd/configure..."
cd "${MODULE_DIR}/src/$REQUIRED_VERSION"
@@ -45,36 +79,30 @@ build () {
mv configure configure.orig
mv configure.patched configure
chmod +x configure
+
+ # For later compiling systemd
+ pinfo "-------------${MODULE_BUILD_DIR}--------------"
+ CPPFLAGS="-I${MODULE_BUILD_DIR}/usr/include/"
+ LDFLAGS="$LDFLAGS -L${MODULE_BUILD_DIR}/usr/lib/ -ldl"
+ # LD_LIBRARY_PATH="$LD_LIBRARY_PATH:${MODULE_BUILD_DIR}/usr/lib/"
cd - &> /dev/null
+ fi
- #build systemd for Scientific Linux
- pinfo "Building systemd"
- cd "${MODULE_DIR}/src/$REQUIRED_VERSION"
- pinfo "calling configure"
- ./configure --prefix=${MODULE_DIR}/build --exec-prefix=${MODULE_DIR}/build --datadir=${MODULE_DIR}/build \
- --disable-manpages --enable-split-usr --sysconfdir="/etc" --enable-gtk-doc-html=no --disable-nls \
+ #build systemd
+ pinfo "Building systemd"
+ cd "${MODULE_DIR}/src/$REQUIRED_VERSION"
+ pinfo "calling configure"
+pinfo "-------$LDFLAGS------------$CPPFLAGS-----------------$LD_LIBRARY_PATH---------------------------------------------------"
+ ./configure --disable-manpages --enable-split-usr --sysconfdir="/etc" --enable-gtk-doc-html=no --disable-nls \
--disable-microhttpd --disable-bootchart --disable-quotacheck --disable-hostnamed --disable-timedated \
--disable-localed --disable-coredump --disable-keymap --without-python --enable-blkid --enable-acl --enable-pam \
|| perror "configure failed."
- pinfo "calling make"
- make || perror "make failed."
- pinfo "calling make install"
- DESTDIR="${MODULE_BUILD_DIR}" make install || perror "make install failed."
- else
- #build systemd
- pinfo "Building systemd"
- cd "${MODULE_DIR}/src/$REQUIRED_VERSION"
- pinfo "calling configure"
- ./configure --disable-manpages --enable-split-usr --sysconfdir="/etc" --enable-gtk-doc-html=no --disable-nls \
- --disable-microhttpd --disable-bootchart --disable-quotacheck --disable-hostnamed --disable-timedated \
- --disable-localed --disable-coredump --disable-keymap --without-python --enable-blkid --enable-acl --enable-pam \
- || perror "configure failed."
- pinfo "calling make"
- make || perror "make failed."
- pinfo "calling make install"
- DESTDIR="${MODULE_BUILD_DIR}" make install || perror "make install failed."
- fi
+ pinfo "calling make"
+ make || perror "make failed."
+ pinfo "calling make install"
+ DESTDIR="${MODULE_BUILD_DIR}" make install || perror "make install failed."
cd - &> /dev/null
+
# Delete unneeded services
pinfo "Deleting unneeded services"
local SERVICE=
diff --git a/remote/modules/systemd/systemd.conf.scientific b/remote/modules/systemd/systemd.conf.scientific
index cbda26fc..71ab4267 100644
--- a/remote/modules/systemd/systemd.conf.scientific
+++ b/remote/modules/systemd/systemd.conf.scientific
@@ -1,6 +1,5 @@
REQUIRED_VERSION="systemd-206"
REQUIRED_URL="http://www.freedesktop.org/software/systemd/${REQUIRED_VERSION}.tar.xz"
-# REQUIRED_URL="http://www.freedesktop.org/software/systemd/${REQUIRED_VERSION}.tar.bz2"
REQUIRED_INSTALLED_PACKAGES="
intltool
gperf
@@ -14,3 +13,9 @@ REQUIRED_INSTALLED_PACKAGES="
"
REQUIRED_UTILLINUX_VERSION="2.23"
REQUIRED_UTILLINUX_URL="ftp://ftp.kernel.org/pub/linux/utils/util-linux/v${REQUIRED_UTILLINUX_VERSION}/util-linux-${REQUIRED_UTILLINUX_VERSION}.tar.xz"
+REQUIRED_M4_VERSION="1.4.16"
+REQUIRED_M4_URL="ftp://ftp.gnu.org/gnu/m4/m4-${REQUIRED_M4_VERSION}.tar.xz"
+REQUIRED_AUTOCONF_VERSION="2.69"
+REQUIRED_AUTOCONF_URL="ftp://ftp.gnu.org/gnu/autoconf/autoconf-${REQUIRED_AUTOCONF_VERSION}.tar.xz"
+REQUIRED_AUTOMAKE_VERSION="1.13"
+REQUIRED_AUTOMAKE_URL="ftp://ftp.gnu.org/gnu/automake/automake-${REQUIRED_AUTOMAKE_VERSION}.tar.xz"