code: purgatorio

Download patch

ref: 27ca2618d4bc7642370feb39a83a3cff92495ca2
parent: 0ec1cfd78b495e9be40e4aa24e35b2aa5d5e5704
author: henesy <devnull@localhost>
date: Mon Mar 11 10:37:56 EDT 2019

add makemk-AIX

binary files a/Linux/386/bin/c2l b/Linux/386/bin/c2l differ
binary files a/Linux/386/bin/data2c b/Linux/386/bin/data2c differ
binary files a/Linux/386/bin/ftl b/Linux/386/bin/ftl differ
binary files a/Linux/386/bin/iar b/Linux/386/bin/iar differ
binary files a/Linux/386/bin/idea b/Linux/386/bin/idea differ
binary files a/Linux/386/bin/inm b/Linux/386/bin/inm differ
binary files a/Linux/386/bin/iyacc b/Linux/386/bin/iyacc differ
binary files a/Linux/386/bin/kprof b/Linux/386/bin/kprof differ
binary files a/Linux/386/bin/ksize b/Linux/386/bin/ksize differ
binary files a/Linux/386/bin/kstrip b/Linux/386/bin/kstrip differ
binary files a/Linux/386/bin/md5sum b/Linux/386/bin/md5sum differ
binary files a/Linux/386/bin/mk b/Linux/386/bin/mk differ
binary files a/Linux/386/bin/mk.save b/Linux/386/bin/mk.save differ
binary files a/Linux/386/bin/mkext b/Linux/386/bin/mkext differ
binary files a/Linux/386/bin/mkppcimage b/Linux/386/bin/mkppcimage differ
binary files a/Linux/386/bin/ms2 b/Linux/386/bin/ms2 differ
binary files a/Linux/386/bin/ndate b/Linux/386/bin/ndate differ
binary files a/Linux/386/bin/sqz b/Linux/386/bin/sqz differ
binary files a/Linux/386/bin/srclist b/Linux/386/bin/srclist differ
binary files a/Linux/386/bin/styxtest b/Linux/386/bin/styxtest differ
--- /dev/null
+++ b/makemk-AIX.sh
@@ -1,0 +1,78 @@
+#!/bin/sh
+
+# this file is used only to bootstrap mk onto a platform
+# that currently lacks a binary for mk.  after that, mk can
+# look after itself.
+
+#	support@vitanuova.com
+
+# change these defines as appropriate here or in mkconfig
+# ROOT should be the root of the Inferno tree
+ROOT=/usr/inferno
+SYSTARG=AIX
+OBJTYPE=power
+SYSTYPE=posix
+
+# if you have already changed mkconfig from the distribution, we'll use the definitions from that
+grep -s 'SYSTARG=Plan9' mkconfig || . ./mkconfig
+
+PLAT=$ROOT/$SYSTARG/$OBJTYPE
+
+# you might need to adjust the CC, LD, AR, and RANLIB definitions after this point
+CC="p xlc -g -O -qsuppress=1506-224 -c -I$PLAT/include -I$ROOT/include -I$ROOT/utils/include"
+LD="p xlc"
+AR="p ar crvs"
+RANLIB=":"	# some systems still require `ranlib'
+
+error() {
+	echo $* >&2
+	exit 1
+}
+
+ofiles() {
+	echo $* | sed 's/\.c/.o/g'
+}
+
+p() {
+	echo $*
+	"$@"
+}
+
+# make sure we start off clean
+echo removing old libraries and binaries
+rm -f $PLAT/lib/*.a $PLAT/bin/*
+rm -f utils/cc/y.tab.?
+
+# ensure the output directories exist
+mkdir -p $PLAT/lib $PLAT/bin
+
+# libregexp
+cd $ROOT/utils/libregexp || error cannot find libregexp directory
+CFILES="regaux.c regcomp.c regerror.c regexec.c regsub.c rregexec.c rregsub.c"
+$CC $CFILES || error libregexp compilation failed
+$AR $PLAT/lib/libregexp.a `ofiles $CFILES` || error libregexp ar failed
+$RANLIB $PLAT/lib/libregexp.a || error libregexp ranlib failed
+
+# libbio
+cd $ROOT/libbio || error cannot find libbio directory
+$CC *.c || error libbio compilation failed
+$AR $PLAT/lib/libbio.a *.o || error libbio ar failed
+$RANLIB $PLAT/lib/libbio.a || error libbio ranlib failed
+
+# lib9
+cd $ROOT/lib9 || error cannot find lib9 directory
+CFILES="dirstat-$SYSTYPE.c rerrstr.c errstr-$SYSTYPE.c getuser-$SYSTYPE.c"	# system specific
+CFILES="$CFILES charstod.c cleanname.c create.c dirwstat.c *print*.c *fmt*.c exits.c getfields.c  pow10.c print.c qsort.c rune.c runestrlen.c seek.c strdup.c strtoll.c utflen.c utfrrune.c utfrune.c utf*.c *str*cpy*.c"
+$CC $CFILES || error lib9 compilation failed
+$AR $PLAT/lib/lib9.a `ofiles $CFILES` || error lib9 ar failed
+$RANLIB $PLAT/lib/lib9.a || error lib9 ranlib failed
+
+# mk itself
+cd $ROOT/utils/mk
+CFILES="Posix.c sh.c"	# system specific
+CFILES="$CFILES arc.c archive-AIX.c bufblock.c env.c file.c graph.c job.c lex.c main.c match.c mk.c parse.c recipe.c rule.c run.c shprint.c symtab.c var.c varsub.c word.c"
+$CC $CFILES || error mk compilation failed
+$LD -o mk `ofiles $CFILES` $PLAT/lib/libregexp.a $PLAT/lib/libbio.a $PLAT/lib/lib9.a || error mk link failed
+cp mk $PLAT/bin || error mk binary install failed
+
+echo mk binary built successfully!