diff options
l--------- | 342.bash_static.build (renamed from 342.bzip2.build) | 0 | ||||
l--------- | 343.bzip2.build (renamed from 343.coreutils.build) | 0 | ||||
l--------- | 344.coreutils.build (renamed from 344.cron.build) | 0 | ||||
l--------- | 345.coreutils_static.build (renamed from 345.curl.build) | 0 | ||||
l--------- | 346.cron.build (renamed from 346.dash.build) | 0 | ||||
l--------- | 347.curl.build (renamed from 347.diffutils.build) | 0 | ||||
l--------- | 348.dash.build (renamed from 348.ed.build) | 0 | ||||
l--------- | 349.diffutils.build (renamed from 349.findutils.build) | 0 | ||||
l--------- | 350.ed.build (renamed from 350.gawk.build) | 0 | ||||
l--------- | 351.file.build (renamed from 351.git.build) | 0 | ||||
l--------- | 352.findutils.build (renamed from 352.grep.build) | 0 | ||||
l--------- | 353.gawk.build (renamed from 353.hexcurse.build) | 0 | ||||
l--------- | 354.git.build (renamed from 354.htop.build) | 0 | ||||
l--------- | 355.grep.build (renamed from 355.inetutils.build) | 0 | ||||
l--------- | 356.hexcurse.build (renamed from 356.irssi.build) | 0 | ||||
l--------- | 357.htop.build (renamed from 357.less.build) | 0 | ||||
l--------- | 358.inetutils.build (renamed from 358.lua.build) | 0 | ||||
l--------- | 359.irssi.build (renamed from 359.lynx.build) | 0 | ||||
l--------- | 360.less.build (renamed from 360.man_db.build) | 0 | ||||
l--------- | 361.lua.build (renamed from 361.make.build) | 0 | ||||
l--------- | 362.lynx.build (renamed from 362.mc.build) | 0 | ||||
l--------- | 363.man_db.build (renamed from 363.mksh.build) | 0 | ||||
l--------- | 364.make.build (renamed from 364.nano.build) | 0 | ||||
l--------- | 365.mc.build (renamed from 365.netcat.build) | 0 | ||||
l--------- | 366.mksh.build (renamed from 366.openssh.build) | 0 | ||||
l--------- | 367.nano.build (renamed from 367.pacman.build) | 0 | ||||
l--------- | 368.netcat.build (renamed from 368.patch.build) | 0 | ||||
l--------- | 369.openssh.build (renamed from 369.perl.build) | 0 | ||||
l--------- | 370.pacman.build (renamed from 370.procps_ng.build) | 0 | ||||
l--------- | 371.patch.build (renamed from 371.python3.build) | 0 | ||||
l--------- | 372.perl.build (renamed from 372.rsync.build) | 0 | ||||
-rw-r--r-- | 372.perl.vars (renamed from 369.perl.vars) | 0 | ||||
l--------- | 373.procps_ng.build (renamed from 373.rxvt_unicode.build) | 0 | ||||
l--------- | 374.python3.build (renamed from 374.sed.build) | 0 | ||||
-rw-r--r-- | 374.python3.vars (renamed from 371.python3.vars) | 0 | ||||
l--------- | 375.rsync.build (renamed from 375.tar.build) | 0 | ||||
l--------- | 376.rxvt_unicode.build (renamed from 376.tcsh.build) | 0 | ||||
l--------- | 377.sed.build (renamed from 377.the_silver_searcher.build) | 0 | ||||
l--------- | 378.tar.build (renamed from 378.tmux.build) | 0 | ||||
l--------- | 379.tcsh.build (renamed from 379.util_linux.build) | 0 | ||||
l--------- | 380.the_silver_searcher.build (renamed from 380.vim.build) | 0 | ||||
l--------- | 381.tmux.build (renamed from 381.which.build) | 0 | ||||
l--------- | 382.util_linux.build (renamed from 382.whois.build) | 0 | ||||
l--------- | 383.vim.build (renamed from 383.xeyes.build) | 0 | ||||
l--------- | 384.which.build (renamed from 384.xwd.build) | 0 | ||||
l--------- | 385.whois.build (renamed from 385.zsh.build) | 0 | ||||
l--------- | 386.xeyes.build | 1 | ||||
l--------- | 387.xwd.build | 1 | ||||
l--------- | 388.zsh.build | 1 | ||||
-rw-r--r-- | 998.midipix_sh.build (renamed from 399.midipix_sh.build) | 0 | ||||
-rw-r--r-- | 999.tarballs.build | 22 | ||||
-rwxr-xr-x | build.sh | 10 | ||||
-rw-r--r-- | build.subr | 18 | ||||
-rw-r--r-- | build.usage | 1 | ||||
-rw-r--r-- | build.vars | 32 | ||||
-rw-r--r-- | config.cache | 3 | ||||
-rwxr-xr-x | midipix.sh | 74 |
57 files changed, 117 insertions, 46 deletions
diff --git a/342.bzip2.build b/342.bash_static.build index 52bb82e5..52bb82e5 120000 --- a/342.bzip2.build +++ b/342.bash_static.build diff --git a/343.coreutils.build b/343.bzip2.build index 52bb82e5..52bb82e5 120000 --- a/343.coreutils.build +++ b/343.bzip2.build diff --git a/344.cron.build b/344.coreutils.build index 52bb82e5..52bb82e5 120000 --- a/344.cron.build +++ b/344.coreutils.build diff --git a/345.curl.build b/345.coreutils_static.build index 52bb82e5..52bb82e5 120000 --- a/345.curl.build +++ b/345.coreutils_static.build diff --git a/346.dash.build b/346.cron.build index 52bb82e5..52bb82e5 120000 --- a/346.dash.build +++ b/346.cron.build diff --git a/347.diffutils.build b/347.curl.build index 52bb82e5..52bb82e5 120000 --- a/347.diffutils.build +++ b/347.curl.build diff --git a/348.ed.build b/348.dash.build index 52bb82e5..52bb82e5 120000 --- a/348.ed.build +++ b/348.dash.build diff --git a/349.findutils.build b/349.diffutils.build index 52bb82e5..52bb82e5 120000 --- a/349.findutils.build +++ b/349.diffutils.build diff --git a/350.gawk.build b/350.ed.build index 52bb82e5..52bb82e5 120000 --- a/350.gawk.build +++ b/350.ed.build diff --git a/351.git.build b/351.file.build index 52bb82e5..52bb82e5 120000 --- a/351.git.build +++ b/351.file.build diff --git a/352.grep.build b/352.findutils.build index 52bb82e5..52bb82e5 120000 --- a/352.grep.build +++ b/352.findutils.build diff --git a/353.hexcurse.build b/353.gawk.build index 52bb82e5..52bb82e5 120000 --- a/353.hexcurse.build +++ b/353.gawk.build diff --git a/354.htop.build b/354.git.build index 52bb82e5..52bb82e5 120000 --- a/354.htop.build +++ b/354.git.build diff --git a/355.inetutils.build b/355.grep.build index 52bb82e5..52bb82e5 120000 --- a/355.inetutils.build +++ b/355.grep.build diff --git a/356.irssi.build b/356.hexcurse.build index 52bb82e5..52bb82e5 120000 --- a/356.irssi.build +++ b/356.hexcurse.build diff --git a/357.less.build b/357.htop.build index 52bb82e5..52bb82e5 120000 --- a/357.less.build +++ b/357.htop.build diff --git a/358.lua.build b/358.inetutils.build index 52bb82e5..52bb82e5 120000 --- a/358.lua.build +++ b/358.inetutils.build diff --git a/359.lynx.build b/359.irssi.build index 52bb82e5..52bb82e5 120000 --- a/359.lynx.build +++ b/359.irssi.build diff --git a/360.man_db.build b/360.less.build index 52bb82e5..52bb82e5 120000 --- a/360.man_db.build +++ b/360.less.build diff --git a/361.make.build b/361.lua.build index 52bb82e5..52bb82e5 120000 --- a/361.make.build +++ b/361.lua.build diff --git a/362.mc.build b/362.lynx.build index 52bb82e5..52bb82e5 120000 --- a/362.mc.build +++ b/362.lynx.build diff --git a/363.mksh.build b/363.man_db.build index 52bb82e5..52bb82e5 120000 --- a/363.mksh.build +++ b/363.man_db.build diff --git a/364.nano.build b/364.make.build index 52bb82e5..52bb82e5 120000 --- a/364.nano.build +++ b/364.make.build diff --git a/365.netcat.build b/365.mc.build index 52bb82e5..52bb82e5 120000 --- a/365.netcat.build +++ b/365.mc.build diff --git a/366.openssh.build b/366.mksh.build index 52bb82e5..52bb82e5 120000 --- a/366.openssh.build +++ b/366.mksh.build diff --git a/367.pacman.build b/367.nano.build index 52bb82e5..52bb82e5 120000 --- a/367.pacman.build +++ b/367.nano.build diff --git a/368.patch.build b/368.netcat.build index 52bb82e5..52bb82e5 120000 --- a/368.patch.build +++ b/368.netcat.build diff --git a/369.perl.build b/369.openssh.build index 52bb82e5..52bb82e5 120000 --- a/369.perl.build +++ b/369.openssh.build diff --git a/370.procps_ng.build b/370.pacman.build index 52bb82e5..52bb82e5 120000 --- a/370.procps_ng.build +++ b/370.pacman.build diff --git a/371.python3.build b/371.patch.build index 52bb82e5..52bb82e5 120000 --- a/371.python3.build +++ b/371.patch.build diff --git a/372.rsync.build b/372.perl.build index 52bb82e5..52bb82e5 120000 --- a/372.rsync.build +++ b/372.perl.build diff --git a/369.perl.vars b/372.perl.vars index 853bef90..853bef90 100644 --- a/369.perl.vars +++ b/372.perl.vars diff --git a/373.rxvt_unicode.build b/373.procps_ng.build index 52bb82e5..52bb82e5 120000 --- a/373.rxvt_unicode.build +++ b/373.procps_ng.build diff --git a/374.sed.build b/374.python3.build index 52bb82e5..52bb82e5 120000 --- a/374.sed.build +++ b/374.python3.build diff --git a/371.python3.vars b/374.python3.vars index 9cdc016f..9cdc016f 100644 --- a/371.python3.vars +++ b/374.python3.vars diff --git a/375.tar.build b/375.rsync.build index 52bb82e5..52bb82e5 120000 --- a/375.tar.build +++ b/375.rsync.build diff --git a/376.tcsh.build b/376.rxvt_unicode.build index 52bb82e5..52bb82e5 120000 --- a/376.tcsh.build +++ b/376.rxvt_unicode.build diff --git a/377.the_silver_searcher.build b/377.sed.build index 52bb82e5..52bb82e5 120000 --- a/377.the_silver_searcher.build +++ b/377.sed.build diff --git a/378.tmux.build b/378.tar.build index 52bb82e5..52bb82e5 120000 --- a/378.tmux.build +++ b/378.tar.build diff --git a/379.util_linux.build b/379.tcsh.build index 52bb82e5..52bb82e5 120000 --- a/379.util_linux.build +++ b/379.tcsh.build diff --git a/380.vim.build b/380.the_silver_searcher.build index 52bb82e5..52bb82e5 120000 --- a/380.vim.build +++ b/380.the_silver_searcher.build diff --git a/381.which.build b/381.tmux.build index 52bb82e5..52bb82e5 120000 --- a/381.which.build +++ b/381.tmux.build diff --git a/382.whois.build b/382.util_linux.build index 52bb82e5..52bb82e5 120000 --- a/382.whois.build +++ b/382.util_linux.build diff --git a/383.xeyes.build b/383.vim.build index 52bb82e5..52bb82e5 120000 --- a/383.xeyes.build +++ b/383.vim.build diff --git a/384.xwd.build b/384.which.build index 52bb82e5..52bb82e5 120000 --- a/384.xwd.build +++ b/384.which.build diff --git a/385.zsh.build b/385.whois.build index 52bb82e5..52bb82e5 120000 --- a/385.zsh.build +++ b/385.whois.build diff --git a/386.xeyes.build b/386.xeyes.build new file mode 120000 index 00000000..52bb82e5 --- /dev/null +++ b/386.xeyes.build @@ -0,0 +1 @@ +pkg.build
\ No newline at end of file diff --git a/387.xwd.build b/387.xwd.build new file mode 120000 index 00000000..52bb82e5 --- /dev/null +++ b/387.xwd.build @@ -0,0 +1 @@ +pkg.build
\ No newline at end of file diff --git a/388.zsh.build b/388.zsh.build new file mode 120000 index 00000000..52bb82e5 --- /dev/null +++ b/388.zsh.build @@ -0,0 +1 @@ +pkg.build
\ No newline at end of file diff --git a/399.midipix_sh.build b/998.midipix_sh.build index a44b7c93..a44b7c93 100644 --- a/399.midipix_sh.build +++ b/998.midipix_sh.build diff --git a/999.tarballs.build b/999.tarballs.build index 09930d1e..a15a6349 100644 --- a/999.tarballs.build +++ b/999.tarballs.build @@ -23,10 +23,11 @@ else log_msg failexit "Unknown tarball suffix \`.${TARBALL_SUFFIX}'."; fi; +PREFIX_BASENAME=${PREFIX_NATIVE##*/}; TARBALL_FNAME=${TARBALL_FNAME_PREFIX}${BUILD_USER}@${BUILD_HNAME}-${BUILD_DATE_START}.tar.${TARBALL_SUFFIX}; +TARBALL_MINIPIX_FNAME=${TARBALL_MINIPIX_FNAME_PREFIX}${BUILD_USER}@${BUILD_HNAME}-${BUILD_DATE_START}.tar.${TARBALL_SUFFIX}; TARBALL_SRC_FNAME=${TARBALL_SRC_FNAME_PREFIX}${BUILD_USER}@${BUILD_HNAME}-${BUILD_DATE_START}.tar.${TARBALL_SUFFIX}; -PREFIX_BASENAME=${PREFIX_NATIVE##*/}; secure_rm ${PREFIX_BASENAME}/lib.bak; insecure_mkdir ${PREFIX_BASENAME}/lib.bak; tar -C ${PREFIX_BASENAME}/lib -cpf - . | tar -C ${PREFIX_BASENAME}/lib.bak -xpf -; @@ -54,16 +55,27 @@ fi; secure_rm ${PREFIX_BASENAME}/lib; mv -- ${PREFIX_BASENAME}/lib.bak ${PREFIX_BASENAME}/lib; log_msg info "Restored ${PREFIX_BASENAME}/lib."; +tar -cpf - minipix \ + "Create \`Midipix mintty shell' shortcut.vbs" midipix.sh README |\ +${TARBALL_COMPRESS_CMD} ${TARBALL_COMPRESS_ARGS} -c > ${TARBALL_MINIPIX_FNAME}; +log_msg info "Finished building binary Minipix distribution tarball."; +if [ -x "$(which gpg 2>/dev/null)" -a -n "${TARBALL_MINIPIX_SIGN_GPG_KEY}" ] &&\ + gpg --list-keys "${TARBALL_MINIPIX_SIGN_GPG_KEY}" >/dev/null 2>&1; then + gpg --armor --passphrase-file /dev/null \ + --local-user "${TARBALL_MINIPIX_SIGN_GPG_KEY}" --sign ${TARBALL_MINIPIX_FNAME}; + log_msg info "Signed binary Minipix distribution tarball."; +fi; + if [ "${BUILD}" = "debug" ]; then log_msg info "Building source tarball..."; - tar -cpf - $(find tmp -mindepth 2 -maxdepth 2 \ - -not -path tmp/.\* \ - -not -path tmp/ntctty/.git -not -path tmp/psxscl/.git) |\ + tar -cpf - $(find tmp -mindepth 2 -maxdepth 2 \ + -not -path tmp/.\* \ + -not -path tmp/ntctty/.git -not -path tmp/psxscl/.git) |\ ${TARBALL_COMPRESS_CMD} ${TARBALL_COMPRESS_ARGS} -c > ${TARBALL_SRC_FNAME}; log_msg info "Finished building source tarball."; if [ -x "$(which gpg 2>/dev/null)" -a -n "${TARBALL_SRC_SIGN_GPG_KEY}" ] &&\ gpg --list-keys "${TARBALL_SRC_SIGN_GPG_KEY}" >/dev/null 2>&1; then - gpg --armor --passphrase-file /dev/null \ + gpg --armor --passphrase-file /dev/null \ --local-user "${TARBALL_SRC_SIGN_GPG_KEY}" --sign ${TARBALL_SRC_FNAME}; log_msg info "Signed source tarball."; fi; @@ -10,7 +10,8 @@ VALID_BUILD_LEVELS="fetch,extract,build_dir,autoconf,patch,configure,clean,build while [ ${#} -gt 0 ]; do case ${1} in -c) ARG_CLEAN=1; ;; --t*) ARG_TARBALL=1; [ "${1#-t.}" != "${1}" ] && TARBALL_SUFFIX=${1#-t.}; ;; +-t*) export ARG_TARBALL=1; [ "${1#-t.}" != "${1}" ] && TARBALL_SUFFIX=${1#-t.}; ;; +-v) export ARG_VERBOSE=1; ;; -x) ARG_XTRACE=1; set -o xtrace; ;; -a) [ -z "${2}" ] && exec cat build.usage || ARCH="${2}"; shift; ;; -b) [ -z "${2}" ] && exec cat build.usage || BUILD="${2}"; shift; ;; @@ -94,7 +95,7 @@ if [ ${ARG_CLEAN:-0} -eq 1 ]; then fi; # Create directory hierarchy and usr -> . symlinks. -insecure_mkdir ${PREFIX} ${PREFIX_NATIVE} ${PREFIX_CROSS} ${PREFIX_TARGET}/lib ${DLCACHEDIR} ${WORKDIR}; +insecure_mkdir ${PREFIX} ${PREFIX_MINIPIX} ${PREFIX_NATIVE} ${PREFIX_CROSS} ${PREFIX_TARGET}/lib ${DLCACHEDIR} ${WORKDIR}; for __ in ${PREFIX}/usr ${PREFIX_NATIVE}/usr; do if [ ! -L "${__}" ]; then secure_rm "${__}"; ln -sf -- . "${__}"; @@ -112,7 +113,7 @@ BUILD_TIMES_SECS=$(command date +%s); log_msg info "Build started by ${BUILD_USER:=${USER}}@${BUILD_HNAME:=$(hostname)} at ${BUILD_DATE_START}."; log_env_vars "build (global)" ${LOG_ENV_VARS}; -for BUILD_LVL in 0 1 2 3 ${ARG_TARBALL:+9}; do +for BUILD_LVL in 0 1 2 3 9; do for BUILD_SCRIPT_FNAME in ${BUILD_LVL}[0-9][0-9].*.build; do if [ -n "${ARG_RESTART_SCRIPT}" ] \ && [ "${ARG_RESTART_SCRIPT}" != "ALL" ] \ @@ -138,7 +139,8 @@ for BUILD_LVL in 0 1 2 3 ${ARG_TARBALL:+9}; do SCRIPT_NAME=${SCRIPT_FNAME%%.build*}; \ export PKG_BUILD=${BUILD}; \ export PKG_TARGET=${TARGET}; \ - export PKG_PREFIX=$(get_var_unsafe PKG_LVL${BUILD_LVL}_PREFIX);\ + export PKG_PREFIX=$(get_vars_unsafe PKG_LVL${BUILD_LVL}_PREFIX \ + PKG_$(echo ${2} | tr a-z A-Z)_PREFIX); \ export MIDIPIX_BUILD_PWD=$(pwd); cd ${WORKDIR}; \ for SCRIPT_SOURCE in build.subr ${SCRIPT_NAME}.vars \ ${BUILD_SCRIPT_FNAME}; do \ @@ -51,6 +51,15 @@ fetch_git() { cp -pr ${DLCACHEDIR}/${_fg_subdir} .; }; +get_vars_unsafe() { + while [ ${#} -gt 0 ]; do + _gvu_vval="$(eval echo \${${1}})"; + [ -z "${_gvu_vval}" ] || _gvu_vval_="${_gvu_vval}"; + shift; + done; echo "${_gvu_vval_}"; + unset _gvu_vval _gvu_vval_; +}; + insert_build_script_link() { _ibsl_fname=${1}; _ibsl_level=${_ibsl_fname%%.*}; @@ -230,7 +239,8 @@ secure_cd() { (cd "${1}"; [ "${PWD#${PREFIX_ROOT}}" = "${PWD}" ] &&\ return 1 || return 0); if [ ${?} -eq 0 ]; then - log_msg warn "Changing working directory to \`${1}'."; + [ "${ARG_VERBOSE:-0}" -eq 1 ] &&\ + log_msg warn "Changing working directory to \`${1}'."; cd -- "${1}"; else log_msg failexit "secure_cd() called with pathname \`${1}' not below \${PREFIX_ROOT} (${PREFIX_ROOT}). This is a bug."; @@ -242,7 +252,8 @@ insecure_mkdir() { if [ -z "${1}" ]; then return 1; elif [ ! -e "${1}" ]; then - log_msg warn "Making directory \`${1}'."; + [ "${ARG_VERBOSE:-0}" -eq 1 ] &&\ + log_msg warn "Making directory \`${1}'."; mkdir -p -- "${1}"; fi; shift; done; @@ -261,7 +272,8 @@ secure_rm() { return 1 || return 0); if [ ${?} -eq 0 ]; then unset _sr_pname_check; - log_msg warn "Removing directory or file \`${1}'."; + [ "${ARG_VERBOSE:-0}" -eq 1 ] &&\ + log_msg warn "Removing directory or file \`${1}'."; rm -rf -- "${1}"; else log_msg failexit "secure_rm() called with pathname \`${1}' not below \${PREFIX_ROOT} (${PREFIX_ROOT}). This is a bug."; diff --git a/build.usage b/build.usage index 624f66ca..59677ed6 100644 --- a/build.usage +++ b/build.usage @@ -20,6 +20,7 @@ usage: ./build.sh [-a nt32|nt64] [-b debug|release] [-c] [-h] [-i level.name.bui level regular files at the end of a build with zero failures. The tarballs will be compressed with either gzip, bzip2, or xz and signed with GPG; the default compression is xz. + -v Be verbose; this currently only affects secure_{cd,rm}() and insecure_mkdir(). -x Set the xtrace sh(1)ell option for debugging purposes. Packages that are built by pkg.build will apply local patches in ${WORKDIR} @@ -31,6 +31,7 @@ fi; : ${PREFIX_ROOT:=${HOME}/midipix}; : ${PREFIX:=${PREFIX_ROOT}/${ARCH}/${BUILD}}; +: ${PREFIX_MINIPIX:=${PREFIX}/minipix}; : ${PREFIX_NATIVE:=${PREFIX}/native}; : ${PREFIX_CROSS:=${PREFIX}/${TARGET}}; : ${DLCACHEDIR:=${PREFIX_ROOT}/dlcache}; @@ -43,7 +44,7 @@ export PATH="${PREFIX}/bin${PATH:+:${PATH}}"; : ${CHECK_PREREQ_CMDS:="aclocal autoconf autopoint awk basename bunzip2 find flex git groff gunzip install libtool lzma make makeinfo nl nroff openssl patch sed sha256sum sort tar tee tr uname wget xz"}; : ${CHECK_PREREQ_FILES:="/usr/include/gmpxx.h /usr/include/mpc.h /usr/include/mpfr.h"}; : ${CHECK_PATH_VARS:="PREFIX PREFIX_NATIVE PREFIX_CROSS DLCACHEDIR WORKDIR"}; -: ${CLEAR_ENV_VARS_EXCEPT:="HOME PATH SHELL TERM USER"}; +: ${CLEAR_ENV_VARS_EXCEPT:="ARG_TARBALL ARG_VERBOSE HOME PATH SHELL TERM USER"}; : ${CLEAR_PREFIX_DIRS:="bin i686-nt32-midipix include lib lib64 libexec native share tmp x86_64-nt64-midipix"}; : ${GITROOT:=git://midipix.org}; : ${GITROOT_HEAD:=git://midipix.org}; @@ -54,6 +55,8 @@ export PATH="${PREFIX}/bin${PATH:+:${PATH}}"; : ${LOG_MSG_WARN_COLOUR:=96}; : ${TARBALL_FNAME_PREFIX:=midipix-${ARCH}-${BUILD}.}; : ${TARBALL_SIGN_GPG_KEY:=}; +: ${TARBALL_MINIPIX_FNAME_PREFIX:=minipix-${ARCH}-${BUILD}.}; +: ${TARBALL_MINIPIX_SIGN_GPG_KEY:=}; : ${TARBALL_SRC_FNAME_PREFIX:=midipix-${ARCH}-${BUILD}_src.}; : ${TARBALL_SRC_SIGN_GPG_KEY:=}; : ${TARBALL_SUFFIX:=xz}; @@ -108,7 +111,8 @@ PKG_LVL3_MAKEFLAGS_INSTALL="DESTDIR=${PREFIX_NATIVE}"; : ${PKG_PSXSTUB_URL_TYPE:=git}; : ${PKG_SLIBTOOL_HOST_URL:=git://midipix.org/slibtool}; : ${PKG_SLIBTOOL_HOST_URL_TYPE:=git}; -: ${PKG_SLIBTOOL_HOST_CONFIGURE_ARGS:=--host= --prefix=${PREFIX}}; +: ${PKG_SLIBTOOL_HOST_CONFIGURE_ARGS:=--host= --prefix=}; +: ${PKG_SLIBTOOL_HOST_MAKEFLAGS_INSTALL=DESTDIR=${PREFIX}}; # # Build level 1 (native toolchain) @@ -151,7 +155,7 @@ PKG_LVL3_MAKEFLAGS_INSTALL="DESTDIR=${PREFIX_NATIVE}"; : ${PKG_PKGCONF_INSTALL_FILES:=/=lib/pkgconfig}; : ${PKG_SLIBTOOL_URL:=git://midipix.org/slibtool}; : ${PKG_SLIBTOOL_URL_TYPE:=git}; -: ${PKG_SLIBTOOL_CONFIGURE_ARGS="--host=${TARGET} --prefix=/ --target=${TARGET}"}; +: ${PKG_SLIBTOOL_CONFIGURE_ARGS="--host=${TARGET} --prefix= --target=${TARGET}"}; # # Build level 2 (runtime components) @@ -161,6 +165,7 @@ PKG_LVL3_MAKEFLAGS_INSTALL="DESTDIR=${PREFIX_NATIVE}"; : ${PKG_NTCON_URL:=${GITROOT}/ntcon}; : ${PKG_NTCTTY_URL:=${GITROOT_HEAD}/ntctty}; : ${PKG_NTCTTY_CFLAGS_CONFIGURE_EXTRA:=-O0}; +: ${PKG_NTCTTY_PREFIX_EXTRA:=DESTDIR=${PREFIX_MINIPIX}}; : ${PKG_PEMAGINE_URL:=${GITROOT}/pemagine}; : ${PKG_PEMAGINE_CFLAGS_CONFIGURE_EXTRA:=-O0}; : ${PKG_PSXSCL_URL:=${GITROOT_HEAD}/psxscl}; @@ -246,6 +251,7 @@ PKG_LVL3_MAKEFLAGS_INSTALL="DESTDIR=${PREFIX_NATIVE}"; : ${PKG_NCURSESW_BUILD_DIR:=ncursesw-${PKG_NCURSESW_VERSION}-native-${TARGET}}; : ${PKG_NCURSESW_CONFIGURE_ARGS_EXTRA:="--enable-pc-files --program-prefix= --with-pkg-config-libdir=${PREFIX_NATIVE}/lib/pkgconfig --with-shared --with-manpages --with-progs --without-tests --enable-widec --without-pthread"}; : ${PKG_NCURSESW_INSTALL_FILES:=@ncursesw/ncurses.h=include/ncurses.h}; +: ${PKG_NCURSESW_PREFIX_EXTRA:=DESTDIR=${PREFIX_MINIPIX}}; : ${PKG_PCRE_VERSION:=8.39}; : ${PKG_PCRE_SHA256SUM:=ccdf7e788769838f8285b3ee672ed573358202305ee361cfec7a4a4fb005bbc7}; : ${PKG_PCRE_URL:=ftp://ftp.csx.cam.ac.uk/pub/software/programming/pcre/pcre-${PKG_PCRE_VERSION}.tar.gz}; @@ -344,12 +350,23 @@ PKG_LVL3_MAKEFLAGS_INSTALL="DESTDIR=${PREFIX_NATIVE}"; : ${PKG_BASH_VERSION:=4.3}; : ${PKG_BASH_SHA256SUM:=afc687a28e0e24dc21b988fa159ff9dbcf6b7caa92ade8645cc6d5605cd024d4}; : ${PKG_BASH_URL:=https://ftp.gnu.org/gnu/bash/bash-${PKG_BASH_VERSION}.tar.gz}; -: ${PKG_BASH_CONFIGURE_ARGS_EXTRA:="--enable-static-link --without-bash-malloc --with-curses"}; +: ${PKG_BASH_CONFIGURE_ARGS_EXTRA:="--without-bash-malloc --with-curses"}; +: ${PKG_BASH_STATIC_VERSION:=4.3}; +: ${PKG_BASH_STATIC_SHA256SUM:=afc687a28e0e24dc21b988fa159ff9dbcf6b7caa92ade8645cc6d5605cd024d4}; +: ${PKG_BASH_STATIC_URL:=https://ftp.gnu.org/gnu/bash/bash-${PKG_BASH_VERSION}.tar.gz}; +: ${PKG_BASH_STATIC_CONFIGURE_ARGS_EXTRA:="--enable-static-link --without-bash-malloc --with-curses"}; +: ${PKG_BASH_STATIC_MAKEFLAGS_INSTALL:="DESTDIR=${PREFIX_MINIPIX}/"}; +: ${PKG_BASH_STATIC_PREFIX=${PREFIX_MINIPIX}}; : ${PKG_COREUTILS_VERSION:=8.23}; : ${PKG_COREUTILS_SHA256SUM:=ec43ca5bcfc62242accb46b7f121f6b684ee21ecd7d075059bf650ff9e37b82d}; : ${PKG_COREUTILS_URL:=https://ftp.gnu.org/gnu/coreutils/coreutils-${PKG_COREUTILS_VERSION}.tar.xz}; -: ${PKG_COREUTILS_LDFLAGS_BUILD_EXTRA:=-static}; -: ${PKG_COREUTILS_MAKEFLAGS_BUILD_EXTRA:=SHARED=0}; +: ${PKG_COREUTILS_STATIC_VERSION:=8.23}; +: ${PKG_COREUTILS_STATIC_SHA256SUM:=ec43ca5bcfc62242accb46b7f121f6b684ee21ecd7d075059bf650ff9e37b82d}; +: ${PKG_COREUTILS_STATIC_URL:=https://ftp.gnu.org/gnu/coreutils/coreutils-${PKG_COREUTILS_VERSION}.tar.xz}; +: ${PKG_COREUTILS_STATIC_LDFLAGS_BUILD_EXTRA:=-static}; +: ${PKG_COREUTILS_STATIC_MAKEFLAGS_BUILD_EXTRA:=SHARED=0}; +: ${PKG_COREUTILS_STATIC_MAKEFLAGS_INSTALL:="DESTDIR=${PREFIX_MINIPIX}/"}; +: ${PKG_COREUTILS_STATIC_PREFIX=${PREFIX_MINIPIX}}; : ${PKG_CRON_URL:=git://anonscm.debian.org/pkg-cron/pkg-cron.git}; : ${PKG_CRON_URL_TYPE:=git}; : ${PKG_CRON_BUILD_DIR:=pkg-cron.git}; @@ -370,6 +387,9 @@ PKG_LVL3_MAKEFLAGS_INSTALL="DESTDIR=${PREFIX_NATIVE}"; : ${PKG_DIFFUTILS_VERSION:=3.3}; : ${PKG_DIFFUTILS_SHA256SUM:=a25e89a8ab65fded1731e4186be1bb25cda967834b6df973599cdcd5abdfc19c}; : ${PKG_DIFFUTILS_URL:=https://ftp.gnu.org/gnu/diffutils/diffutils-${PKG_DIFFUTILS_VERSION}.tar.xz}; +: ${PKG_FILE_VERSION:=5.28}; +: ${PKG_FILE_SHA256SUM:=0ecb5e146b8655d1fa84159a847ee619fc102575205a0ff9c6cc60fc5ee2e012}; +: ${PKG_FILE_URL:=ftp://ftp.astron.com/pub/file/file-${PKG_FILE_VERSION}.tar.gz}; : ${PKG_FINDUTILS_VERSION:=4.5.14}; : ${PKG_FINDUTILS_SHA256SUM:=0de3cf625a5c9f154eee3171e072515ffdde405244dd00502af617ac57b73ae2}; : ${PKG_FINDUTILS_URL:=http://alpha.gnu.org/gnu/findutils/findutils-${PKG_FINDUTILS_VERSION}.tar.gz}; diff --git a/config.cache b/config.cache index 1c131219..9f4d314f 100644 --- a/config.cache +++ b/config.cache @@ -143,6 +143,9 @@ bash_cv_unusable_rtsigs=no # libX11 xorg_cv_malloc0_returns_null=yes +# mc +ac_list_mounted_fs=found + # procps_ng ac_cv_func_realloc_0_nonnull=yes @@ -21,9 +21,9 @@ convert_links_ask() { read _; case "${_}" in [yY]) break; ;; - *) echo "Exiting."; exit 5; ;; + *) echo "Exiting."; exit 6; ;; esac; - for _link_name in $(find ${MIDIPIX_PATH}/native/lib \ + for _link_name in $(find ${MIDIPIX_PATH}/native/lib \ -maxdepth 1 -name \*.so -type l); do _link_target="$(readlink -- "${_link_name}")"; if [ -f "${MIDIPIX_PATH}/native/lib/${_link_target}" ]; then @@ -37,10 +37,10 @@ convert_links_ask() { check_prereq_files() { local _fname; - for _fname in native/bin/ntctty.exe \ - native/bin/chroot \ - native/bin/env \ - native/bin/bash; do + for _fname in ${MIDIPIX_DNAME_ROOT}/bin/ntctty.exe \ + ${MIDIPIX_DNAME_ROOT}/bin/chroot \ + ${MIDIPIX_DNAME_ROOT}/bin/env \ + ${MIDIPIX_DNAME_ROOT}/bin/bash; do if [ ! -e ${MIDIPIX_PATH}/${_fname} ]; then return 1; fi; @@ -48,32 +48,50 @@ check_prereq_files() { }; prepend_path /bin; -if [ "${1}" = -h ]; then - echo "usage: $0 [Cygwin pathname to Midipix root]"; exit 0; -elif [ "${1}" = -l ]; then - TAILF_LOG=1; shift; -fi; -if [ ${#} -eq 0 ]; then +while [ ${#} -gt 0 ]; do + if [ "${1}" = -h ]; then + echo "usage: $0 [-h] [-l] [-m] [Cygwin pathname to Midipix root]"; + echo " -l: tail(1) -f libpsxscl.log"; + echo " -m: use Minipix root"; + exit 0; + elif [ "${1}" = -l ]; then + ARG_TAILF_LOG=1; shift; + elif [ "${1}" = -m ]; then + ARG_MINIPIX=1; shift; + MIDIPIX_DNAME_ROOT=minipix; + elif [ "${1#-}" = "${1}" ]; then + MIDIPIX_PATH="${1}"; + fi; +done; +if [ -z "${MIDIPIX_PATH}" ]; then MIDIPIX_PATH="$(cygpath -am .)" || exit 1; -else - MIDIPIX_PATH="${1}"; fi; UNAME_OS="$(uname -o)" || exit 2; if [ "${MIDIPIX_PATH#*[ ]*}" != "${MIDIPIX_PATH}" ]; then echo "Error: drive_letter/dirname must not contain SP (\` ') or VT (\`\\\t') characters."; exit 3; -fi; -if [ ! -d ${MIDIPIX_PATH} ]; then +elif [ ! -d ${MIDIPIX_PATH} ]; then echo "Error: Midipix path non-existent or invalid (\`${MIDIPIX_PATH}'.)"; exit 4; -elif [ -n "${NATIVE_LIB_LINKS:=$(find ${MIDIPIX_PATH}/native/lib -maxdepth 1 -name \*.so -type l -print -quit)}" ]; then - convert_links_ask || exit 5; +elif [ -z "${MIDIPIX_DNAME_ROOT}" ]; then + if [ -e ${MIDIPIX_PATH}/native ]; then + MIDIPIX_DNAME_ROOT=native; + elif [ -e ${MIDIPIX_PATH}/minipix ]; then + MIDIPIX_DNAME_ROOT=minipix; + else + echo "Error: neither \`${MIDIPIX_PATH}/native' nor \`${MIDIPIX_PATH}/minipix' exist."; + exit 5; + fi; +fi; +if [ \( "${ARG_MINIPIX:-0}" -eq 0 \) -a \ + \( -n "${NATIVE_LIB_LINKS:=$(find ${MIDIPIX_PATH}/native/lib -maxdepth 1 -name \*.so -type l -print -quit)}" \) ]; then + convert_links_ask || exit 7; else - check_prereq_files || exit 6; + check_prereq_files || exit 8; if [ -f ${MIDIPIX_PATH}/libpsxscl.log ]; then echo Found libpsxscl.log, copying to ${MIDIPIX_PATH}/libpsxscl.last. - cp -p -- ${MIDIPIX_PATH}/libpsxscl.log \ - ${MIDIPIX_PATH}/libpsxscl.last || exit 7; + cp -p -- ${MIDIPIX_PATH}/libpsxscl.log \ + ${MIDIPIX_PATH}/libpsxscl.last || exit 9; fi; echo "Absolute Midipix pathname: ${MIDIPIX_PATH}"; if [ "${UNAME_OS}" = "Msys" ]; then @@ -81,16 +99,16 @@ else fi; mintty -h always -s 120,80 -e /bin/sh -c " set -o errexit; stty raw -echo; - cd ${MIDIPIX_PATH}; \ - env PATH=${MIDIPIX_PATH}/native/lib \ - native/bin/ntctty.exe -e \ - chroot native \ - /bin/env PATH=/bin:/lib \ + cd ${MIDIPIX_PATH}; \ + env PATH=${MIDIPIX_PATH}/${MIDIPIX_DNAME_ROOT}/lib \ + ${MIDIPIX_DNAME_ROOT}/bin/ntctty.exe -e \ + chroot ${MIDIPIX_DNAME_ROOT} \ + /bin/env PATH=/bin:/lib \ bash" & sleep 0.25; NTCTTY_PID="$(ps -W | awk '$NF ~ /ntctty\.exe$/{print $1}')"; echo "ntctty PID : ${NTCTTY_PID}"; - if [ ${TAILF_LOG:-0} -eq 1 ]; then - tail -f ${MIDIPIX_PATH}/native/bin/libpsxscl.log; + if [ ${ARG_TAILF_LOG:-0} -eq 1 ]; then + tail -f ${MIDIPIX_PATH}/${MIDIPIX_DNAME_ROOT}/bin/libpsxscl.log; fi; fi; |