From d53f3251f1335f35315e9514bb2a438f9a779b4b Mon Sep 17 00:00:00 2001 From: Jonathan Bauer Date: Mon, 18 Mar 2013 16:37:12 +0100 Subject: fix plymouth theme path, fix stage3.1 vmware/uvesafb modprobing --- .../data/lib/plymouth/themes/default.plymouth | 8 -- .../plymouth/themes/unifr-rz/rz_banner_trans.png | Bin 15730 -> 0 bytes .../lib/plymouth/themes/unifr-rz/rz_logo_trans.png | Bin 4309 -> 0 bytes .../lib/plymouth/themes/unifr-rz/unifr-rz.plymouth | 9 -- .../lib/plymouth/themes/unifr-rz/unifr-rz.script | 116 --------------------- .../plymouth/themes/unifr-rz/white_dot_small.png | Bin 376 -> 0 bytes .../data/share/plymouth/themes/default.plymouth | 8 ++ .../plymouth/themes/unifr-rz/rz_banner_trans.png | Bin 0 -> 15730 bytes .../plymouth/themes/unifr-rz/rz_logo_trans.png | Bin 0 -> 4309 bytes .../plymouth/themes/unifr-rz/unifr-rz.plymouth | 9 ++ .../share/plymouth/themes/unifr-rz/unifr-rz.script | 116 +++++++++++++++++++++ .../plymouth/themes/unifr-rz/white_dot_small.png | Bin 0 -> 376 bytes 12 files changed, 133 insertions(+), 133 deletions(-) delete mode 100644 remote/modules/plymouth/data/lib/plymouth/themes/default.plymouth delete mode 100644 remote/modules/plymouth/data/lib/plymouth/themes/unifr-rz/rz_banner_trans.png delete mode 100644 remote/modules/plymouth/data/lib/plymouth/themes/unifr-rz/rz_logo_trans.png delete mode 100644 remote/modules/plymouth/data/lib/plymouth/themes/unifr-rz/unifr-rz.plymouth delete mode 100644 remote/modules/plymouth/data/lib/plymouth/themes/unifr-rz/unifr-rz.script delete mode 100644 remote/modules/plymouth/data/lib/plymouth/themes/unifr-rz/white_dot_small.png create mode 100644 remote/modules/plymouth/data/share/plymouth/themes/default.plymouth create mode 100644 remote/modules/plymouth/data/share/plymouth/themes/unifr-rz/rz_banner_trans.png create mode 100644 remote/modules/plymouth/data/share/plymouth/themes/unifr-rz/rz_logo_trans.png create mode 100644 remote/modules/plymouth/data/share/plymouth/themes/unifr-rz/unifr-rz.plymouth create mode 100644 remote/modules/plymouth/data/share/plymouth/themes/unifr-rz/unifr-rz.script create mode 100644 remote/modules/plymouth/data/share/plymouth/themes/unifr-rz/white_dot_small.png (limited to 'remote/modules') diff --git a/remote/modules/plymouth/data/lib/plymouth/themes/default.plymouth b/remote/modules/plymouth/data/lib/plymouth/themes/default.plymouth deleted file mode 100644 index bc669108..00000000 --- a/remote/modules/plymouth/data/lib/plymouth/themes/default.plymouth +++ /dev/null @@ -1,8 +0,0 @@ -[Plymouth Theme] -Name=Uni-Freiburg Basic Theme -Description=Uni-Freiburg simple blue-ish theme with simple progress bar -ModuleName=script - -[script] -ImageDir=/lib/plymouth/themes/unifr-rz -ScriptFile=/lib/plymouth/themes/unifr-rz/unifr-rz.script diff --git a/remote/modules/plymouth/data/lib/plymouth/themes/unifr-rz/rz_banner_trans.png b/remote/modules/plymouth/data/lib/plymouth/themes/unifr-rz/rz_banner_trans.png deleted file mode 100644 index 9cb68040..00000000 Binary files a/remote/modules/plymouth/data/lib/plymouth/themes/unifr-rz/rz_banner_trans.png and /dev/null differ diff --git a/remote/modules/plymouth/data/lib/plymouth/themes/unifr-rz/rz_logo_trans.png b/remote/modules/plymouth/data/lib/plymouth/themes/unifr-rz/rz_logo_trans.png deleted file mode 100644 index 16b069cc..00000000 Binary files a/remote/modules/plymouth/data/lib/plymouth/themes/unifr-rz/rz_logo_trans.png and /dev/null differ diff --git a/remote/modules/plymouth/data/lib/plymouth/themes/unifr-rz/unifr-rz.plymouth b/remote/modules/plymouth/data/lib/plymouth/themes/unifr-rz/unifr-rz.plymouth deleted file mode 100644 index 0f300f6b..00000000 --- a/remote/modules/plymouth/data/lib/plymouth/themes/unifr-rz/unifr-rz.plymouth +++ /dev/null @@ -1,9 +0,0 @@ -[Plymouth Theme] -Name=Simple RZ Theme -Description=Simple blue RZ theme with progress bar. -ModuleName=script - -[script] -ImageDir=/lib/plymouth/themes/unifr-rz -ScriptFile=/lib/plymouth/themes/unifr-rz/unifr-rz.script - diff --git a/remote/modules/plymouth/data/lib/plymouth/themes/unifr-rz/unifr-rz.script b/remote/modules/plymouth/data/lib/plymouth/themes/unifr-rz/unifr-rz.script deleted file mode 100644 index f2d8bd28..00000000 --- a/remote/modules/plymouth/data/lib/plymouth/themes/unifr-rz/unifr-rz.script +++ /dev/null @@ -1,116 +0,0 @@ -Window.SetBackgroundTopColor(0.00, 0.21, 0.57); -#Window.SetBackgroundBottomColor(0.00, 0.17, 0.95); - -title_left_image = Image("rz_banner_trans.png"); -title_right_image = Image("rz_logo_trans.png"); -title_left_sprite = Sprite(title_left_image); -title_right_sprite = Sprite(title_right_image); - -title_right_sprite.SetX(Window.GetWidth() - title_right_image.GetWidth()); - -dot.image = Image("white_dot_small.png"); -dot.sprite1 = Sprite(dot.image); -dot.sprite2 = Sprite(dot.image); -dot.sprite3 = Sprite(dot.image); -dot.sprite4 = Sprite(dot.image); -dot.sprite5 = Sprite(dot.image); - -#----------------------------------------- Progress Dots -------------------------------- - -dot.x = Window.GetWidth() / 2 - dot.image.GetWidth() / 2; -dot.y = Window.GetHeight() * 0.75 - dot.image.GetHeight() / 2; -dot.spacing = Window.GetWidth() / 15; - -# place 5 centered dots -dot.sprite1.SetPosition(dot.x - 2 * dot.spacing, dot.y, 1); -dot.sprite2.SetPosition(dot.x - dot.spacing, dot.y, 1); -dot.sprite3.SetPosition(dot.x, dot.y, 1); -dot.sprite4.SetPosition(dot.x + dot.spacing, dot.y, 1); -dot.sprite5.SetPosition(dot.x + 2 * dot.spacing, dot.y, 1); - -# set opacity -dot.sprite1.SetOpacity(0.1); -dot.sprite2.SetOpacity(0.1); -dot.sprite3.SetOpacity(0.1); -dot.sprite4.SetOpacity(0.1); -dot.sprite5.SetOpacity(0.1); - -fun progress_callback (duration, progress) - { - phase = Math.Int(duration * 2) % 10; - - if ( phase == 1 ) - { - fade_out(dot.sprite5); - fade_in(dot.sprite1); - } - - if ( phase == 2 ) - { - fade_out(dot.sprite1); - fade_in(dot.sprite2); - } - - if ( phase == 3 ) - { - fade_out(dot.sprite2); - fade_in(dot.sprite3); - } - - if ( phase == 4 ) - { - fade_out(dot.sprite3); - fade_in(dot.sprite4); - } - - if ( phase == 5 ) - { - fade_out(dot.sprite4); - fade_in(dot.sprite5); - } - - if ( phase == 6 ) - { - fade_out(dot.sprite5); - fade_in(dot.sprite1); - } - - if ( phase == 7 ) - { - fade_out(dot.sprite1); - fade_in(dot.sprite2); - } - - if ( phase == 8 ) - { - fade_out(dot.sprite2); - fade_in(dot.sprite3); - } - - if ( phase == 9 ) - { - fade_out(dot.sprite3); - fade_in(dot.sprite4); - } - - if ( phase == 0 ) - { - fade_out(dot.sprite4); - if ( Math.Int(duration) > 0 ) - { fade_in(dot.sprite5); } - } - } - -fun fade_in(sprite) -{ - if ( sprite.GetOpacity() + 0.1 < 1 ) - { sprite.SetOpacity(sprite.GetOpacity() + 0.1);} -} - -fun fade_out(sprite) -{ - if ( sprite.GetOpacity() - 0.1 > 0.1 ) - { sprite.SetOpacity(sprite.GetOpacity() - 0.1);} -} - -Plymouth.SetBootProgressFunction(progress_callback); diff --git a/remote/modules/plymouth/data/lib/plymouth/themes/unifr-rz/white_dot_small.png b/remote/modules/plymouth/data/lib/plymouth/themes/unifr-rz/white_dot_small.png deleted file mode 100644 index 4fd4be30..00000000 Binary files a/remote/modules/plymouth/data/lib/plymouth/themes/unifr-rz/white_dot_small.png and /dev/null differ diff --git a/remote/modules/plymouth/data/share/plymouth/themes/default.plymouth b/remote/modules/plymouth/data/share/plymouth/themes/default.plymouth new file mode 100644 index 00000000..8499e451 --- /dev/null +++ b/remote/modules/plymouth/data/share/plymouth/themes/default.plymouth @@ -0,0 +1,8 @@ +[Plymouth Theme] +Name=Uni-Freiburg Basic Theme +Description=Uni-Freiburg simple blue-ish theme with simple progress bar +ModuleName=script + +[script] +ImageDir=/share/plymouth/themes/unifr-rz +ScriptFile=/share/plymouth/themes/unifr-rz/unifr-rz.script diff --git a/remote/modules/plymouth/data/share/plymouth/themes/unifr-rz/rz_banner_trans.png b/remote/modules/plymouth/data/share/plymouth/themes/unifr-rz/rz_banner_trans.png new file mode 100644 index 00000000..9cb68040 Binary files /dev/null and b/remote/modules/plymouth/data/share/plymouth/themes/unifr-rz/rz_banner_trans.png differ diff --git a/remote/modules/plymouth/data/share/plymouth/themes/unifr-rz/rz_logo_trans.png b/remote/modules/plymouth/data/share/plymouth/themes/unifr-rz/rz_logo_trans.png new file mode 100644 index 00000000..16b069cc Binary files /dev/null and b/remote/modules/plymouth/data/share/plymouth/themes/unifr-rz/rz_logo_trans.png differ diff --git a/remote/modules/plymouth/data/share/plymouth/themes/unifr-rz/unifr-rz.plymouth b/remote/modules/plymouth/data/share/plymouth/themes/unifr-rz/unifr-rz.plymouth new file mode 100644 index 00000000..0f300f6b --- /dev/null +++ b/remote/modules/plymouth/data/share/plymouth/themes/unifr-rz/unifr-rz.plymouth @@ -0,0 +1,9 @@ +[Plymouth Theme] +Name=Simple RZ Theme +Description=Simple blue RZ theme with progress bar. +ModuleName=script + +[script] +ImageDir=/lib/plymouth/themes/unifr-rz +ScriptFile=/lib/plymouth/themes/unifr-rz/unifr-rz.script + diff --git a/remote/modules/plymouth/data/share/plymouth/themes/unifr-rz/unifr-rz.script b/remote/modules/plymouth/data/share/plymouth/themes/unifr-rz/unifr-rz.script new file mode 100644 index 00000000..f2d8bd28 --- /dev/null +++ b/remote/modules/plymouth/data/share/plymouth/themes/unifr-rz/unifr-rz.script @@ -0,0 +1,116 @@ +Window.SetBackgroundTopColor(0.00, 0.21, 0.57); +#Window.SetBackgroundBottomColor(0.00, 0.17, 0.95); + +title_left_image = Image("rz_banner_trans.png"); +title_right_image = Image("rz_logo_trans.png"); +title_left_sprite = Sprite(title_left_image); +title_right_sprite = Sprite(title_right_image); + +title_right_sprite.SetX(Window.GetWidth() - title_right_image.GetWidth()); + +dot.image = Image("white_dot_small.png"); +dot.sprite1 = Sprite(dot.image); +dot.sprite2 = Sprite(dot.image); +dot.sprite3 = Sprite(dot.image); +dot.sprite4 = Sprite(dot.image); +dot.sprite5 = Sprite(dot.image); + +#----------------------------------------- Progress Dots -------------------------------- + +dot.x = Window.GetWidth() / 2 - dot.image.GetWidth() / 2; +dot.y = Window.GetHeight() * 0.75 - dot.image.GetHeight() / 2; +dot.spacing = Window.GetWidth() / 15; + +# place 5 centered dots +dot.sprite1.SetPosition(dot.x - 2 * dot.spacing, dot.y, 1); +dot.sprite2.SetPosition(dot.x - dot.spacing, dot.y, 1); +dot.sprite3.SetPosition(dot.x, dot.y, 1); +dot.sprite4.SetPosition(dot.x + dot.spacing, dot.y, 1); +dot.sprite5.SetPosition(dot.x + 2 * dot.spacing, dot.y, 1); + +# set opacity +dot.sprite1.SetOpacity(0.1); +dot.sprite2.SetOpacity(0.1); +dot.sprite3.SetOpacity(0.1); +dot.sprite4.SetOpacity(0.1); +dot.sprite5.SetOpacity(0.1); + +fun progress_callback (duration, progress) + { + phase = Math.Int(duration * 2) % 10; + + if ( phase == 1 ) + { + fade_out(dot.sprite5); + fade_in(dot.sprite1); + } + + if ( phase == 2 ) + { + fade_out(dot.sprite1); + fade_in(dot.sprite2); + } + + if ( phase == 3 ) + { + fade_out(dot.sprite2); + fade_in(dot.sprite3); + } + + if ( phase == 4 ) + { + fade_out(dot.sprite3); + fade_in(dot.sprite4); + } + + if ( phase == 5 ) + { + fade_out(dot.sprite4); + fade_in(dot.sprite5); + } + + if ( phase == 6 ) + { + fade_out(dot.sprite5); + fade_in(dot.sprite1); + } + + if ( phase == 7 ) + { + fade_out(dot.sprite1); + fade_in(dot.sprite2); + } + + if ( phase == 8 ) + { + fade_out(dot.sprite2); + fade_in(dot.sprite3); + } + + if ( phase == 9 ) + { + fade_out(dot.sprite3); + fade_in(dot.sprite4); + } + + if ( phase == 0 ) + { + fade_out(dot.sprite4); + if ( Math.Int(duration) > 0 ) + { fade_in(dot.sprite5); } + } + } + +fun fade_in(sprite) +{ + if ( sprite.GetOpacity() + 0.1 < 1 ) + { sprite.SetOpacity(sprite.GetOpacity() + 0.1);} +} + +fun fade_out(sprite) +{ + if ( sprite.GetOpacity() - 0.1 > 0.1 ) + { sprite.SetOpacity(sprite.GetOpacity() - 0.1);} +} + +Plymouth.SetBootProgressFunction(progress_callback); diff --git a/remote/modules/plymouth/data/share/plymouth/themes/unifr-rz/white_dot_small.png b/remote/modules/plymouth/data/share/plymouth/themes/unifr-rz/white_dot_small.png new file mode 100644 index 00000000..4fd4be30 Binary files /dev/null and b/remote/modules/plymouth/data/share/plymouth/themes/unifr-rz/white_dot_small.png differ -- cgit v1.2.3-55-g7522 From da0084106fbd7a11fb0156bc673947a4f482b2d2 Mon Sep 17 00:00:00 2001 From: Jonathan Bauer Date: Tue, 19 Mar 2013 15:02:52 +0100 Subject: copy_static_files function now called on each module --- helper/fileutil.inc | 9 +++++++++ remote/modules/hwinfo/hwinfo.build | 2 +- remote/modules/kdm/kdm.build | 2 -- remote/modules/ldm-gtk-greeter/ldm-gtk-greeter.build | 6 +----- remote/modules/ldm/ldm.build | 3 --- remote/modules/plymouth/plymouth.build | 5 +---- remote/modules/policykit/policykit.build | 3 --- remote/modules/sshd/sshd.build | 1 - remote/modules/systemd/systemd.build | 3 --- remote/setup_target | 8 +++++--- 10 files changed, 17 insertions(+), 25 deletions(-) (limited to 'remote/modules') diff --git a/helper/fileutil.inc b/helper/fileutil.inc index 4855e326..f7654719 100644 --- a/helper/fileutil.inc +++ b/helper/fileutil.inc @@ -63,7 +63,16 @@ install_dependencies() { zypper install -y $REQUIRED_DEPENDENCIES || perror "Could not zypper install $REQUIRED_DEPENDENCIES" fi } +# +# copies static data files from /data/ to +# +copy_static_data() { + [ ! -d "${MODULE_DIR}/data" ] && pinfo "${MODULE} has no static 'data' directory." && return + cp -r ${MODULE_DIR}/data/* ${TARGET_BUILD_DIR} || perror "Could not copy static data of ${MODULE}" +} + +###################################################################################################################### # # generate initramfs of directory # usage: diff --git a/remote/modules/hwinfo/hwinfo.build b/remote/modules/hwinfo/hwinfo.build index 383b8c2a..b2012a22 100644 --- a/remote/modules/hwinfo/hwinfo.build +++ b/remote/modules/hwinfo/hwinfo.build @@ -9,7 +9,7 @@ fetch_source() { build() { pdebug "Installing libx86emu in ${MODULE_DIR}/build..." cd "${MODULE_DIR}/src/libx86emu" - make || perror "libx86emu: make failed." + EXTRA_FLAGS="-I${MODULE_DIR}/src/libx86emu/include" make || perror "libx86emu: make failed." DESTDIR="${MODULE_DIR}"/build make install || perror "libx86emu: make install failed." cd - &> /dev/null diff --git a/remote/modules/kdm/kdm.build b/remote/modules/kdm/kdm.build index 88c47f6b..3a924380 100644 --- a/remote/modules/kdm/kdm.build +++ b/remote/modules/kdm/kdm.build @@ -14,8 +14,6 @@ build () { } post_copy() { - # copy static kdm files to stage3.2 - cp -r ${MODULE_DIR}/data/* ${TARGET_BUILD_DIR} #create static kdm folders in stage3.2 mkdir -p ${TARGET_BUILD_DIR}/var/lib/kdm mkdir -p ${TARGET_BUILD_DIR}/var/run/kdm diff --git a/remote/modules/ldm-gtk-greeter/ldm-gtk-greeter.build b/remote/modules/ldm-gtk-greeter/ldm-gtk-greeter.build index 19adf66a..7f02e281 100644 --- a/remote/modules/ldm-gtk-greeter/ldm-gtk-greeter.build +++ b/remote/modules/ldm-gtk-greeter/ldm-gtk-greeter.build @@ -28,11 +28,7 @@ build () { } post_copy() { - #copy static data files - cp -r "${MODULE_DIR}/data/"* "${TARGET_BUILD_DIR}" || perror "Copying data/* failed." - # TODO: FIX PATH TO TRIPLET... - TRIPLET="$(basename "$(dirname "$(ldd "$SHELL" | grep libc | awk -F " " '{print $3}')")")" - gdk-pixbuf-query-loaders > "${TARGET_BUILD_DIR}/usr/lib/${TRIPLET}/gdk-pixbuf-2.0/2.10.0/loaders.cache" || perror "pixbuf-query-loaders failed." + gdk-pixbuf-query-loaders > "${TARGET_BUILD_DIR}/usr/lib/${ARCH_TRIPLET}/gdk-pixbuf-2.0/2.10.0/loaders.cache" || perror "pixbuf-query-loaders failed." mkdir -p "${TARGET_BUILD_DIR}/etc/pango" || perror "Making etc/pango failed." pango-querymodules > "${TARGET_BUILD_DIR}/etc/pango/pango.modules" || perror "pango-querymodules failed." gtk-update-icon-cache-3.0 "${TARGET_BUILD_DIR}/usr/share/icons/hicolor/" || perror "update-icon-cache-3.0 failed." diff --git a/remote/modules/ldm/ldm.build b/remote/modules/ldm/ldm.build index 88429cff..0e73148c 100644 --- a/remote/modules/ldm/ldm.build +++ b/remote/modules/ldm/ldm.build @@ -34,8 +34,5 @@ post_copy() { local LDMGID=$(add_group "lightdm") pinfo "lightdm user and group is $LDMUID $LDMGID" chown -R "${LDMUID}:${LDMGID}" "${TARGET_BUILD_DIR}/var/lib/lightdm/" || perror "chowning '${TARGET_BUILD_DIR}/var/lib/lightdm/' failed." - #copyi static data files - cp -r "${MODULE_DIR}/data/"* "${TARGET_BUILD_DIR}" || perror "Copying data/ failed." - } diff --git a/remote/modules/plymouth/plymouth.build b/remote/modules/plymouth/plymouth.build index 4363e809..fbaa428a 100644 --- a/remote/modules/plymouth/plymouth.build +++ b/remote/modules/plymouth/plymouth.build @@ -20,8 +20,5 @@ build() { } post_copy() { - # copy static dbus systemd unit files to stage3.2 - SYSTEMDDIR=${TARGET_BUILD_DIR}/etc/systemd/system - [ ! -d ${SYSTEMDDIR} ] && mkdir -p ${SYSTEMDDIR} - cp -r ${MODULE_DIR}/data/* ${TARGET_BUILD_DIR} + : } diff --git a/remote/modules/policykit/policykit.build b/remote/modules/policykit/policykit.build index 6a03b81c..b6b70b7f 100644 --- a/remote/modules/policykit/policykit.build +++ b/remote/modules/policykit/policykit.build @@ -15,9 +15,6 @@ build () { post_copy() { - # copy static policykit files to stage3.2 - cp -r ${MODULE_BUILD_DIR}/data/* ${TARGET_BUILD_DIR} - #Add Polkit User/Group/Shadow to Stage3.2 pinfo "Adding polkitd user to target system..." add_user "polkitd" diff --git a/remote/modules/sshd/sshd.build b/remote/modules/sshd/sshd.build index 57a9e35d..aa4241e6 100644 --- a/remote/modules/sshd/sshd.build +++ b/remote/modules/sshd/sshd.build @@ -15,5 +15,4 @@ build() { post_copy() { mkdir -p "${TARGET_BUILD_DIR}/var/run/sshd" - cp -r "${MODULE_DIR}"/data/* "${TARGET_BUILD_DIR}" } diff --git a/remote/modules/systemd/systemd.build b/remote/modules/systemd/systemd.build index 450e743b..bb58fc1c 100644 --- a/remote/modules/systemd/systemd.build +++ b/remote/modules/systemd/systemd.build @@ -32,9 +32,6 @@ build () { } post_copy() { - # copy static data files - cp -r "${MODULE_DIR}"/data/* "${TARGET_BUILD_DIR}" || perror "copying data files failed." - # dont clear systemd log at startup sed -i.bak "s/TTYVTDisallocate=yes/TTYVTDisallocate=no/g" "${TARGET_BUILD_DIR}/usr/lib/systemd/system/getty@.service" diff --git a/remote/setup_target b/remote/setup_target index c1a45787..e3273f4d 100755 --- a/remote/setup_target +++ b/remote/setup_target @@ -51,7 +51,8 @@ read_build () { . "${BUILD_SCRIPT}" || perror "Sourcing '${BUILD_SCRIPT}' failed." } -copyfileswithdependencies () { + +copy_files_with_deps () { [ ! -d $MODULE_BUILD_DIR ] && pinfo "No build directory found, skipping dependency copying" && return 0 cd $MODULE_BUILD_DIR @@ -188,7 +189,6 @@ process_module() { if [ ! -z "$REQUIRED_MODULES" ]; then pinfo "$MODULE depends on ${REQUIRED_MODULES}...." for DEP in $REQUIRED_MODULES; do - #[[ "$DESIRED_MODULES" != *"!${DEP}!"* ]] && perror "$TOOL has dependency $DEP, but $DEP is not in current profile." process_module "$DEP" done # Read old config again, as it got overwritten by the deps @@ -207,7 +207,9 @@ process_module() { # remove *.la files as they might confuse libtool/linker of other tool packages find "${MODULE_DIR}/build" -name '*.la' -exec rm -f {} \; pinfo "## Copying files with dependencies" - copyfileswithdependencies + copy_files_with_deps + pinfo "## Copying static module files" + copy_static_data pinfo "## Post copy" post_copy -- cgit v1.2.3-55-g7522 From 2668c259b71369bd39ac222894c15363d6668c40 Mon Sep 17 00:00:00 2001 From: Jonathan Bauer Date: Tue, 19 Mar 2013 16:00:42 +0100 Subject: use all cores by make through MAKEFLAGS --- helper/system.inc | 4 ++++ remote/modules/busybox/busybox.build | 2 +- remote/modules/plymouth/plymouth.build | 2 +- remote/modules/systemd/systemd.build | 18 +++++++++--------- remote/modules/systemd/systemd.conf | 2 ++ 5 files changed, 17 insertions(+), 11 deletions(-) (limited to 'remote/modules') diff --git a/helper/system.inc b/helper/system.inc index 1245687b..b9c61b98 100644 --- a/helper/system.inc +++ b/helper/system.inc @@ -8,3 +8,7 @@ ARCH_TRIPLET=$(ldd $SHELL|grep libc | awk -F "/" '{print $3}') # determine kernel version KERNEL_VERSION=$(uname -r) [ ! -z $KERNEL_VERSION ] || pwarning "Could not determine kernel version." + +# determine number of CPU cores +CPU_CORES=$(cat /proc/cpuinfo | grep processor | wc -l) +export MAKEFLAGS="-j$[$CPU_CORES +1]" diff --git a/remote/modules/busybox/busybox.build b/remote/modules/busybox/busybox.build index bc2adc64..d11a3828 100644 --- a/remote/modules/busybox/busybox.build +++ b/remote/modules/busybox/busybox.build @@ -14,7 +14,7 @@ build() if [ ! -e .built ]; then cd src pinfo "Running make" - make -j5 || perror "failed." + make || perror "failed." pinfo "Running make install" make CONFIG_PREFIX="${MODULE_DIR}"/build/"${PREFIX}" install || perror "failed" cd - diff --git a/remote/modules/plymouth/plymouth.build b/remote/modules/plymouth/plymouth.build index fbaa428a..d5e9c594 100644 --- a/remote/modules/plymouth/plymouth.build +++ b/remote/modules/plymouth/plymouth.build @@ -11,7 +11,7 @@ build() { pinfo "Running configure" ./configure --enable-systemd-integration --disable-gtk --disable-static --prefix=""|| perror "failed." pinfo "Running make" - make -j5 || perror "failed" + make || perror "failed" pinfo "Running make install" DESTDIR="${MODULE_BUILD_DIR}" make install || perror "failed" cd - diff --git a/remote/modules/systemd/systemd.build b/remote/modules/systemd/systemd.build index bb58fc1c..57fb705e 100644 --- a/remote/modules/systemd/systemd.build +++ b/remote/modules/systemd/systemd.build @@ -3,8 +3,7 @@ fetch_source () { if [ ! -e .fetched_source ]; then download_untar "$URL" "src/" - local LIBKMOD_VERSION="kmod-12" - download_untar "http://www.kernel.org/pub/linux/utils/kernel/kmod/${LIBKMOD_VERSION}.tar.gz" "src/" + download_untar "$LIBKMOD_URL" "src/" touch .fetched_source fi } @@ -12,21 +11,22 @@ fetch_source () { build () { if [ ! -e .built ]; then #build libkmod - cd "src/$LIBKMOD_VERSION/" + cd "${MODULE_DIR}/src/$LIBKMOD_VERSION" + pwarning "$(pwd)" ./configure - make -j5 - make install - cd - + make || perror "make failed." + make install || perror "make install failed." + cd - &> /dev/null #build systemd - cd "src/$VERSION/" + cd "${MODULE_DIR}/src/$VERSION" pinfo "calling configure" ./configure --disable-manpages --enable-split-usr --sysconfdir="/etc" --enable-gtk-doc-html=no || perror "configure failed." pinfo "calling make" - make -j5 || perror "make failed." + make || perror "make failed." pinfo "calling make install" DESTDIR="${MODULE_BUILD_DIR}" make install || perror "make install failed." - cd - + cd - &> /dev/null touch .built fi } diff --git a/remote/modules/systemd/systemd.conf b/remote/modules/systemd/systemd.conf index c5e72aeb..634828bd 100644 --- a/remote/modules/systemd/systemd.conf +++ b/remote/modules/systemd/systemd.conf @@ -1,5 +1,7 @@ VERSION=systemd-197 URL=http://www.freedesktop.org/software/systemd/${VERSION}.tar.xz +LIBKMOD_VERSION="kmod-12" +LIBKMOD_URL="http://www.kernel.org/pub/linux/utils/kernel/kmod/${LIBKMOD_VERSION}.tar.gz" REQUIRED_DEPENDENCIES=" intltool gperf dbus -- cgit v1.2.3-55-g7522