--- embedaddon/build.sh 2011/07/20 12:25:35 1.2 +++ embedaddon/build.sh 2011/11/01 19:37:27 1.5.2.2 @@ -1,19 +1,24 @@ #!/bin/sh # -# (C)`10 PKG-Builder for elwix by Michael Pounov +# (C)`10 PKG-Builder for ELWIX by Michael Pounov # -# ./build.sh [package] [prefix_dir] [os_specific_set] [other_make_opts ...] +# ./build.sh [package] [os_specific_build_set] [prefix_dir] [other_make_opts ...] # -# $Id: build.sh,v 1.2 2011/07/20 12:25:35 misho Exp $ +# $Id: build.sh,v 1.5.2.2 2011/11/01 19:37:27 misho Exp $ # CMD=$1 MK=${2:-make} P=${3:-/tmp} +B=$4 PFX="--prefix ${P}" -shift; shift; shift; +shift; shift; shift; shift; echo ">>> Working script ${MK} into ${PFX}" +if [ -n "${B}" ]; then + PFX="${PFX} --build ${B}" +fi + TOP=$(pwd) echo ">>> TOPDIR=${TOP}" @@ -21,12 +26,18 @@ case $CMD in sudo) cd sudo # [ ! -r config.log ] && \ - ./configure --sysconfdir=/etc --with-ignore-dot --with-tty-tickets \ - --with-env-editor --with-logincap \ - --with-long-otp-prompt --with-pam --with-logfac=local2 ${PFX} + ./configure --sysconfdir=/etc --libexecdir=/usr/libexec --with-ignore-dot \ + --with-tty-tickets --with-env-editor --with-logincap \ + --with-long-otp-prompt --with-pam --with-logfac=local2 \ + ${PFX} ${MK} clean ${MK} - ${MK} install + install src/sudo ${P}/bin + ln ${P}/bin/sudo ${P}/bin/sudoedit + install plugins/sudoers/sudoreplay ${P}/bin + install plugins/sudoers/visudo ${P}/sbin + install plugins/sudoers/.libs/sudoers.so ${P}/libexec + install src/.libs/libsudo_noexec.so ${P}/libexec echo ">>> Now rebuild elwix firmware image ..." ;; ntpd) @@ -121,7 +132,9 @@ case $CMD in --enable-dhcpv6 ${PFX} ${MK} clean ${MK} - ${MK} install + install server/dhcpd ${P}/sbin + install relay/dhcrelay ${P}/sbin + install dhcpctl/omshell ${P}/bin echo ">>> Now rebuild elwix firmware image ..." ;; dhcping) @@ -196,8 +209,8 @@ case $CMD in ${MK} install echo ">>> Now rebuild elwix firmware image ..." ;; - hping2) - cd hping2 + hping) + cd hping # [ ! -r config.log ] && \ ./configure ${PFX} ${MK} clean @@ -395,7 +408,10 @@ case $CMD in ./configure --enable-utf8 --enable-unicode-properties ${PFX} ${MK} clean ${MK} - ${MK} install + install .libs/libpcre.so ${P}/lib + install .libs/libpcreposix.so ${P}/lib + install .libs/libpcrecpp.so ${P}/lib +# rm -f ${P}/lib/libpcrecpp.so*T ${P}/lib/libpcreposix.so*T echo ">>> Now rebuild elwix firmware image ..." ;; spawn-fcgi) @@ -422,13 +438,56 @@ case $CMD in ./configure --without-python ${PFX} ${MK} clean ${MK} - ${MK} install + install .libs/libxml2.so ${P}/lib cd .. cd php # [ ! -r config.log ] && \ - ./configure --localstatedir=/tmp --with-config-file-scan-dir=/etc/php --disable-all \ + ./configure --localstatedir=/var --with-config-file-scan-dir=/etc/php --disable-all \ --enable-libxml=../libxml2/.libs --with-openssl \ --enable-zip --enable-sqlite-utf8 ${PFX} + ${MK} clean + ${MK} + ${MK} install + echo ">>> Now rebuild elwix firmware image ..." + ;; + scan_ffs) + cd scan_ffs + ${MK} clean + ${MK} + install scan_ffs ${P}/bin + echo ">>> Now rebuild elwix firmware image ..." + ;; + rsync) + cd rsync + ./configure.sh --disable-debug --enable-ipv6 --with-rsyncd-conf=/etc/rsyncd.conf \ + --disable-iconv --with-included-popt ${PFX} + ${MK} clean + ${MK} + ${MK} install + echo ">>> Now rebuild elwix firmware image ..." + ;; + pciutils) + cd pciutils + ${MK} clean + ${MK} + install lspci ${P}/bin + install setpci ${P}/bin + echo ">>> Now rebuild elwix firmware image ..." + ;; + pure-ftpd) + cd pure-ftpd + ./configure --with-everything --with-paranoidmsg --sysconfdir=/etc --localstatedir=/var \ + --with-privsep --with-peruserlimits --with-throttling --with-tls --with-pam \ + --with-uploadscript --with-rfc2640 --with-sendfile --enable-largefile \ + --with-virtualchroot ${PFX} + ${MK} clean + ${MK} + ${MK} install + echo ">>> Now rebuild elwix firmware image ..." + ;; + ladvd) + cd ladvd + ./configure --with-chroot-dir=/var/empty ${PFX} ${MK} clean ${MK} ${MK} install