# Contains a bunch of scrapped build procedures, for different purposes, # so the research may be reused at a later date... # tar (1.13), not in guix: # Builds and works correctly, but has the same bug with extracting gcc-4.6 # as tar-1.12 does, and that one doesn't require patches... rm -rf tar-1.13 gzip -cd tar-1.13.tar.gz | tar x ( cd tar-1.13 sed -e 's/if (case_sensitive$/if (1/' \ lib/argmatch.c > /tmp/sed; mv /tmp/sed lib/argmatch.c CC=tcc ./configure --host=i686-pc-linux-gnu --disable-nls echo '#define __MES_MODE_T' >> config.h echo '#define S_ISLNK(Mode) (((Mode) & S_IFMT) == S_IFLNK)' >> config.h make AR='tcc -ar' install -Dm755 src/tar /bin/tar ) rm -rf tar-1.13 # tar (1.14), not in guix: # If this can be got to work, the build of tar-1.22 with gcc2 can be dropped. # Builds, but extracting anything fails... rm -rf tar-1.14 bzip2 -cd tar-1.14.tar.bz2 | tar x ( cd tar-1.14 # asctime doesn't exist in mes-libc and isn't used anyway... sed -e 's/asctime (tm)/NULL/' \ lib/time_r.c > /tmp/sed; mv /tmp/sed lib/time_r.c # mode_t and friends are in sys/stat.h... sed -e 's@@@' \ lib/modechange.h > /tmp/sed; mv /tmp/sed lib/modechange.h # rewrite src/xheader.c:xheader_set_option to not use strtok: # char *token = string; # for (;;) # { # char *t = strchr (token, ','); # if (t) *t = '\0'; # # char *p = strchr (token, '='); # if (!p) # xheader_set_single_keyword (token); # else # xheader_set_keyword_equal (token, p); # # if (!t) break; # token = t + 1; # } CC=tcc LD=tcc ./configure --disable-nls # Add linux kernel defines that are missing from mes-libc echo '#define MB_LEN_MAX 16' >> config.h echo '#define CLOCK_REALTIME 0' >> config.h echo '#define EPERM 1' >> config.h make AR='tcc -ar' install -Dm755 src/tar /bin/tar ) rm -rf tar-1.14 # Options for a "minimal" bash-2.05b build # Left out because even though it holds up just fine, no patches can be avoided # with the minimal config. # It might however be interesting to use a minimal config as a bootstrap bin? CC='tcc -D_POSIX_VERSION=1' AR='tcc -ar' ./configure \ --build=i686-pc-linux-gnu \ --without-bash-malloc \ --enable-minimal-config \ --enable-cond-command \ --enable-dparen-arithmetic \ --enable-arith-for-command \ --enable-alias \ --disable-nls \ bash_cv_getcwd_calls_popen=no \ bash_cv_signal_vintage=posix \ ac_cv_func_working_mktime=yes # gcc-4.6.4 build for build_binaries.sh mkdir build; cd build # Build breaks without a build directory CFLAGS='-O2 -w' CXXFLAGS='-O2 -w' MAKEINFO=true ../configure \ --target=i686-bootstrap-linux-gnu \ --prefix="$prefix" \ --with-sysroot="$prefix" \ --with-local-prefix=/ \ --with-newlib \ --without-headers \ --disable-shared \ --disable-decimal-float \ --disable-threads \ --disable-nls \ --enable-languages=c make all-gcc all-target-libgcc make install-gcc install-target-libgcc