From f42965c7189c8fbbce85f268a96a94a504de9737 Mon Sep 17 00:00:00 2001 From: Lucio Andrés Illanes Albornoz (arab, vxp) Date: Jul 19 2016 08:40:42 +0000 Subject: - Additionally install ncursesw and ntctty into ${PREFIX_MINIPIX} and create Minipix tarball in 999.tarballs.build which solely contains ${PREFIX_MINIPIX}. - Adds {bash,coreutils}_static which are linked statically and installed to ${PREFIX_MINIPIX} as opposed to {bash_coreutils} which are not linked statically and installed to ${PREFIX_NATIVE}. - Adds file v5.28. - Add support for ${PREFIX_MINIPIX} to midipix.sh (either automatically detected or specified via -m.) - Adds verbosity flag -v wrt. secure_{cd,rm}() and insecure_mkdir(). - Build slibtool{_host,} w/ `--prefix='. - Export ${ARG_TARBALL} instead of special-casing build level 9. - Fix mc configure failure (error: could not determine how to read list of mounted file systems.) --- diff --git a/342.bash_static.build b/342.bash_static.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/342.bash_static.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/342.bzip2.build b/342.bzip2.build deleted file mode 120000 index 52bb82e..0000000 --- a/342.bzip2.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/343.bzip2.build b/343.bzip2.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/343.bzip2.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/343.coreutils.build b/343.coreutils.build deleted file mode 120000 index 52bb82e..0000000 --- a/343.coreutils.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/344.coreutils.build b/344.coreutils.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/344.coreutils.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/344.cron.build b/344.cron.build deleted file mode 120000 index 52bb82e..0000000 --- a/344.cron.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/345.coreutils_static.build b/345.coreutils_static.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/345.coreutils_static.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/345.curl.build b/345.curl.build deleted file mode 120000 index 52bb82e..0000000 --- a/345.curl.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/346.cron.build b/346.cron.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/346.cron.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/346.dash.build b/346.dash.build deleted file mode 120000 index 52bb82e..0000000 --- a/346.dash.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/347.curl.build b/347.curl.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/347.curl.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/347.diffutils.build b/347.diffutils.build deleted file mode 120000 index 52bb82e..0000000 --- a/347.diffutils.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/348.dash.build b/348.dash.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/348.dash.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/348.ed.build b/348.ed.build deleted file mode 120000 index 52bb82e..0000000 --- a/348.ed.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/349.diffutils.build b/349.diffutils.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/349.diffutils.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/349.findutils.build b/349.findutils.build deleted file mode 120000 index 52bb82e..0000000 --- a/349.findutils.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/350.ed.build b/350.ed.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/350.ed.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/350.gawk.build b/350.gawk.build deleted file mode 120000 index 52bb82e..0000000 --- a/350.gawk.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/351.file.build b/351.file.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/351.file.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/351.git.build b/351.git.build deleted file mode 120000 index 52bb82e..0000000 --- a/351.git.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/352.findutils.build b/352.findutils.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/352.findutils.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/352.grep.build b/352.grep.build deleted file mode 120000 index 52bb82e..0000000 --- a/352.grep.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/353.gawk.build b/353.gawk.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/353.gawk.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/353.hexcurse.build b/353.hexcurse.build deleted file mode 120000 index 52bb82e..0000000 --- a/353.hexcurse.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/354.git.build b/354.git.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/354.git.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/354.htop.build b/354.htop.build deleted file mode 120000 index 52bb82e..0000000 --- a/354.htop.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/355.grep.build b/355.grep.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/355.grep.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/355.inetutils.build b/355.inetutils.build deleted file mode 120000 index 52bb82e..0000000 --- a/355.inetutils.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/356.hexcurse.build b/356.hexcurse.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/356.hexcurse.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/356.irssi.build b/356.irssi.build deleted file mode 120000 index 52bb82e..0000000 --- a/356.irssi.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/357.htop.build b/357.htop.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/357.htop.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/357.less.build b/357.less.build deleted file mode 120000 index 52bb82e..0000000 --- a/357.less.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/358.inetutils.build b/358.inetutils.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/358.inetutils.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/358.lua.build b/358.lua.build deleted file mode 120000 index 52bb82e..0000000 --- a/358.lua.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/359.irssi.build b/359.irssi.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/359.irssi.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/359.lynx.build b/359.lynx.build deleted file mode 120000 index 52bb82e..0000000 --- a/359.lynx.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/360.less.build b/360.less.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/360.less.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/360.man_db.build b/360.man_db.build deleted file mode 120000 index 52bb82e..0000000 --- a/360.man_db.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/361.lua.build b/361.lua.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/361.lua.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/361.make.build b/361.make.build deleted file mode 120000 index 52bb82e..0000000 --- a/361.make.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/362.lynx.build b/362.lynx.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/362.lynx.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/362.mc.build b/362.mc.build deleted file mode 120000 index 52bb82e..0000000 --- a/362.mc.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/363.man_db.build b/363.man_db.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/363.man_db.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/363.mksh.build b/363.mksh.build deleted file mode 120000 index 52bb82e..0000000 --- a/363.mksh.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/364.make.build b/364.make.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/364.make.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/364.nano.build b/364.nano.build deleted file mode 120000 index 52bb82e..0000000 --- a/364.nano.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/365.mc.build b/365.mc.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/365.mc.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/365.netcat.build b/365.netcat.build deleted file mode 120000 index 52bb82e..0000000 --- a/365.netcat.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/366.mksh.build b/366.mksh.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/366.mksh.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/366.openssh.build b/366.openssh.build deleted file mode 120000 index 52bb82e..0000000 --- a/366.openssh.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/367.nano.build b/367.nano.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/367.nano.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/367.pacman.build b/367.pacman.build deleted file mode 120000 index 52bb82e..0000000 --- a/367.pacman.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/368.netcat.build b/368.netcat.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/368.netcat.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/368.patch.build b/368.patch.build deleted file mode 120000 index 52bb82e..0000000 --- a/368.patch.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/369.openssh.build b/369.openssh.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/369.openssh.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/369.perl.build b/369.perl.build deleted file mode 120000 index 52bb82e..0000000 --- a/369.perl.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/369.perl.vars b/369.perl.vars deleted file mode 100644 index 853bef9..0000000 --- a/369.perl.vars +++ /dev/null @@ -1,24 +0,0 @@ -# -# . ./build.vars and set -o errexit -o noglob are assumed. -# - -pkg_perl_extract_post() { - git clone https://github.com/lalbornoz/perl-cross; - for _ppep_fname_src in $(find perl-cross -type f \ - -not -path perl-cross/.git/\* -not -name .gitignore); do - _ppep_fname_dst=perl-${PKG_VERSION}${_ppep_fname_src#perl-cross}; - if [ -f ${_ppep_fname_dst} ]; then - mv -- ${_ppep_fname_dst} ${_ppep_fname_dst}.orig; - fi; - if [ ! -d "$(dirname ${_ppep_fname_dst})" ]; then - mkdir -p -- $(dirname ${_ppep_fname_dst}); - fi; - cp -- ${_ppep_fname_src} ${_ppep_fname_dst}; - done; - for _ppep_cflag in ${PKG_CFLAGS_CONFIGURE}; do - PKG_CONFIGURE_ARGS="${PKG_CONFIGURE_ARGS:+${PKG_CONFIGURE_ARGS} }-A ccflags=${_ppep_cflag}"; - done; - unset _ppep_fname_src _ppep_fname_dst _ppep_cflag; -}; - -# vim:filetype=sh diff --git a/370.pacman.build b/370.pacman.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/370.pacman.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/370.procps_ng.build b/370.procps_ng.build deleted file mode 120000 index 52bb82e..0000000 --- a/370.procps_ng.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/371.patch.build b/371.patch.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/371.patch.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/371.python3.build b/371.python3.build deleted file mode 120000 index 52bb82e..0000000 --- a/371.python3.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/371.python3.vars b/371.python3.vars deleted file mode 100644 index 9cdc016..0000000 --- a/371.python3.vars +++ /dev/null @@ -1,17 +0,0 @@ -# -# . ./build.vars and set -o errexit -o noglob are assumed. -# - -pkg_python3_configure_pre() { - (cd ../${PKG_SUBDIR} && autoconf); - (unset AR BLDSHARED CC CFLAGS CPPFLAGS LDFLAGS RANLIB; - mv -- config.cache ../${PKG_SUBDIR}/config.cache; - ../${PKG_SUBDIR}/configure; - make _FIP=Programs/host_freeze_importlib Programs/host_freeze_importlib \ - BUILDPYTHON=hostpython hostpython \ - PGEN=Parser/hostpgen Parser/hostpgen; - make distclean); - mv -- ../${PKG_SUBDIR}/config.cache .; -}; - -# vim:filetype=sh diff --git a/372.perl.build b/372.perl.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/372.perl.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/372.perl.vars b/372.perl.vars new file mode 100644 index 0000000..853bef9 --- /dev/null +++ b/372.perl.vars @@ -0,0 +1,24 @@ +# +# . ./build.vars and set -o errexit -o noglob are assumed. +# + +pkg_perl_extract_post() { + git clone https://github.com/lalbornoz/perl-cross; + for _ppep_fname_src in $(find perl-cross -type f \ + -not -path perl-cross/.git/\* -not -name .gitignore); do + _ppep_fname_dst=perl-${PKG_VERSION}${_ppep_fname_src#perl-cross}; + if [ -f ${_ppep_fname_dst} ]; then + mv -- ${_ppep_fname_dst} ${_ppep_fname_dst}.orig; + fi; + if [ ! -d "$(dirname ${_ppep_fname_dst})" ]; then + mkdir -p -- $(dirname ${_ppep_fname_dst}); + fi; + cp -- ${_ppep_fname_src} ${_ppep_fname_dst}; + done; + for _ppep_cflag in ${PKG_CFLAGS_CONFIGURE}; do + PKG_CONFIGURE_ARGS="${PKG_CONFIGURE_ARGS:+${PKG_CONFIGURE_ARGS} }-A ccflags=${_ppep_cflag}"; + done; + unset _ppep_fname_src _ppep_fname_dst _ppep_cflag; +}; + +# vim:filetype=sh diff --git a/372.rsync.build b/372.rsync.build deleted file mode 120000 index 52bb82e..0000000 --- a/372.rsync.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/373.procps_ng.build b/373.procps_ng.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/373.procps_ng.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/373.rxvt_unicode.build b/373.rxvt_unicode.build deleted file mode 120000 index 52bb82e..0000000 --- a/373.rxvt_unicode.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/374.python3.build b/374.python3.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/374.python3.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/374.python3.vars b/374.python3.vars new file mode 100644 index 0000000..9cdc016 --- /dev/null +++ b/374.python3.vars @@ -0,0 +1,17 @@ +# +# . ./build.vars and set -o errexit -o noglob are assumed. +# + +pkg_python3_configure_pre() { + (cd ../${PKG_SUBDIR} && autoconf); + (unset AR BLDSHARED CC CFLAGS CPPFLAGS LDFLAGS RANLIB; + mv -- config.cache ../${PKG_SUBDIR}/config.cache; + ../${PKG_SUBDIR}/configure; + make _FIP=Programs/host_freeze_importlib Programs/host_freeze_importlib \ + BUILDPYTHON=hostpython hostpython \ + PGEN=Parser/hostpgen Parser/hostpgen; + make distclean); + mv -- ../${PKG_SUBDIR}/config.cache .; +}; + +# vim:filetype=sh diff --git a/374.sed.build b/374.sed.build deleted file mode 120000 index 52bb82e..0000000 --- a/374.sed.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/375.rsync.build b/375.rsync.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/375.rsync.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/375.tar.build b/375.tar.build deleted file mode 120000 index 52bb82e..0000000 --- a/375.tar.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/376.rxvt_unicode.build b/376.rxvt_unicode.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/376.rxvt_unicode.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/376.tcsh.build b/376.tcsh.build deleted file mode 120000 index 52bb82e..0000000 --- a/376.tcsh.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/377.sed.build b/377.sed.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/377.sed.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/377.the_silver_searcher.build b/377.the_silver_searcher.build deleted file mode 120000 index 52bb82e..0000000 --- a/377.the_silver_searcher.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/378.tar.build b/378.tar.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/378.tar.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/378.tmux.build b/378.tmux.build deleted file mode 120000 index 52bb82e..0000000 --- a/378.tmux.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/379.tcsh.build b/379.tcsh.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/379.tcsh.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/379.util_linux.build b/379.util_linux.build deleted file mode 120000 index 52bb82e..0000000 --- a/379.util_linux.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/380.the_silver_searcher.build b/380.the_silver_searcher.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/380.the_silver_searcher.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/380.vim.build b/380.vim.build deleted file mode 120000 index 52bb82e..0000000 --- a/380.vim.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/381.tmux.build b/381.tmux.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/381.tmux.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/381.which.build b/381.which.build deleted file mode 120000 index 52bb82e..0000000 --- a/381.which.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/382.util_linux.build b/382.util_linux.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/382.util_linux.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/382.whois.build b/382.whois.build deleted file mode 120000 index 52bb82e..0000000 --- a/382.whois.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/383.vim.build b/383.vim.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/383.vim.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/383.xeyes.build b/383.xeyes.build deleted file mode 120000 index 52bb82e..0000000 --- a/383.xeyes.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/384.which.build b/384.which.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/384.which.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/384.xwd.build b/384.xwd.build deleted file mode 120000 index 52bb82e..0000000 --- a/384.xwd.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/385.whois.build b/385.whois.build new file mode 120000 index 0000000..52bb82e --- /dev/null +++ b/385.whois.build @@ -0,0 +1 @@ +pkg.build \ No newline at end of file diff --git a/385.zsh.build b/385.zsh.build deleted file mode 120000 index 52bb82e..0000000 --- a/385.zsh.build +++ /dev/null @@ -1 +0,0 @@ -pkg.build \ No newline at end of file diff --git a/386.xeyes.build b/386.xeyes.build new file mode 120000 index 0000000..52bb82e --- /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 0000000..52bb82e --- /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 0000000..52bb82e --- /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/399.midipix_sh.build deleted file mode 100644 index a44b7c9..0000000 --- a/399.midipix_sh.build +++ /dev/null @@ -1,14 +0,0 @@ -# -# . ./build.vars and set -o errexit -o noglob are assumed. -# - -if ! is_build_script_done install; then - (cd ${MIDIPIX_BUILD_PWD}; - tar -cpf - midipix.sh README \ - 'Create `Midipix mintty shell'\'' shortcut.vbs' |\ - tar -C ${PREFIX} -xpf -); - chmod +x ${PREFIX}/midipix.sh; - set_build_script_done install finish; -fi; - -# vim:filetype=sh diff --git a/998.midipix_sh.build b/998.midipix_sh.build new file mode 100644 index 0000000..a44b7c9 --- /dev/null +++ b/998.midipix_sh.build @@ -0,0 +1,14 @@ +# +# . ./build.vars and set -o errexit -o noglob are assumed. +# + +if ! is_build_script_done install; then + (cd ${MIDIPIX_BUILD_PWD}; + tar -cpf - midipix.sh README \ + 'Create `Midipix mintty shell'\'' shortcut.vbs' |\ + tar -C ${PREFIX} -xpf -); + chmod +x ${PREFIX}/midipix.sh; + set_build_script_done install finish; +fi; + +# vim:filetype=sh diff --git a/999.tarballs.build b/999.tarballs.build index 09930d1..a15a634 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; diff --git a/build.sh b/build.sh index 8662d5e..b0e1a0b 100755 --- a/build.sh +++ b/build.sh @@ -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 \ diff --git a/build.subr b/build.subr index 10dbfd1..fc3ab1d 100644 --- a/build.subr +++ b/build.subr @@ -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 624f66c..59677ed 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} diff --git a/build.vars b/build.vars index 79019c1..5dd2d3b 100644 --- a/build.vars +++ b/build.vars @@ -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 1c13121..9f4d314 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 diff --git a/midipix.sh b/midipix.sh index 2e03abe..887ded2 100755 --- a/midipix.sh +++ b/midipix.sh @@ -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;