-# Makefile for the libraries
-# This makefile runs make in all the subdirectories of the src/lib tree.
-# See ansi/Makefile for a further explanation.
-
-MAKE = exec make -$(MAKEFLAGS)
-ZLIB=zlib-1.2.3
-
-usage:
- @echo "Usage: make all" >&2 # Compile all library functions" >&2
- @echo " make install # Backup /usr/lib/*.a first!" >&2
- @echo " make clean # Delete .o and .a files" >&2
- @false
-
-all:
- cd ansi && $(MAKE)
- cd curses && $(MAKE)
- cd dummy && $(MAKE)
- cd editline && $(MAKE)
- cd end && $(MAKE)
- cd float && $(MAKE)
- cd fphook && $(MAKE)
- cd ip && $(MAKE)
- cd libm2 && $(MAKE)
- cd libp && $(MAKE)
- cd liby && $(MAKE)
- cd math && $(MAKE)
- cd other && $(MAKE)
- cd posix && $(MAKE)
- test `arch` = i86 || { cd regex && $(MAKE); }
- cd rts && $(MAKE)
- cd stdio && $(MAKE)
- cd syscall && $(MAKE)
- cd syslib && $(MAKE)
- cd util && $(MAKE)
- cd sysutil && $(MAKE)
- cd timers && $(MAKE)
- cd $(ZLIB) && $(MAKE)
- cd `arch` && $(MAKE)
-
-install: all
- cd $(ZLIB) && make install
- $(MAKE) install_`arch`
-
-# Installation rules for PC Minix.
-LIB= /usr/lib
-
-install_i86: \
- $(LIB)/ncrtso.o \
- $(LIB)/nm2rtso.o \
- $(LIB)/nprtso.o \
- $(LIB)/libc.a \
- $(LIB)/libd.a \
- $(LIB)/libe.a \
- $(LIB)/libfp.a \
- $(LIB)/libm.a \
- $(LIB)/libm2.a \
- $(LIB)/libp.a \
- $(LIB)/end.a \
- $(LIB)/libsys.a \
- $(LIB)/libtimers.a \
- $(LIB)/util.a \
- $(LIB)/sysutil.a \
- $(LIB)/libcurses.a \
- $(LIB)/libedit.a \
- $(LIB)/liby.a \
-
-$(LIB)/ncrtso.o: ncrtso.o
- install -c -o bin $? $@
-
-$(LIB)/nm2rtso.o: nm2rtso.o
- install -c -o bin $? $@
-
-$(LIB)/nprtso.o: nprtso.o
- install -c -o bin $? $@
-
-$(LIB)/libc.a: libc.a
- install -c -o bin $? $@
-
-$(LIB)/libd.a: libd.a
- install -c -o bin $? $@
-
-$(LIB)/libe.a: libe.a
- install -c -o bin $? $@
-
-$(LIB)/libfp.a: libfp.a
- install -c -o bin $? $@
-
-$(LIB)/libm.a: libm.a
- install -c -o bin $? $@
-
-$(LIB)/libm2.a: libm2.a
- install -c -o bin $? $@
-
-$(LIB)/libp.a: libp.a
- install -c -o bin $? $@
-
-$(LIB)/end.a: end.a
- install -c -o bin $? $@
-
-$(LIB)/libsys.a: libsys.a
- install -c -o bin $? $@
-
-$(LIB)/libtimers.a: libtimers.a
- install -c -o bin $? $@
-
-$(LIB)/libsysutil.a: libsysutil.a
- install -c -o bin $? $@
-
-$(LIB)/libutil.a: libutil.a
- install -c -o bin $? $@
-
-$(LIB)/libcurses.a: libcurses.a
- install -c -o bin $? $@
-
-$(LIB)/libedit.a: libedit.a
- install -c -o bin $? $@
-
-$(LIB)/liby.a: liby.a
- install -c -o bin $? $@
-
-# Installation rules for Minix-386.
-LIB386= /usr/lib/i386
-LIB86= /usr/lib/i86
-
-install_i386: \
- $(LIB386)/crtso.o \
- $(LIB386)/m2rtso.o \
- $(LIB386)/prtso.o \
- $(LIB386)/libc.a \
- $(LIB386)/libd.a \
- $(LIB386)/libe.a \
- $(LIB386)/libfp.a \
- $(LIB386)/libm.a \
- $(LIB386)/libm2.a \
- $(LIB386)/libp.a \
- $(LIB386)/libtimers.a \
- $(LIB386)/end.a \
- $(LIB386)/libsys.a \
- $(LIB386)/libtimers.a \
- $(LIB386)/libutil.a \
- $(LIB386)/libsysutil.a \
- $(LIB386)/libcurses.a \
- $(LIB386)/libedit.a \
- $(LIB386)/liby.a \
-# $(LIB86)/libc.a \
-# $(LIB86)/end.a \
-
-$(LIB386)/crtso.o: crtso.o
- install -c -o bin $? $@
-
-$(LIB386)/m2rtso.o: m2rtso.o
- install -c -o bin $? $@
-
-$(LIB386)/prtso.o: prtso.o
- install -c -o bin $? $@
-
-$(LIB386)/libc.a: libc.a
- install -c -o bin $? $@
-
-$(LIB386)/libd.a: libd.a
- install -c -o bin $? $@
-
-$(LIB386)/libe.a: libe.a
- install -c -o bin $? $@
-
-$(LIB386)/libfp.a: libfp.a
- install -c -o bin $? $@
-
-$(LIB386)/libm.a: libm.a
- install -c -o bin $? $@
-
-$(LIB386)/libm2.a: libm2.a
- install -c -o bin $? $@
-
-$(LIB386)/libp.a: libp.a
- install -c -o bin $? $@
-
-$(LIB386)/end.a: end.a
- install -c -o bin $? $@
-
-$(LIB386)/libsys.a: libsys.a
- install -c -o bin $? $@
-
-$(LIB386)/libtimers.a: libtimers.a
- install -c -o bin $? $@
-
-$(LIB386)/libsysutil.a: libsysutil.a
- install -c -o bin $? $@
-
-$(LIB386)/libutil.a: libutil.a
- install -c -o bin $? $@
-
-$(LIB386)/libcurses.a: libcurses.a
- install -c -o bin $? $@
-
-$(LIB386)/libedit.a: libedit.a
- install -c -o bin $? $@
-
-$(LIB386)/liby.a: liby.a
- install -c -o bin $? $@
-
-#$(LIB86)/libc.a: libc86.a
-# install -c -o bin $? $@
-#
-#$(LIB86)/end.a: end86.a
-# install -c -o bin $? $@
-
-clean:
- find . -name '*.[oa]' -o -name '*.bak' | xargs rm
+ACKBASE=$(CURDIR)/obj-ack
+GNUBASE=$(CURDIR)/obj-gnu
+
+OBJDIR=.
+
+PATH:=$(PATH):/usr/gnu/bin
+
+SUBDIRS = ansi \
+ curses \
+ dummy \
+ editline \
+ end \
+ ip \
+ math \
+ other \
+ posix \
+ regex \
+ stdio \
+ syscall \
+ syslib \
+ util \
+ sysutil \
+ timers \
+ i386 \
+ zlib-1.2.3 \
+ ack \
+ gnu
+
+
+include Makefile.inc
+
+install:: all
+ install -o bin $(ACKBASE)/*.[ao] /usr/lib/i386
+ install -o bin $(GNUBASE)/*.[ao] /usr/gnu/lib
--- /dev/null
+Libraries are compiled for both ack and gcc. If you want to compile them
+for ack only (gcc takes up a lot of memory), please see ackonly/README.
# This Makefile compiles part of the C library, the functions required by the
# ANSI C standard. This Makefile, and those in the other subdirectories use
# a little known feature of make, the ability to refer to a file within a
-# library. The construct 'libc.a(abs.o)' names the file 'abs.o' contained
+# library. The construct abs.o' names the file 'abs.o' contained
# in 'libc.a'. So the rule
#
-# libc.a(abs.o): abs.c
+# abs.o: abs.c
# cc -c abs.c
# aal cr libc.a abs.o
# rm abs.o
# Many of the string functions in this directory are not used, because the
# have fast assembly implementations.
-CFLAGS = -O -D_MINIX -D_POSIX_SOURCE
-CC1 = $(CC) $(CFLAGS) -c
-
-LIBRARY = ../libc.a
-all: $(LIBRARY)
-
-OBJECTS = \
- $(LIBRARY)(abort.o) \
- $(LIBRARY)(abs.o) \
- $(LIBRARY)(asctime.o) \
- $(LIBRARY)(assert.o) \
- $(LIBRARY)(atexit.o) \
- $(LIBRARY)(atof.o) \
- $(LIBRARY)(atoi.o) \
- $(LIBRARY)(atol.o) \
- $(LIBRARY)(bsearch.o) \
- $(LIBRARY)(calloc.o) \
- $(LIBRARY)(chartab.o) \
- $(LIBRARY)(clock.o) \
- $(LIBRARY)(ctime.o) \
- $(LIBRARY)(difftime.o) \
- $(LIBRARY)(div.o) \
- $(LIBRARY)(errlist.o) \
- $(LIBRARY)(exit.o) \
- $(LIBRARY)(ext_comp.o) \
- $(LIBRARY)(getenv.o) \
- $(LIBRARY)(gmtime.o) \
- $(LIBRARY)(isalnum.o) \
- $(LIBRARY)(isalpha.o) \
- $(LIBRARY)(isascii.o) \
- $(LIBRARY)(iscntrl.o) \
- $(LIBRARY)(isdigit.o) \
- $(LIBRARY)(isgraph.o) \
- $(LIBRARY)(islower.o) \
- $(LIBRARY)(isprint.o) \
- $(LIBRARY)(ispunct.o) \
- $(LIBRARY)(isspace.o) \
- $(LIBRARY)(isupper.o) \
- $(LIBRARY)(isxdigit.o) \
- $(LIBRARY)(labs.o) \
- $(LIBRARY)(ldiv.o) \
- $(LIBRARY)(localeconv.o) \
- $(LIBRARY)(localtime.o) \
- $(LIBRARY)(malloc.o) \
- $(LIBRARY)(mblen.o) \
- $(LIBRARY)(mbstowcs.o) \
- $(LIBRARY)(mbtowc.o) \
- $(LIBRARY)(misc.o) \
- $(LIBRARY)(mktime.o) \
- $(LIBRARY)(qsort.o) \
- $(LIBRARY)(raise.o) \
- $(LIBRARY)(rand.o) \
- $(LIBRARY)(setlocale.o) \
- $(LIBRARY)(sigmisc.o) \
- $(LIBRARY)(signal.o) \
- $(LIBRARY)(strcoll.o) \
- $(LIBRARY)(strcspn.o) \
- $(LIBRARY)(strerror.o) \
- $(LIBRARY)(strftime.o) \
- $(LIBRARY)(strpbrk.o) \
- $(LIBRARY)(strspn.o) \
- $(LIBRARY)(strstr.o) \
- $(LIBRARY)(strtok.o) \
- $(LIBRARY)(strtol.o) \
- $(LIBRARY)(strxfrm.o) \
- $(LIBRARY)(system.o) \
- $(LIBRARY)(tolower.o) \
- $(LIBRARY)(toupper.o) \
- $(LIBRARY)(tzset.o) \
- $(LIBRARY)(wcstombs.o) \
- $(LIBRARY)(wctomb.o) \
-
-$(LIBRARY): $(OBJECTS)
- aal cr $@ *.o
- rm *.o
-
-$(LIBRARY)(abort.o): abort.c
- $(CC1) abort.c
-
-$(LIBRARY)(abs.o): abs.c
- $(CC1) abs.c
-
-$(LIBRARY)(asctime.o): asctime.c
- $(CC1) asctime.c
-
-$(LIBRARY)(assert.o): assert.c
- $(CC1) assert.c
-
-$(LIBRARY)(atexit.o): atexit.c
- $(CC1) atexit.c
-
-$(LIBRARY)(atof.o): atof.c
- $(CC1) atof.c
-
-$(LIBRARY)(atoi.o): atoi.c
- $(CC1) atoi.c
-
-$(LIBRARY)(atol.o): atol.c
- $(CC1) atol.c
-
-$(LIBRARY)(bsearch.o): bsearch.c
- $(CC1) bsearch.c
-
-$(LIBRARY)(calloc.o): calloc.c
- $(CC1) calloc.c
-
-$(LIBRARY)(chartab.o): chartab.c
- $(CC1) chartab.c
-
-$(LIBRARY)(clock.o): clock.c
- $(CC1) clock.c
-
-$(LIBRARY)(ctime.o): ctime.c
- $(CC1) ctime.c
-
-$(LIBRARY)(difftime.o): difftime.c
- $(CC1) difftime.c
-
-$(LIBRARY)(div.o): div.c
- $(CC1) div.c
-
-$(LIBRARY)(errlist.o): errlist.c
- $(CC1) errlist.c
-
-$(LIBRARY)(exit.o): exit.c
- $(CC1) exit.c
-
-$(LIBRARY)(ext_comp.o): ext_comp.c
- $(CC1) ext_comp.c
-
-$(LIBRARY)(getenv.o): getenv.c
- $(CC1) getenv.c
-
-$(LIBRARY)(gmtime.o): gmtime.c
- $(CC1) gmtime.c
-
-$(LIBRARY)(isalnum.o): isalnum.c
- $(CC1) isalnum.c
-
-$(LIBRARY)(isalpha.o): isalpha.c
- $(CC1) isalpha.c
-
-$(LIBRARY)(isascii.o): isascii.c
- $(CC1) isascii.c
-
-$(LIBRARY)(iscntrl.o): iscntrl.c
- $(CC1) iscntrl.c
-
-$(LIBRARY)(isdigit.o): isdigit.c
- $(CC1) isdigit.c
-
-$(LIBRARY)(isgraph.o): isgraph.c
- $(CC1) isgraph.c
-
-$(LIBRARY)(islower.o): islower.c
- $(CC1) islower.c
-
-$(LIBRARY)(isprint.o): isprint.c
- $(CC1) isprint.c
-
-$(LIBRARY)(ispunct.o): ispunct.c
- $(CC1) ispunct.c
-
-$(LIBRARY)(isspace.o): isspace.c
- $(CC1) isspace.c
-
-$(LIBRARY)(isupper.o): isupper.c
- $(CC1) isupper.c
-
-$(LIBRARY)(isxdigit.o): isxdigit.c
- $(CC1) isxdigit.c
-
-$(LIBRARY)(labs.o): labs.c
- $(CC1) labs.c
-
-$(LIBRARY)(ldiv.o): ldiv.c
- $(CC1) ldiv.c
-
-$(LIBRARY)(localeconv.o): localeconv.c
- $(CC1) localeconv.c
-
-$(LIBRARY)(localtime.o): localtime.c
- $(CC1) localtime.c
-
-$(LIBRARY)(malloc.o): malloc.c
- $(CC1) malloc.c
-
-$(LIBRARY)(mblen.o): mblen.c
- $(CC1) mblen.c
-
-$(LIBRARY)(mbstowcs.o): mbstowcs.c
- $(CC1) mbstowcs.c
-
-$(LIBRARY)(mbtowc.o): mbtowc.c
- $(CC1) mbtowc.c
-
-$(LIBRARY)(memchr.o): memchr.c
- $(CC1) memchr.c
-
-$(LIBRARY)(memcmp.o): memcmp.c
- $(CC1) memcmp.c
-
-$(LIBRARY)(memcpy.o): memcpy.c
- $(CC1) memcpy.c
-
-$(LIBRARY)(memmove.o): memmove.c
- $(CC1) memmove.c
-
-$(LIBRARY)(memset.o): memset.c
- $(CC1) memset.c
-
-$(LIBRARY)(misc.o): misc.c
- $(CC1) misc.c
-
-$(LIBRARY)(mktime.o): mktime.c
- $(CC1) mktime.c
-
-$(LIBRARY)(qsort.o): qsort.c
- $(CC1) qsort.c
-
-$(LIBRARY)(raise.o): raise.c
- $(CC1) raise.c
-
-$(LIBRARY)(rand.o): rand.c
- $(CC1) rand.c
-
-$(LIBRARY)(setlocale.o): setlocale.c
- $(CC1) setlocale.c
-
-$(LIBRARY)(sigmisc.o): sigmisc.c
- $(CC1) sigmisc.c
-
-$(LIBRARY)(signal.o): signal.c
- $(CC1) signal.c
-
-$(LIBRARY)(strcat.o): strcat.c
- $(CC1) strcat.c
-
-$(LIBRARY)(strchr.o): strchr.c
- $(CC1) strchr.c
-
-$(LIBRARY)(strcmp.o): strcmp.c
- $(CC1) strcmp.c
-
-$(LIBRARY)(strcoll.o): strcoll.c
- $(CC1) strcoll.c
-
-$(LIBRARY)(strcpy.o): strcpy.c
- $(CC1) strcpy.c
-
-$(LIBRARY)(strcspn.o): strcspn.c
- $(CC1) strcspn.c
-
-$(LIBRARY)(strerror.o): strerror.c
- $(CC1) strerror.c
-
-$(LIBRARY)(strftime.o): strftime.c
- $(CC1) strftime.c
-
-$(LIBRARY)(strlen.o): strlen.c
- $(CC1) strlen.c
-
-$(LIBRARY)(strncat.o): strncat.c
- $(CC1) strncat.c
-
-$(LIBRARY)(strncmp.o): strncmp.c
- $(CC1) strncmp.c
-
-$(LIBRARY)(strncpy.o): strncpy.c
- $(CC1) strncpy.c
-
-$(LIBRARY)(strpbrk.o): strpbrk.c
- $(CC1) strpbrk.c
-
-$(LIBRARY)(strrchr.o): strrchr.c
- $(CC1) strrchr.c
-
-$(LIBRARY)(strspn.o): strspn.c
- $(CC1) strspn.c
-
-$(LIBRARY)(strstr.o): strstr.c
- $(CC1) strstr.c
-
-$(LIBRARY)(strtok.o): strtok.c
- $(CC1) strtok.c
-
-$(LIBRARY)(strtol.o): strtol.c
- $(CC1) strtol.c
-
-$(LIBRARY)(strxfrm.o): strxfrm.c
- $(CC1) strxfrm.c
-
-$(LIBRARY)(system.o): system.c
- $(CC1) system.c
-
-$(LIBRARY)(tolower.o): tolower.c
- $(CC1) tolower.c
-
-$(LIBRARY)(toupper.o): toupper.c
- $(CC1) toupper.c
-
-$(LIBRARY)(tzset.o): tzset.c
- $(CC1) tzset.c
-
-$(LIBRARY)(wcstombs.o): wcstombs.c
- $(CC1) wcstombs.c
-
-$(LIBRARY)(wctomb.o): wctomb.c
- $(CC1) wctomb.c
+CFLAGS = -O -D_MINIX -D_POSIX_SOURCE -D__USG
+
+LIBRARIES = libc
+libc_OBJECTS = \
+ abort.o \
+ abs.o \
+ asctime.o \
+ assert.o \
+ atexit.o \
+ atof.o \
+ atoi.o \
+ atol.o \
+ bsearch.o \
+ calloc.o \
+ chartab.o \
+ clock.o \
+ ctime.o \
+ difftime.o \
+ div.o \
+ errlist.o \
+ exit.o \
+ ext_comp.o \
+ getenv.o \
+ gmtime.o \
+ isalnum.o \
+ isalpha.o \
+ isascii.o \
+ iscntrl.o \
+ isdigit.o \
+ isgraph.o \
+ islower.o \
+ isprint.o \
+ ispunct.o \
+ isspace.o \
+ isupper.o \
+ isxdigit.o \
+ labs.o \
+ ldiv.o \
+ localeconv.o \
+ localtime.o \
+ malloc.o \
+ mblen.o \
+ mbstowcs.o \
+ mbtowc.o \
+ misc.o \
+ mktime.o \
+ qsort.o \
+ raise.o \
+ rand.o \
+ setlocale.o \
+ sigmisc.o \
+ signal.o \
+ strcoll.o \
+ strcspn.o \
+ strerror.o \
+ strftime.o \
+ strpbrk.o \
+ strspn.o \
+ strstr.o \
+ strtok.o \
+ strtol.o \
+ strxfrm.o \
+ system.o \
+ tolower.o \
+ toupper.o \
+ tzset.o \
+ wcstombs.o \
+ wctomb.o
+
+include ../Makefile.inc
# Makefile for lib/curses.
CFLAGS = -O -D_MINIX -D_POSIX_SOURCE
-CC1 = $(CC) $(CFLAGS) -c
-LIBRARY = ../libcurses.a
-all: $(LIBRARY)
-
-OBJECTS = \
- $(LIBRARY)(beep.o) \
- $(LIBRARY)(charpick.o) \
- $(LIBRARY)(curs_set.o) \
- $(LIBRARY)(cursesio.o) \
- $(LIBRARY)(endwin.o) \
- $(LIBRARY)(flash.o) \
- $(LIBRARY)(initscr.o) \
- $(LIBRARY)(longname.o) \
- $(LIBRARY)(move.o) \
- $(LIBRARY)(mvcursor.o) \
- $(LIBRARY)(newwin.o) \
- $(LIBRARY)(options.o) \
- $(LIBRARY)(overlay.o) \
- $(LIBRARY)(prntscan.o) \
- $(LIBRARY)(refresh.o) \
- $(LIBRARY)(scrreg.o) \
- $(LIBRARY)(setterm.o) \
- $(LIBRARY)(tabsize.o) \
- $(LIBRARY)(termmisc.o) \
- $(LIBRARY)(unctrl.o) \
- $(LIBRARY)(update.o) \
- $(LIBRARY)(waddch.o) \
- $(LIBRARY)(waddstr.o) \
- $(LIBRARY)(wbox.o) \
- $(LIBRARY)(wclear.o) \
- $(LIBRARY)(wclrtobot.o) \
- $(LIBRARY)(wclrtoeol.o) \
- $(LIBRARY)(wdelch.o) \
- $(LIBRARY)(wdeleteln.o) \
- $(LIBRARY)(werase.o) \
- $(LIBRARY)(wgetch.o) \
- $(LIBRARY)(wgetstr.o) \
- $(LIBRARY)(windel.o) \
- $(LIBRARY)(winmove.o) \
- $(LIBRARY)(winsch.o) \
- $(LIBRARY)(winscrol.o) \
- $(LIBRARY)(winsertln.o) \
- $(LIBRARY)(wintouch.o) \
-
-$(LIBRARY): $(OBJECTS)
- aal cr $@ *.o
- rm *.o
-
-$(LIBRARY)(beep.o): beep.c
- $(CC1) beep.c
-
-$(LIBRARY)(charpick.o): charpick.c
- $(CC1) charpick.c
-
-$(LIBRARY)(curs_set.o): curs_set.c
- $(CC1) curs_set.c
-
-$(LIBRARY)(cursesio.o): cursesio.c
- $(CC1) cursesio.c
-
-$(LIBRARY)(endwin.o): endwin.c
- $(CC1) endwin.c
-
-$(LIBRARY)(flash.o): flash.c
- $(CC1) flash.c
-
-$(LIBRARY)(initscr.o): initscr.c
- $(CC1) initscr.c
-
-$(LIBRARY)(longname.o): longname.c
- $(CC1) longname.c
-
-$(LIBRARY)(move.o): move.c
- $(CC1) move.c
-
-$(LIBRARY)(mvcursor.o): mvcursor.c
- $(CC1) mvcursor.c
-
-$(LIBRARY)(newwin.o): newwin.c
- $(CC1) newwin.c
-
-$(LIBRARY)(options.o): options.c
- $(CC1) options.c
-
-$(LIBRARY)(overlay.o): overlay.c
- $(CC1) overlay.c
-
-$(LIBRARY)(prntscan.o): prntscan.c
- $(CC1) prntscan.c
-
-$(LIBRARY)(refresh.o): refresh.c
- $(CC1) refresh.c
-
-$(LIBRARY)(scrreg.o): scrreg.c
- $(CC1) scrreg.c
-
-$(LIBRARY)(setterm.o): setterm.c
- $(CC1) setterm.c
-
-$(LIBRARY)(tabsize.o): tabsize.c
- $(CC1) tabsize.c
-
-$(LIBRARY)(termmisc.o): termmisc.c
- $(CC1) termmisc.c
-
-$(LIBRARY)(unctrl.o): unctrl.c
- $(CC1) unctrl.c
-
-$(LIBRARY)(update.o): update.c
- $(CC1) update.c
-
-$(LIBRARY)(waddch.o): waddch.c
- $(CC1) waddch.c
-
-$(LIBRARY)(waddstr.o): waddstr.c
- $(CC1) waddstr.c
-
-$(LIBRARY)(wbox.o): wbox.c
- $(CC1) wbox.c
-
-$(LIBRARY)(wclear.o): wclear.c
- $(CC1) wclear.c
-
-$(LIBRARY)(wclrtobot.o): wclrtobot.c
- $(CC1) wclrtobot.c
-
-$(LIBRARY)(wclrtoeol.o): wclrtoeol.c
- $(CC1) wclrtoeol.c
-
-$(LIBRARY)(wdelch.o): wdelch.c
- $(CC1) wdelch.c
-
-$(LIBRARY)(wdeleteln.o): wdeleteln.c
- $(CC1) wdeleteln.c
-
-$(LIBRARY)(werase.o): werase.c
- $(CC1) werase.c
-
-$(LIBRARY)(wgetch.o): wgetch.c
- $(CC1) wgetch.c
-
-$(LIBRARY)(wgetstr.o): wgetstr.c
- $(CC1) wgetstr.c
-
-$(LIBRARY)(windel.o): windel.c
- $(CC1) windel.c
-
-$(LIBRARY)(winmove.o): winmove.c
- $(CC1) winmove.c
-
-$(LIBRARY)(winsch.o): winsch.c
- $(CC1) winsch.c
-
-$(LIBRARY)(winscrol.o): winscrol.c
- $(CC1) winscrol.c
-
-$(LIBRARY)(winsertln.o): winsertln.c
- $(CC1) winsertln.c
-
-$(LIBRARY)(wintouch.o): wintouch.c
- $(CC1) wintouch.c
+LIBRARIES = libcurses
+
+libcurses_OBJECTS = \
+ beep.o \
+ charpick.o \
+ curs_set.o \
+ cursesio.o \
+ endwin.o \
+ flash.o \
+ initscr.o \
+ longname.o \
+ move.o \
+ mvcursor.o \
+ newwin.o \
+ options.o \
+ overlay.o \
+ prntscan.o \
+ refresh.o \
+ scrreg.o \
+ setterm.o \
+ tabsize.o \
+ termmisc.o \
+ unctrl.o \
+ update.o \
+ waddch.o \
+ waddstr.o \
+ wbox.o \
+ wclear.o \
+ wclrtobot.o \
+ wclrtoeol.o \
+ wdelch.o \
+ wdeleteln.o \
+ werase.o \
+ wgetch.o \
+ wgetstr.o \
+ windel.o \
+ winmove.o \
+ winsch.o \
+ winscrol.o \
+ winsertln.o \
+ wintouch.o \
+
+include ../Makefile.inc
-## Makefile for lib/dummy.
-#
-## Make a dummy libm library so that -lm works.
-#
-#
-#LIBRARIES=libm
-#
-#libm_OBJECTS=dummy.o
-#
-#include ../Makefile.inc
-#
-#dummy.c:
-# echo "int __dummy__;" > $@
-#
+# Makefile for lib/dummy.
-all: ../libm.a
+# Make a dummy libm library so that -lm works.
-../libm.a:
- echo "int __dummy__;" >dummy.c
- $(CC) -c dummy.c
- aal cr $@ dummy.o
- rm dummy.?
+
+LIBRARIES=libm
+
+libm_OBJECTS=dummy.o
+
+include ../Makefile.inc
+
+dummy.c:
+ echo "int __dummy__;" > $@
## Unix makefile for editline library.
##
+
## Set your options:
## -DANSI_ARROWS ANSI arrows keys work like emacs.
## -DHAVE_STDLIB Have <stdlib.h>.
-## -DHAVE_TCGETATTR Have tcgetattr(), tcsetattr().
+## -DHAVE_TCGETATTR Have , .
## -DHAVE_TERMIO Have "struct termio" and <termio.h>
## (If neither of above two, we use <sgttyb.h> and BSD ioctl's)
## -DHIDE Make static functions static (non debug).
## -DHIST_SIZE=n History size.
-## -DNEED_STRDUP Don't have strdup().
+## -DNEED_STRDUP Don't have .
## -DUNIQUE_HISTORY Don't save command if same as last one.
## -DUSE_DIRENT Use <dirent.h>, not <sys/dir.h>?
## -DUSE_TERMCAP Use the termcap library for terminal size
## see LDFLAGS, below, if you set this.
-## -DNEED_PERROR Don't have perror() (used in testit)
+## -DNEED_PERROR Don't have (used in testit)
DEFS = -DANSI_ARROWS -DHAVE_STDLIB -DHAVE_TCGETATTR -DHIDE -DUSE_DIRENT \
- -DHIST_SIZE=100 -DUSE_TERMCAP -DSYS_UNIX -DNEED_STRDUP
+ -DHIST_SIZE=100 -DUSE_TERMCAP -DSYS_UNIX
+#-DNEED_STRDUP
CFLAGS = -O -D_MINIX -D_POSIX_SOURCE $(DEFS) -wo
CC1 = $(CC) $(CFLAGS) -c
## End of configuration.
SOURCES = editline.c complete.c sysunix.c
-LIBRARY = ../libedit.a
-OBJECTS = $(LIBRARY)(editline.o) $(LIBRARY)(complete.o) $(LIBRARY)(sysunix.o)
+#LIBRARY = ../libedit.a
+LIBRARIES = libedit
+#OBJECTS = editline.o complete.o sysunix.o
+libedit_OBJECTS = editline.o complete.o sysunix.o
SHARFILES = README Makefile editline.3 editline.h unix.h editline.c \
- complete.c sysunix.c testit.c
-
-install: $(LIBRARY)
-
-testit: testit.c $(LIBRARY)
- $(CC) $(CFLAGS) -o testit testit.c $(LIBRARY) $(LDFLAGS)
-
-shar: $(SHARFILES)
- shar $(SHARFILES) >shar
-
-clean:
- rm -f *.[oa] testit foo core tags lint lint.all a.out shar
-
-lint: testit
- lint -a -b -u -x $(DEFS) $(SOURCES) testit.c >lint.all
- sed -e '/warning: function prototype not in scope/d' \
- -e '/warning: old style argument declaration/'d \
- -e '/mix of old and new style function declaration/'d \
- <lint.all >lint
-
-$(LIBRARY): $(OBJECTS)
- aal cr $@ *.o
- rm *.o
-
-$(OBJECTS): editline.h
-
-$(LIBRARY)(editline.o): editline.c
- $(CC1) editline.c
-$(LIBRARY)(complete.o): complete.c
- $(CC1) complete.c
+include ../Makefile.inc
-$(LIBRARY)(sysunix.o): sysunix.c
- $(CC1) sysunix.c
+$(call ADDDEPENDENCIES,$(libedit_OBJECTS),editline.h)
# Makefile for lib/end.
-CC1 = $(CC) -c
+LIBRARIES = end
-LIBRARY = ../end.a
-all: $(LIBRARY)
+end_OBJECTS = \
+ edata.o \
+ em_end.o \
+ end.o \
+ etext.o \
-OBJECTS = \
- $(LIBRARY)(edata.o) \
- $(LIBRARY)(em_end.o) \
- $(LIBRARY)(end.o) \
- $(LIBRARY)(etext.o) \
-
-$(LIBRARY): $(OBJECTS)
- aal cr $@ *.o
- rm *.o
-
-$(LIBRARY)(edata.o): edata.s
- $(CC1) edata.s
-
-$(LIBRARY)(em_end.o): em_end.s
- $(CC1) em_end.s
-
-$(LIBRARY)(end.o): end.s
- $(CC1) end.s
-
-$(LIBRARY)(etext.o): etext.s
- $(CC1) etext.s
+include ../Makefile.inc
# Makefile for lib/i386.
-MAKE = exec make -$(MAKEFLAGS)
+SUBDIRS = \
+ int64 \
+ misc \
+ rts \
+ string
-install:
- cd em && $(MAKE)
- cd head && $(MAKE)
- cd int64 && $(MAKE)
- cd misc && $(MAKE)
- cd rts && $(MAKE)
- cd string && $(MAKE)
+include ../Makefile.inc
# Makefile for lib/i386/int64.
-CFLAGS = -O -D_MINIX -D_POSIX_SOURCE -Was-ack
-CC1 = $(CC) $(CFLAGS) -c
-
-LIBRARY = ../../libc.a
-all: $(LIBRARY)
-
-OBJECTS = \
- $(LIBRARY)(add64.o) \
- $(LIBRARY)(add64u.o) \
- $(LIBRARY)(cmp64.o) \
- $(LIBRARY)(cv64u.o) \
- $(LIBRARY)(cvu64.o) \
- $(LIBRARY)(diff64.o) \
- $(LIBRARY)(div64u.o) \
- $(LIBRARY)(ex64.o) \
- $(LIBRARY)(make64.o) \
- $(LIBRARY)(mul64u.o) \
- $(LIBRARY)(sub64.o) \
- $(LIBRARY)(sub64u.o) \
-
-$(LIBRARY): $(OBJECTS)
- aal cr $@ *.o
- rm *.o
-
-$(LIBRARY)(add64.o): add64.s
- $(CC1) add64.s
-
-$(LIBRARY)(add64u.o): add64u.s
- $(CC1) add64u.s
-
-$(LIBRARY)(cmp64.o): cmp64.s
- $(CC1) cmp64.s
-
-$(LIBRARY)(cv64u.o): cv64u.s
- $(CC1) cv64u.s
-
-$(LIBRARY)(cvu64.o): cvu64.s
- $(CC1) cvu64.s
-
-$(LIBRARY)(diff64.o): diff64.s
- $(CC1) diff64.s
-
-$(LIBRARY)(div64u.o): div64u.s
- $(CC1) div64u.s
-
-$(LIBRARY)(ex64.o): ex64.s
- $(CC1) ex64.s
-
-$(LIBRARY)(make64.o): make64.s
- $(CC1) make64.s
-
-$(LIBRARY)(mul64u.o): mul64u.s
- $(CC1) mul64u.s
-
-$(LIBRARY)(sub64.o): sub64.s
- $(CC1) sub64.s
-
-$(LIBRARY)(sub64u.o): sub64u.s
- $(CC1) sub64u.s
+CFLAGS = -O -D_MINIX -D_POSIX_SOURCE
+
+LIBRARIES = libc
+
+libc_OBJECTS = \
+ add64.o \
+ add64u.o \
+ cmp64.o \
+ cv64u.o \
+ cvu64.o \
+ diff64.o \
+ div64u.o \
+ ex64.o \
+ make64.o \
+ mul64u.o \
+ sub64.o \
+ sub64u.o \
+
+include ../../Makefile.inc
# Makefile for lib/i386/misc.
-CFLAGS = -O -D_MINIX -D_POSIX_SOURCE -Was-ack
-CC1 = $(CC) $(CFLAGS) -c
-
-LIBRARY = ../../libc.a
-all: $(LIBRARY)
-
-OBJECTS = \
- $(LIBRARY)(alloca.o) \
- $(LIBRARY)(get_bp.o) \
- $(LIBRARY)(getprocessor.o) \
- $(LIBRARY)(io_inb.o) \
- $(LIBRARY)(io_inl.o) \
- $(LIBRARY)(io_insb.o) \
- $(LIBRARY)(io_insl.o) \
- $(LIBRARY)(io_insw.o) \
- $(LIBRARY)(io_intr.o) \
- $(LIBRARY)(io_inw.o) \
- $(LIBRARY)(io_outb.o) \
- $(LIBRARY)(io_outl.o) \
- $(LIBRARY)(io_outsb.o) \
- $(LIBRARY)(io_outsl.o) \
- $(LIBRARY)(io_outsw.o) \
- $(LIBRARY)(io_outw.o) \
- $(LIBRARY)(oneC_sum.o) \
-
-$(LIBRARY): $(OBJECTS)
- aal cr $@ *.o
- rm *.o
-
-$(LIBRARY)(alloca.o): alloca.s
- $(CC1) alloca.s
-
-$(LIBRARY)(get_bp.o): get_bp.s
- $(CC1) get_bp.s
-
-$(LIBRARY)(getprocessor.o): getprocessor.s
- $(CC1) getprocessor.s
-
-$(LIBRARY)(io_inb.o): io_inb.s
- $(CC1) io_inb.s
-
-$(LIBRARY)(io_inl.o): io_inl.s
- $(CC1) io_inl.s
-
-$(LIBRARY)(io_insb.o): io_insb.s
- $(CC1) io_insb.s
-
-$(LIBRARY)(io_insl.o): io_insl.s
- $(CC1) io_insl.s
-
-$(LIBRARY)(io_insw.o): io_insw.s
- $(CC1) io_insw.s
-
-$(LIBRARY)(io_intr.o): io_intr.s
- $(CC1) io_intr.s
-
-$(LIBRARY)(io_inw.o): io_inw.s
- $(CC1) io_inw.s
-
-$(LIBRARY)(io_outb.o): io_outb.s
- $(CC1) io_outb.s
-
-$(LIBRARY)(io_outl.o): io_outl.s
- $(CC1) io_outl.s
-
-$(LIBRARY)(io_outsb.o): io_outsb.s
- $(CC1) io_outsb.s
-
-$(LIBRARY)(io_outsl.o): io_outsl.s
- $(CC1) io_outsl.s
-
-$(LIBRARY)(io_outsw.o): io_outsw.s
- $(CC1) io_outsw.s
-
-$(LIBRARY)(io_outw.o): io_outw.s
- $(CC1) io_outw.s
-
-$(LIBRARY)(oneC_sum.o): oneC_sum.s
- $(CC1) oneC_sum.s
+CFLAGS = -O -D_MINIX -D_POSIX_SOURCE
+
+LIBRARIES = libc
+
+libc_OBJECTS = \
+ alloca.o \
+ get_bp.o \
+ getprocessor.o \
+ io_inb.o \
+ io_inl.o \
+ io_insb.o \
+ io_insl.o \
+ io_insw.o \
+ io_intr.o \
+ io_inw.o \
+ io_outb.o \
+ io_outl.o \
+ io_outsb.o \
+ io_outsl.o \
+ io_outsw.o \
+ io_outw.o \
+ oneC_sum.o \
+
+include ../../Makefile.inc
# Makefile for lib/i386/rts.
-CFLAGS = -O -D_MINIX -D_POSIX_SOURCE -Was-ack
-CC1 = $(CC) $(CFLAGS) -c
+CFLAGS = -O -D_MINIX -D_POSIX_SOURCE
-LIBRARY = ../../libc.a
+LIBRARIES = libc
-all: \
- ../../crtso.o \
- ../../m2rtso.o \
- ../../prtso.o \
- $(LIBRARY)
+libc_OBJECTS = \
+ __sigreturn.o \
+ _ipc.o \
+ brksize.o \
+
+TOPLEVEL_OBJECTS = \
+ crtso.o \
+ m2rtso.o \
+ prtso.o \
-../../crtso.o: crtso.s
- $(CC1) -c crtso.s
- mv crtso.o $@
-
-../../m2rtso.o: m2rtso.s
- $(CC1) -c m2rtso.s
- mv m2rtso.o $@
-
-../../prtso.o: prtso.s
- $(CC1) -c prtso.s
- mv prtso.o $@
-
-OBJECTS = \
- $(LIBRARY)(__sigreturn.o) \
- $(LIBRARY)(_ipc.o) \
- $(LIBRARY)(brksize.o) \
-
-$(LIBRARY): $(OBJECTS)
- aal cr $@ *.o
- rm *.o
-
-$(LIBRARY)(__sigreturn.o): __sigreturn.s
- $(CC1) __sigreturn.s
-
-$(LIBRARY)(_ipc.o): _ipc.s
- $(CC1) _ipc.s
-
-$(LIBRARY)(brksize.o): brksize.s
- $(CC1) brksize.s
+include ../../Makefile.inc
.sect .bss
begbss:
-.define crtso, ___main, __penviron, __penvp, __fpu_present
+.define crtso, __penviron, __penvp, __fpu_present
.extern _main, _exit
.sect .text
crtso:
hlt ! force a trap if exit fails
-___main: ! for GCC
- ret
-
.sect .rom
.data4 0 ! Separate I&D: *NULL == 0
! Also keeps the first string in the
# Makefile for lib/i386/string.
-CC1 = $(CC) -Was-ack -c
-
-LIBRARY = ../../libc.a
-all: $(LIBRARY)
-
-OBJECTS = \
- $(LIBRARY)(_memmove.o) \
- $(LIBRARY)(_strncat.o) \
- $(LIBRARY)(_strncmp.o) \
- $(LIBRARY)(_strncpy.o) \
- $(LIBRARY)(_strnlen.o) \
- $(LIBRARY)(bcmp.o) \
- $(LIBRARY)(bcopy.o) \
- $(LIBRARY)(bzero.o) \
- $(LIBRARY)(index.o) \
- $(LIBRARY)(memchr.o) \
- $(LIBRARY)(memcmp.o) \
- $(LIBRARY)(memcpy.o) \
- $(LIBRARY)(memmove.o) \
- $(LIBRARY)(memset.o) \
- $(LIBRARY)(rindex.o) \
- $(LIBRARY)(strcat.o) \
- $(LIBRARY)(strchr.o) \
- $(LIBRARY)(strcmp.o) \
- $(LIBRARY)(strcpy.o) \
- $(LIBRARY)(strlen.o) \
- $(LIBRARY)(strncat.o) \
- $(LIBRARY)(strncmp.o) \
- $(LIBRARY)(strncpy.o) \
- $(LIBRARY)(strnlen.o) \
- $(LIBRARY)(strrchr.o) \
-
-$(LIBRARY): $(OBJECTS)
- aal cr $@ *.o
- rm *.o
-
-$(LIBRARY)(_memmove.o): _memmove.s
- $(CC1) _memmove.s
-
-$(LIBRARY)(_strncat.o): _strncat.s
- $(CC1) _strncat.s
-
-$(LIBRARY)(_strncmp.o): _strncmp.s
- $(CC1) _strncmp.s
-
-$(LIBRARY)(_strncpy.o): _strncpy.s
- $(CC1) _strncpy.s
-
-$(LIBRARY)(_strnlen.o): _strnlen.s
- $(CC1) _strnlen.s
-
-$(LIBRARY)(bcmp.o): bcmp.s
- $(CC1) bcmp.s
-
-$(LIBRARY)(bcopy.o): bcopy.s
- $(CC1) bcopy.s
-
-$(LIBRARY)(bzero.o): bzero.s
- $(CC1) bzero.s
-
-$(LIBRARY)(index.o): index.s
- $(CC1) index.s
-
-$(LIBRARY)(memchr.o): memchr.s
- $(CC1) memchr.s
-
-$(LIBRARY)(memcmp.o): memcmp.s
- $(CC1) memcmp.s
-
-$(LIBRARY)(memcpy.o): memcpy.s
- $(CC1) memcpy.s
-
-$(LIBRARY)(memmove.o): memmove.s
- $(CC1) memmove.s
-
-$(LIBRARY)(memset.o): memset.s
- $(CC1) memset.s
-
-$(LIBRARY)(rindex.o): rindex.s
- $(CC1) rindex.s
-
-$(LIBRARY)(strcat.o): strcat.s
- $(CC1) strcat.s
-
-$(LIBRARY)(strchr.o): strchr.s
- $(CC1) strchr.s
-
-$(LIBRARY)(strcmp.o): strcmp.s
- $(CC1) strcmp.s
-
-$(LIBRARY)(strcpy.o): strcpy.s
- $(CC1) strcpy.s
-
-$(LIBRARY)(strlen.o): strlen.s
- $(CC1) strlen.s
-
-$(LIBRARY)(strncat.o): strncat.s
- $(CC1) strncat.s
-
-$(LIBRARY)(strncmp.o): strncmp.s
- $(CC1) strncmp.s
-
-$(LIBRARY)(strncpy.o): strncpy.s
- $(CC1) strncpy.s
-
-$(LIBRARY)(strnlen.o): strnlen.s
- $(CC1) strnlen.s
-
-$(LIBRARY)(strrchr.o): strrchr.s
- $(CC1) strrchr.s
+LIBRARIES = libc
+
+libc_OBJECTS = \
+ _memmove.o \
+ _strncat.o \
+ _strncmp.o \
+ _strncpy.o \
+ _strnlen.o \
+ bcmp.o \
+ bcopy.o \
+ bzero.o \
+ index.o \
+ memchr.o \
+ memcmp.o \
+ memcpy.o \
+ memmove.o \
+ memset.o \
+ rindex.o \
+ strcat.o \
+ strchr.o \
+ strcmp.o \
+ strcpy.o \
+ strlen.o \
+ strncat.o \
+ strncmp.o \
+ strncpy.o \
+ strnlen.o \
+ strrchr.o \
+
+include ../../Makefile.inc
# Note: The oneC_sum.c file is not used if there is an assembly equivalent.
CFLAGS = -O -D_MINIX -D_POSIX_SOURCE -I. -DNDEBUG
-CC1 = $(CC) $(CFLAGS) -c
-MAKE = exec make -$(MAKEFLAGS)
-LIBRARY = ../libc.a
-all: $(LIBRARY)
-
-OBJECTS = \
- $(LIBRARY)(accept.o) \
- $(LIBRARY)(bind.o) \
- $(LIBRARY)(connect.o) \
- $(LIBRARY)(dhcp_gettag.o) \
- $(LIBRARY)(dhcp_settag.o) \
- $(LIBRARY)(ether_line.o) \
- $(LIBRARY)(ethera2n.o) \
- $(LIBRARY)(ethere2a.o) \
- $(LIBRARY)(etherh2n.o) \
- $(LIBRARY)(ethern2h.o) \
- $(LIBRARY)(getdomain.o) \
- $(LIBRARY)(gethnmadr.o) \
- $(LIBRARY)(gethostent.o) \
- $(LIBRARY)(gethostname.o) \
- $(LIBRARY)(getnetent.o) \
- $(LIBRARY)(getnetbyname.o) \
- $(LIBRARY)(getnetbyaddr.o) \
- $(LIBRARY)(getpeername.o) \
- $(LIBRARY)(getproto.o) \
- $(LIBRARY)(getprotoent.o) \
- $(LIBRARY)(getservent.o) \
- $(LIBRARY)(getsockname.o) \
- $(LIBRARY)(getsockopt.o) \
- $(LIBRARY)(getsrvbyname.o) \
- $(LIBRARY)(getsrvbyport.o) \
- $(LIBRARY)(hton.o) \
- $(LIBRARY)(inet_addr.o) \
- $(LIBRARY)(inet_network.o) \
- $(LIBRARY)(inet_ntoa.o) \
- $(LIBRARY)(listen.o) \
- $(LIBRARY)(memcspn.o) \
- $(LIBRARY)(rcmd.o) \
- $(LIBRARY)(recv.o) \
- $(LIBRARY)(recvfrom.o) \
- $(LIBRARY)(res_comp.o) \
- $(LIBRARY)(res_init.o) \
- $(LIBRARY)(res_mkquery.o) \
- $(LIBRARY)(res_query.o) \
- $(LIBRARY)(res_send.o) \
- $(LIBRARY)(ruserok.o) \
- $(LIBRARY)(send.o) \
- $(LIBRARY)(sendto.o) \
- $(LIBRARY)(sethostent.o) \
- $(LIBRARY)(setsockopt.o) \
- $(LIBRARY)(servxcheck.o) \
- $(LIBRARY)(shutdown.o) \
- $(LIBRARY)(socket.o) \
- $(LIBRARY)(strcasecmp.o) \
-
-$(LIBRARY): $(OBJECTS)
- aal cr $@ *.o
- rm *.o
-
-$(LIBRARY)(accept.o): accept.c
- $(CC1) accept.c
-
-$(LIBRARY)(bind.o): bind.c
- $(CC1) bind.c
-
-$(LIBRARY)(connect.o): connect.c
- $(CC1) connect.c
-
-$(LIBRARY)(dhcp_gettag.o): dhcp_gettag.c
- $(CC1) dhcp_gettag.c
-
-$(LIBRARY)(dhcp_settag.o): dhcp_settag.c
- $(CC1) dhcp_settag.c
-
-$(LIBRARY)(ether_line.o): ether_line.c
- $(CC1) ether_line.c
-
-$(LIBRARY)(ethera2n.o): ethera2n.c
- $(CC1) ethera2n.c
-
-$(LIBRARY)(ethere2a.o): ethere2a.c
- $(CC1) ethere2a.c
-
-$(LIBRARY)(etherh2n.o): etherh2n.c
- $(CC1) etherh2n.c
-
-$(LIBRARY)(ethern2h.o): ethern2h.c
- $(CC1) ethern2h.c
-
-$(LIBRARY)(getdomain.o): getdomain.c
- $(CC1) getdomain.c
-
-$(LIBRARY)(gethnmadr.o): gethnmadr.c
- $(CC1) gethnmadr.c
-
-$(LIBRARY)(gethostent.o): gethostent.c
- $(CC1) gethostent.c
-
-$(LIBRARY)(gethostname.o): gethostname.c
- $(CC1) gethostname.c
-
-$(LIBRARY)(getnetent.o): getnetent.c
- $(CC1) getnetent.c
-
-$(LIBRARY)(getnetbyname.o): getnetbyname.c
- $(CC1) getnetbyname.c
-
-$(LIBRARY)(getnetbyaddr.o): getnetbyaddr.c
- $(CC1) getnetbyaddr.c
-
-$(LIBRARY)(getpeername.o): getpeername.c
- $(CC1) getpeername.c
-
-$(LIBRARY)(getproto.o): getproto.c
- $(CC1) getproto.c
-
-$(LIBRARY)(getprotoent.o): getprotoent.c
- $(CC1) getprotoent.c
-
-$(LIBRARY)(getservent.o): getservent.c
- $(CC1) getservent.c
-
-$(LIBRARY)(getsockname.o): getsockname.c
- $(CC1) getsockname.c
-
-$(LIBRARY)(getsockopt.o): getsockopt.c
- $(CC1) getsockopt.c
-
-$(LIBRARY)(getsrvbyname.o): getsrvbyname.c
- $(CC1) getsrvbyname.c
-
-$(LIBRARY)(getsrvbyport.o): getsrvbyport.c
- $(CC1) getsrvbyport.c
-
-$(LIBRARY)(hton.o): hton.c
- $(CC1) hton.c
-
-$(LIBRARY)(inet_addr.o): inet_addr.c
- $(CC1) inet_addr.c
-
-$(LIBRARY)(inet_network.o): inet_network.c
- $(CC1) inet_network.c
-
-$(LIBRARY)(inet_ntoa.o): inet_ntoa.c
- $(CC1) inet_ntoa.c
-
-$(LIBRARY)(listen.o): listen.c
- $(CC1) listen.c
-
-$(LIBRARY)(memcspn.o): memcspn.c
- $(CC1) memcspn.c
-
-$(LIBRARY)(oneC_sum.o): oneC_sum.c
- $(CC1) oneC_sum.c
-
-$(LIBRARY)(rcmd.o): rcmd.c
- $(CC1) rcmd.c
-
-$(LIBRARY)(recv.o): recv.c
- $(CC1) recv.c
-
-$(LIBRARY)(recvfrom.o): recvfrom.c
- $(CC1) recvfrom.c
-
-$(LIBRARY)(res_comp.o): res_comp.c
- $(CC1) res_comp.c
-
-$(LIBRARY)(res_init.o): res_init.c
- $(CC1) res_init.c
-
-$(LIBRARY)(res_mkquery.o): res_mkquery.c
- $(CC1) res_mkquery.c
-
-$(LIBRARY)(res_query.o): res_query.c
- $(CC1) res_query.c
-
-$(LIBRARY)(res_send.o): res_send.c
- $(CC1) res_send.c
-
-$(LIBRARY)(ruserok.o): ruserok.c
- $(CC1) ruserok.c
-
-$(LIBRARY)(send.o): send.c
- $(CC1) send.c
-
-$(LIBRARY)(sendto.o): sendto.c
- $(CC1) sendto.c
-
-$(LIBRARY)(sethostent.o): sethostent.c
- $(CC1) sethostent.c
-
-$(LIBRARY)(setsockopt.o): setsockopt.c
- $(CC1) setsockopt.c
-
-$(LIBRARY)(servxcheck.o): servxcheck.c
- $(CC1) servxcheck.c
-
-$(LIBRARY)(shutdown.o): shutdown.c
- $(CC1) shutdown.c
-
-$(LIBRARY)(socket.o): socket.c
- $(CC1) socket.c
-
-$(LIBRARY)(strcasecmp.o): strcasecmp.c
- $(CC1) strcasecmp.c
+LIBRARIES = libc
+
+libc_OBJECTS = \
+ accept.o \
+ bind.o \
+ connect.o \
+ dhcp_gettag.o \
+ dhcp_settag.o \
+ ether_line.o \
+ ethera2n.o \
+ ethere2a.o \
+ etherh2n.o \
+ ethern2h.o \
+ getdomain.o \
+ gethnmadr.o \
+ gethostent.o \
+ gethostname.o \
+ getnetent.o \
+ getnetbyname.o \
+ getnetbyaddr.o \
+ getpeername.o \
+ getproto.o \
+ getprotoent.o \
+ getservent.o \
+ getsockname.o \
+ getsockopt.o \
+ getsrvbyname.o \
+ getsrvbyport.o \
+ hton.o \
+ inet_addr.o \
+ inet_network.o \
+ inet_ntoa.o \
+ listen.o \
+ memcspn.o \
+ rcmd.o \
+ recv.o \
+ recvfrom.o \
+ res_comp.o \
+ res_init.o \
+ res_mkquery.o \
+ res_query.o \
+ res_send.o \
+ ruserok.o \
+ send.o \
+ sendto.o \
+ sethostent.o \
+ setsockopt.o \
+ servxcheck.o \
+ shutdown.o \
+ socket.o \
+ strcasecmp.o \
+
+include ../Makefile.inc
# Makefile for lib/math.
CFLAGS = -O -D_MINIX -D_POSIX_SOURCE
-CC1 = $(CC) $(CFLAGS) -c
-LIBRARY = ../libc.a
-all: $(LIBRARY)
-
-OBJECTS = \
- $(LIBRARY)(asin.o) \
- $(LIBRARY)(atan.o) \
- $(LIBRARY)(atan2.o) \
- $(LIBRARY)(ceil.o) \
- $(LIBRARY)(exp.o) \
- $(LIBRARY)(fabs.o) \
- $(LIBRARY)(floor.o) \
- $(LIBRARY)(fmod.o) \
- $(LIBRARY)(frexp.o) \
- $(LIBRARY)(hugeval.o) \
- $(LIBRARY)(isnan.o) \
- $(LIBRARY)(ldexp.o) \
- $(LIBRARY)(log.o) \
- $(LIBRARY)(log10.o) \
- $(LIBRARY)(modf.o) \
- $(LIBRARY)(pow.o) \
- $(LIBRARY)(sin.o) \
- $(LIBRARY)(sinh.o) \
- $(LIBRARY)(sqrt.o) \
- $(LIBRARY)(tan.o) \
- $(LIBRARY)(tanh.o) \
-
-$(LIBRARY): $(OBJECTS)
- aal cr $@ *.o
- rm *.o
-
-$(LIBRARY)(asin.o): asin.c
- $(CC1) asin.c
-
-$(LIBRARY)(atan.o): atan.c
- $(CC1) atan.c
-
-$(LIBRARY)(atan2.o): atan2.c
- $(CC1) atan2.c
-
-$(LIBRARY)(ceil.o): ceil.c
- $(CC1) ceil.c
-
-$(LIBRARY)(exp.o): exp.c
- $(CC1) exp.c
-
-$(LIBRARY)(fabs.o): fabs.c
- $(CC1) fabs.c
-
-$(LIBRARY)(floor.o): floor.c
- $(CC1) floor.c
-
-$(LIBRARY)(fmod.o): fmod.c
- $(CC1) fmod.c
-
-$(LIBRARY)(frexp.o): frexp.s
- $(CC1) frexp.s
-
-$(LIBRARY)(hugeval.o): hugeval.c
- $(CC1) hugeval.c
-
-$(LIBRARY)(isnan.o): isnan.c
- $(CC1) isnan.c
-
-$(LIBRARY)(ldexp.o): ldexp.c
- $(CC1) ldexp.c
-
-$(LIBRARY)(log.o): log.c
- $(CC1) log.c
-
-$(LIBRARY)(log10.o): log10.c
- $(CC1) log10.c
-
-$(LIBRARY)(modf.o): modf.s
- $(CC1) modf.s
-
-$(LIBRARY)(pow.o): pow.c
- $(CC1) pow.c
-
-$(LIBRARY)(sin.o): sin.c
- $(CC1) sin.c
-
-$(LIBRARY)(sinh.o): sinh.c
- $(CC1) sinh.c
-
-$(LIBRARY)(sqrt.o): sqrt.c
- $(CC1) sqrt.c
-
-$(LIBRARY)(tan.o): tan.c
- $(CC1) tan.c
-
-$(LIBRARY)(tanh.o): tanh.c
- $(CC1) tanh.c
+LIBRARIES = libc
+
+libc_OBJECTS = \
+ asin.o \
+ atan.o \
+ atan2.o \
+ ceil.o \
+ exp.o \
+ fabs.o \
+ floor.o \
+ fmod.o \
+ hugeval.o \
+ log.o \
+ log10.o \
+ pow.o \
+ sin.o \
+ sinh.o \
+ sqrt.o \
+ tan.o \
+ tanh.o \
+
+include ../Makefile.inc
# Makefile for lib/other.
-# The bxxx(), and *index() functions are not used, because they have assembly
-# equivalents.
-
CFLAGS = -O -D_MINIX -D_POSIX_SOURCE -I../../servers
-CC1 = $(CC) $(CFLAGS) -c
-
-LIBRARY = ../libc.a
-all: $(LIBRARY)
-
-OBJECTS = \
- $(LIBRARY)(_allocmem.o) \
- $(LIBRARY)(_freemem.o) \
- $(LIBRARY)(_brk.o) \
- $(LIBRARY)(_reboot.o) \
- $(LIBRARY)(_seekdir.o) \
- $(LIBRARY)(_svrctl.o) \
- $(LIBRARY)(_getsysinfo.o) \
- $(LIBRARY)(_getprocnr.o) \
- $(LIBRARY)(_getpprocnr.o) \
- $(LIBRARY)(_getnprocnr.o) \
- $(LIBRARY)(_getnpid.o) \
- $(LIBRARY)(_devctl.o) \
- $(LIBRARY)(_findproc.o) \
- $(LIBRARY)(asynchio.o) \
- $(LIBRARY)(basename.o) \
- $(LIBRARY)(configfile.o) \
- $(LIBRARY)(crypt.o) \
- $(LIBRARY)(ctermid.o) \
- $(LIBRARY)(cuserid.o) \
- $(LIBRARY)(environ.o) \
- $(LIBRARY)(errno.o) \
- $(LIBRARY)(fdopen.o) \
- $(LIBRARY)(ffs.o) \
- $(LIBRARY)(fslib.o) \
- $(LIBRARY)(fsversion.o) \
- $(LIBRARY)(getgrent.o) \
- $(LIBRARY)(getlogin.o) \
- $(LIBRARY)(getopt.o) \
- $(LIBRARY)(getpagesize.o) \
- $(LIBRARY)(getpass.o) \
- $(LIBRARY)(getpwent.o) \
- $(LIBRARY)(getttyent.o) \
- $(LIBRARY)(getw.o) \
- $(LIBRARY)(hypot.o) \
- $(LIBRARY)(itoa.o) \
- $(LIBRARY)(loadname.o) \
- $(LIBRARY)(lock.o) \
- $(LIBRARY)(lrand.o) \
- $(LIBRARY)(lsearch.o) \
- $(LIBRARY)(memccpy.o) \
- $(LIBRARY)(mstats.o) \
- $(LIBRARY)(mtab.o) \
- $(LIBRARY)(nlist.o) \
- $(LIBRARY)(peekpoke.o) \
- $(LIBRARY)(popen.o) \
- $(LIBRARY)(putenv.o) \
- $(LIBRARY)(putw.o) \
- $(LIBRARY)(random.o) \
- $(LIBRARY)(setgroups.o) \
- $(LIBRARY)(settimeofday.o) \
- $(LIBRARY)(stderr.o) \
- $(LIBRARY)(strdup.o) \
- $(LIBRARY)(strtok_r.o) \
- $(LIBRARY)(swab.o) \
- $(LIBRARY)(syscall.o) \
- $(LIBRARY)(sysconf.o) \
- $(LIBRARY)(sys_eniop.o) \
- $(LIBRARY)(taskcall.o) \
- $(LIBRARY)(telldir.o) \
- $(LIBRARY)(termcap.o) \
- $(LIBRARY)(ttyname.o) \
- $(LIBRARY)(ttyslot.o) \
- $(LIBRARY)(v8regexp.o) \
- $(LIBRARY)(v8regsub.o) \
-
-$(LIBRARY): $(OBJECTS)
- aal cr $@ *.o
- rm *.o
-
-$(LIBRARY)(_allocmem.o): _allocmem.c
- $(CC1) _allocmem.c
-
-$(LIBRARY)(_freemem.o): _freemem.c
- $(CC1) _freemem.c
-
-$(LIBRARY)(_brk.o): _brk.c
- $(CC1) _brk.c
-
-$(LIBRARY)(_reboot.o): _reboot.c
- $(CC1) _reboot.c
-
-$(LIBRARY)(_seekdir.o): _seekdir.c
- $(CC1) _seekdir.c
-
-$(LIBRARY)(_svrctl.o): _svrctl.c
- $(CC1) _svrctl.c
-
-$(LIBRARY)(_devctl.o): _devctl.c
- $(CC1) _devctl.c
-
-$(LIBRARY)(_getnpid.o): _getnpid.c
- $(CC1) _getnpid.c
-
-$(LIBRARY)(_getprocnr.o): _getprocnr.c
- $(CC1) _getprocnr.c
-
-$(LIBRARY)(_getpprocnr.o): _getpprocnr.c
- $(CC1) _getpprocnr.c
-
-$(LIBRARY)(_getnprocnr.o): _getnprocnr.c
- $(CC1) _getnprocnr.c
-
-$(LIBRARY)(_findproc.o): _findproc.c
- $(CC1) _findproc.c
-
-$(LIBRARY)(_getsysinfo.o): _getsysinfo.c
- $(CC1) _getsysinfo.c
-
-$(LIBRARY)(asynchio.o): asynchio.c
- $(CC1) asynchio.c
-
-$(LIBRARY)(basename.o): basename.c
- $(CC1) basename.c
-
-$(LIBRARY)(bcmp.o): bcmp.c
- $(CC1) bcmp.c
-
-$(LIBRARY)(bcopy.o): bcopy.c
- $(CC1) bcopy.c
-
-$(LIBRARY)(bzero.o): bzero.c
- $(CC1) bzero.c
-
-$(LIBRARY)(configfile.o): configfile.c
- $(CC1) configfile.c
-
-$(LIBRARY)(crypt.o): crypt.c
- $(CC1) crypt.c
-
-$(LIBRARY)(ctermid.o): ctermid.c
- $(CC1) ctermid.c
-
-$(LIBRARY)(cuserid.o): cuserid.c
- $(CC1) cuserid.c
-
-$(LIBRARY)(environ.o): environ.c
- $(CC1) environ.c
-
-$(LIBRARY)(errno.o): errno.c
- $(CC1) errno.c
-
-$(LIBRARY)(fdopen.o): fdopen.c
- $(CC1) fdopen.c
-
-$(LIBRARY)(ffs.o): ffs.c
- $(CC1) ffs.c
-
-$(LIBRARY)(fslib.o): fslib.c
- $(CC1) fslib.c
-
-$(LIBRARY)(fsversion.o): fsversion.c
- $(CC1) fsversion.c
-
-$(LIBRARY)(getgrent.o): getgrent.c
- $(CC1) getgrent.c
-
-$(LIBRARY)(getlogin.o): getlogin.c
- $(CC1) getlogin.c
-
-$(LIBRARY)(getopt.o): getopt.c
- $(CC1) getopt.c
-
-$(LIBRARY)(getpagesize.o): getpagesize.c
- $(CC1) getpagesize.c
-
-$(LIBRARY)(getpass.o): getpass.c
- $(CC1) getpass.c
-
-$(LIBRARY)(getpwent.o): getpwent.c
- $(CC1) getpwent.c
-
-$(LIBRARY)(getttyent.o): getttyent.c
- $(CC1) getttyent.c
-
-$(LIBRARY)(getw.o): getw.c
- $(CC1) getw.c
-
-$(LIBRARY)(hypot.o): hypot.c
- $(CC1) hypot.c
-
-$(LIBRARY)(index.o): index.c
- $(CC1) index.c
-
-$(LIBRARY)(itoa.o): itoa.c
- $(CC1) itoa.c
-
-$(LIBRARY)(loadname.o): loadname.c
- $(CC1) loadname.c
-
-$(LIBRARY)(lock.o): lock.c
- $(CC1) lock.c
-
-$(LIBRARY)(lrand.o): lrand.c
- $(CC1) lrand.c
-
-$(LIBRARY)(lsearch.o): lsearch.c
- $(CC1) lsearch.c
-
-$(LIBRARY)(memccpy.o): memccpy.c
- $(CC1) memccpy.c
-
-$(LIBRARY)(mstats.o): mstats.c
- $(CC1) mstats.c
-
-$(LIBRARY)(mtab.o): mtab.c
- $(CC1) mtab.c
-
-$(LIBRARY)(nlist.o): nlist.c
- $(CC1) nlist.c
-
-$(LIBRARY)(peekpoke.o): peekpoke.c
- $(CC1) peekpoke.c
-
-$(LIBRARY)(popen.o): popen.c
- $(CC1) popen.c
-
-$(LIBRARY)(putenv.o): putenv.c
- $(CC1) putenv.c
-
-$(LIBRARY)(putw.o): putw.c
- $(CC1) putw.c
-
-$(LIBRARY)(rindex.o): rindex.c
- $(CC1) rindex.c
-
-$(LIBRARY)(random.o): random.c
- $(CC1) random.c
-
-$(LIBRARY)(setgroups.o): setgroups.c
- $(CC1) setgroups.c
-
-$(LIBRARY)(settimeofday.o): settimeofday.c
- $(CC1) settimeofday.c
-
-$(LIBRARY)(stderr.o): stderr.c
- $(CC1) stderr.c
-
-$(LIBRARY)(strdup.o): strdup.c
- $(CC1) strdup.c
-
-$(LIBRARY)(strtok_r.o): strtok_r.c
- $(CC1) strtok_r.c
-
-$(LIBRARY)(swab.o): swab.c
- $(CC1) swab.c
-
-$(LIBRARY)(syscall.o): syscall.c
- $(CC1) syscall.c
-
-$(LIBRARY)(sysconf.o): sysconf.c
- $(CC1) sysconf.c
-
-$(LIBRARY)(syslib.o): syslib.c
- $(CC1) syslib.c
-
-$(LIBRARY)(sys_eniop.o): sys_eniop.c
- $(CC1) sys_eniop.c
-
-$(LIBRARY)(taskcall.o): taskcall.c
- $(CC1) taskcall.c
-
-$(LIBRARY)(telldir.o): telldir.c
- $(CC1) telldir.c
-
-$(LIBRARY)(termcap.o): termcap.c
- $(CC1) termcap.c
-
-$(LIBRARY)(ttyname.o): ttyname.c
- $(CC1) ttyname.c
-
-$(LIBRARY)(ttyslot.o): ttyslot.c
- $(CC1) ttyslot.c
-
-$(LIBRARY)(v8regexp.o): v8regexp.c
- $(CC1) v8regexp.c
-
-$(LIBRARY)(v8regsub.o): v8regsub.c
- $(CC1) v8regsub.c
-$(LIBRARY)(writev.o): writev.c
- $(CC1) writev.c
+LIBRARIES = libc
+
+libc_OBJECTS = \
+ _allocmem.o \
+ _freemem.o \
+ _brk.o \
+ _reboot.o \
+ _seekdir.o \
+ _svrctl.o \
+ _getsysinfo.o \
+ _getprocnr.o \
+ _getnpid.o \
+ _getnprocnr.o \
+ _getpprocnr.o \
+ _devctl.o \
+ _findproc.o \
+ asynchio.o \
+ basename.o \
+ configfile.o \
+ crypt.o \
+ ctermid.o \
+ cuserid.o \
+ environ.o \
+ errno.o \
+ fdopen.o \
+ ffs.o \
+ fslib.o \
+ fsversion.o \
+ getgrent.o \
+ getlogin.o \
+ getopt.o \
+ getpagesize.o \
+ getpass.o \
+ getpwent.o \
+ getttyent.o \
+ getw.o \
+ hypot.o \
+ itoa.o \
+ loadname.o \
+ lock.o \
+ lrand.o \
+ lsearch.o \
+ memccpy.o \
+ mstats.o \
+ mtab.o \
+ nlist.o \
+ peekpoke.o \
+ popen.o \
+ putenv.o \
+ putw.o \
+ random.o \
+ setgroups.o \
+ settimeofday.o \
+ stderr.o \
+ strdup.o \
+ strtok_r.o \
+ swab.o \
+ syscall.o \
+ sysconf.o \
+ telldir.o \
+ termcap.o \
+ ttyname.o \
+ ttyslot.o \
+ v8regexp.o \
+ v8regsub.o \
+
+include ../Makefile.inc
# Makefile for lib/posix.
CFLAGS = -O -D_MINIX -D_POSIX_SOURCE
-CC1 = $(CC) $(CFLAGS) -c
-
-LIBRARY = ../libc.a
-all: $(LIBRARY)
-
-OBJECTS = \
- $(LIBRARY)(__exit.o) \
- $(LIBRARY)(_access.o) \
- $(LIBRARY)(_alarm.o) \
- $(LIBRARY)(_cfgetispeed.o) \
- $(LIBRARY)(_cfgetospeed.o) \
- $(LIBRARY)(_cfsetispeed.o) \
- $(LIBRARY)(_cfsetospeed.o) \
- $(LIBRARY)(_chdir.o) \
- $(LIBRARY)(_chmod.o) \
- $(LIBRARY)(_chown.o) \
- $(LIBRARY)(_chroot.o) \
- $(LIBRARY)(_close.o) \
- $(LIBRARY)(_closedir.o) \
- $(LIBRARY)(_creat.o) \
- $(LIBRARY)(_dup.o) \
- $(LIBRARY)(_dup2.o) \
- $(LIBRARY)(_execl.o) \
- $(LIBRARY)(_execle.o) \
- $(LIBRARY)(_execlp.o) \
- $(LIBRARY)(_execv.o) \
- $(LIBRARY)(_execve.o) \
- $(LIBRARY)(_execvp.o) \
- $(LIBRARY)(_fcntl.o) \
- $(LIBRARY)(_fork.o) \
- $(LIBRARY)(_fpathconf.o) \
- $(LIBRARY)(_fstat.o) \
- $(LIBRARY)(_fstatfs.o) \
- $(LIBRARY)(_fsync.o) \
- $(LIBRARY)(_getcwd.o) \
- $(LIBRARY)(_getegid.o) \
- $(LIBRARY)(_geteuid.o) \
- $(LIBRARY)(_getgid.o) \
- $(LIBRARY)(_getgroups.o) \
- $(LIBRARY)(_getpgrp.o) \
- $(LIBRARY)(_getpid.o) \
- $(LIBRARY)(_getppid.o) \
- $(LIBRARY)(_getuid.o) \
- $(LIBRARY)(_ioctl.o) \
- $(LIBRARY)(_isatty.o) \
- $(LIBRARY)(_kill.o) \
- $(LIBRARY)(_link.o) \
- $(LIBRARY)(_lseek.o) \
- $(LIBRARY)(_mkdir.o) \
- $(LIBRARY)(_mkfifo.o) \
- $(LIBRARY)(_mknod.o) \
- $(LIBRARY)(_mktemp.o) \
- $(LIBRARY)(_mount.o) \
- $(LIBRARY)(_open.o) \
- $(LIBRARY)(_opendir.o) \
- $(LIBRARY)(_pathconf.o) \
- $(LIBRARY)(_pause.o) \
- $(LIBRARY)(_pipe.o) \
- $(LIBRARY)(_ptrace.o) \
- $(LIBRARY)(_read.o) \
- $(LIBRARY)(_readdir.o) \
- $(LIBRARY)(_rename.o) \
- $(LIBRARY)(_rewinddir.o) \
- $(LIBRARY)(_rmdir.o) \
- $(LIBRARY)(_select.o) \
- $(LIBRARY)(_setgid.o) \
- $(LIBRARY)(_setsid.o) \
- $(LIBRARY)(_setuid.o) \
- $(LIBRARY)(_sigaction.o) \
- $(LIBRARY)(_sigpending.o) \
- $(LIBRARY)(_sigprocmask.o) \
- $(LIBRARY)(_sigreturn.o) \
- $(LIBRARY)(_sigset.o) \
- $(LIBRARY)(_sigsetjmp.o) \
- $(LIBRARY)(_sigsuspend.o) \
- $(LIBRARY)(_sleep.o) \
- $(LIBRARY)(_stat.o) \
- $(LIBRARY)(_stime.o) \
- $(LIBRARY)(_sync.o) \
- $(LIBRARY)(_tcdrain.o) \
- $(LIBRARY)(_tcflow.o) \
- $(LIBRARY)(_tcflush.o) \
- $(LIBRARY)(_tcgetattr.o) \
- $(LIBRARY)(_tcsendbreak.o) \
- $(LIBRARY)(_tcsetattr.o) \
- $(LIBRARY)(_time.o) \
- $(LIBRARY)(_times.o) \
- $(LIBRARY)(_umask.o) \
- $(LIBRARY)(_umount.o) \
- $(LIBRARY)(_uname.o) \
- $(LIBRARY)(_unlink.o) \
- $(LIBRARY)(_utime.o) \
- $(LIBRARY)(_wait.o) \
- $(LIBRARY)(_waitpid.o) \
- $(LIBRARY)(_write.o) \
- $(LIBRARY)(gettimeofday.o) \
- $(LIBRARY)(getopt.o) \
- $(LIBRARY)(lstat.o) \
- $(LIBRARY)(priority.o) \
- $(LIBRARY)(readlink.o) \
- $(LIBRARY)(symlink.o) \
- $(LIBRARY)(usleep.o) \
-
-$(LIBRARY): $(OBJECTS)
- aal cr $@ *.o
- rm *.o
-
-$(LIBRARY)(__exit.o): __exit.c
- $(CC1) __exit.c
-
-$(LIBRARY)(_access.o): _access.c
- $(CC1) _access.c
-
-$(LIBRARY)(_alarm.o): _alarm.c
- $(CC1) _alarm.c
-
-$(LIBRARY)(_cfgetispeed.o): _cfgetispeed.c
- $(CC1) _cfgetispeed.c
-
-$(LIBRARY)(_cfgetospeed.o): _cfgetospeed.c
- $(CC1) _cfgetospeed.c
-
-$(LIBRARY)(_cfsetispeed.o): _cfsetispeed.c
- $(CC1) _cfsetispeed.c
-
-$(LIBRARY)(_cfsetospeed.o): _cfsetospeed.c
- $(CC1) _cfsetospeed.c
-
-$(LIBRARY)(_chdir.o): _chdir.c
- $(CC1) _chdir.c
-
-$(LIBRARY)(_chmod.o): _chmod.c
- $(CC1) _chmod.c
-
-$(LIBRARY)(_chown.o): _chown.c
- $(CC1) _chown.c
-
-$(LIBRARY)(_chroot.o): _chroot.c
- $(CC1) _chroot.c
-
-$(LIBRARY)(_close.o): _close.c
- $(CC1) _close.c
-
-$(LIBRARY)(_closedir.o): _closedir.c
- $(CC1) _closedir.c
-
-$(LIBRARY)(_creat.o): _creat.c
- $(CC1) _creat.c
-
-$(LIBRARY)(_dup.o): _dup.c
- $(CC1) _dup.c
-
-$(LIBRARY)(_dup2.o): _dup2.c
- $(CC1) _dup2.c
-
-$(LIBRARY)(_execl.o): _execl.c
- $(CC1) _execl.c
-
-$(LIBRARY)(_execle.o): _execle.c
- $(CC1) _execle.c
-
-$(LIBRARY)(_execlp.o): _execlp.c
- $(CC1) _execlp.c
-
-$(LIBRARY)(_execv.o): _execv.c
- $(CC1) _execv.c
-
-$(LIBRARY)(_execve.o): _execve.c
- $(CC1) _execve.c
-
-$(LIBRARY)(_execvp.o): _execvp.c
- $(CC1) _execvp.c
-
-$(LIBRARY)(_fcntl.o): _fcntl.c
- $(CC1) _fcntl.c
-
-$(LIBRARY)(_fork.o): _fork.c
- $(CC1) _fork.c
-
-$(LIBRARY)(_fpathconf.o): _fpathconf.c
- $(CC1) _fpathconf.c
-
-$(LIBRARY)(_fstat.o): _fstat.c
- $(CC1) _fstat.c
-
-$(LIBRARY)(_fsync.o): _fsync.c
- $(CC1) _fsync.c
-
-$(LIBRARY)(_fstatfs.o): _fstatfs.c
- $(CC1) _fstatfs.c
-
-$(LIBRARY)(_getcwd.o): _getcwd.c
- $(CC1) _getcwd.c
-
-$(LIBRARY)(_getegid.o): _getegid.c
- $(CC1) _getegid.c
-
-$(LIBRARY)(_geteuid.o): _geteuid.c
- $(CC1) _geteuid.c
-
-$(LIBRARY)(_getgid.o): _getgid.c
- $(CC1) _getgid.c
-
-$(LIBRARY)(_getgroups.o): _getgroups.c
- $(CC1) _getgroups.c
-
-$(LIBRARY)(_getpgrp.o): _getpgrp.c
- $(CC1) _getpgrp.c
-
-$(LIBRARY)(_getpid.o): _getpid.c
- $(CC1) _getpid.c
-
-$(LIBRARY)(_getppid.o): _getppid.c
- $(CC1) _getppid.c
-
-$(LIBRARY)(_getuid.o): _getuid.c
- $(CC1) _getuid.c
-
-$(LIBRARY)(_ioctl.o): _ioctl.c
- $(CC1) _ioctl.c
-
-$(LIBRARY)(_isatty.o): _isatty.c
- $(CC1) _isatty.c
-
-$(LIBRARY)(_kill.o): _kill.c
- $(CC1) _kill.c
-
-$(LIBRARY)(_link.o): _link.c
- $(CC1) _link.c
-
-$(LIBRARY)(_lseek.o): _lseek.c
- $(CC1) _lseek.c
-
-$(LIBRARY)(_mkdir.o): _mkdir.c
- $(CC1) _mkdir.c
-
-$(LIBRARY)(_mkfifo.o): _mkfifo.c
- $(CC1) _mkfifo.c
-
-$(LIBRARY)(_mknod.o): _mknod.c
- $(CC1) _mknod.c
-
-$(LIBRARY)(_mktemp.o): _mktemp.c
- $(CC1) _mktemp.c
-
-$(LIBRARY)(_mount.o): _mount.c
- $(CC1) _mount.c
-
-$(LIBRARY)(_open.o): _open.c
- $(CC1) _open.c
-
-$(LIBRARY)(_opendir.o): _opendir.c
- $(CC1) _opendir.c
-
-$(LIBRARY)(_pathconf.o): _pathconf.c
- $(CC1) _pathconf.c
-
-$(LIBRARY)(_pause.o): _pause.c
- $(CC1) _pause.c
-
-$(LIBRARY)(_pipe.o): _pipe.c
- $(CC1) _pipe.c
-
-$(LIBRARY)(_ptrace.o): _ptrace.c
- $(CC1) _ptrace.c
-
-$(LIBRARY)(_read.o): _read.c
- $(CC1) _read.c
-
-$(LIBRARY)(_readdir.o): _readdir.c
- $(CC1) _readdir.c
-
-$(LIBRARY)(_rename.o): _rename.c
- $(CC1) _rename.c
-
-$(LIBRARY)(_rewinddir.o): _rewinddir.c
- $(CC1) _rewinddir.c
-
-$(LIBRARY)(_rmdir.o): _rmdir.c
- $(CC1) _rmdir.c
-
-$(LIBRARY)(_select.o): _select.c
- $(CC1) _select.c
-
-$(LIBRARY)(_setgid.o): _setgid.c
- $(CC1) _setgid.c
-
-$(LIBRARY)(_setsid.o): _setsid.c
- $(CC1) _setsid.c
-
-$(LIBRARY)(_setuid.o): _setuid.c
- $(CC1) _setuid.c
-
-$(LIBRARY)(_sigaction.o): _sigaction.c
- $(CC1) _sigaction.c
-
-$(LIBRARY)(_sigpending.o): _sigpending.c
- $(CC1) _sigpending.c
-
-$(LIBRARY)(_sigprocmask.o): _sigprocmask.c
- $(CC1) _sigprocmask.c
-
-$(LIBRARY)(_sigreturn.o): _sigreturn.c
- $(CC1) _sigreturn.c
-
-$(LIBRARY)(_sigset.o): _sigset.c
- $(CC1) _sigset.c
-
-$(LIBRARY)(_sigsetjmp.o): _sigsetjmp.c
- $(CC1) _sigsetjmp.c
-
-$(LIBRARY)(_sigsuspend.o): _sigsuspend.c
- $(CC1) _sigsuspend.c
-
-$(LIBRARY)(_sleep.o): _sleep.c
- $(CC1) _sleep.c
-
-$(LIBRARY)(_stat.o): _stat.c
- $(CC1) _stat.c
-
-$(LIBRARY)(_stime.o): _stime.c
- $(CC1) _stime.c
-
-$(LIBRARY)(_sync.o): _sync.c
- $(CC1) _sync.c
-
-$(LIBRARY)(_tcdrain.o): _tcdrain.c
- $(CC1) _tcdrain.c
-
-$(LIBRARY)(_tcflow.o): _tcflow.c
- $(CC1) _tcflow.c
-
-$(LIBRARY)(_tcflush.o): _tcflush.c
- $(CC1) _tcflush.c
-
-$(LIBRARY)(_tcgetattr.o): _tcgetattr.c
- $(CC1) _tcgetattr.c
-
-$(LIBRARY)(_tcsendbreak.o): _tcsendbreak.c
- $(CC1) _tcsendbreak.c
-
-$(LIBRARY)(_tcsetattr.o): _tcsetattr.c
- $(CC1) _tcsetattr.c
-
-$(LIBRARY)(_time.o): _time.c
- $(CC1) _time.c
-
-$(LIBRARY)(_times.o): _times.c
- $(CC1) _times.c
-
-$(LIBRARY)(_umask.o): _umask.c
- $(CC1) _umask.c
-
-$(LIBRARY)(_umount.o): _umount.c
- $(CC1) _umount.c
-
-$(LIBRARY)(_uname.o): _uname.c /usr/include/minix/config.h
- $(CC1) _uname.c
-
-$(LIBRARY)(_unlink.o): _unlink.c
- $(CC1) _unlink.c
-
-$(LIBRARY)(_utime.o): _utime.c
- $(CC1) _utime.c
-
-$(LIBRARY)(_wait.o): _wait.c
- $(CC1) _wait.c
-
-$(LIBRARY)(_waitpid.o): _waitpid.c
- $(CC1) _waitpid.c
-
-$(LIBRARY)(_write.o): _write.c
- $(CC1) _write.c
-
-$(LIBRARY)(gettimeofday.o): gettimeofday.c
- $(CC1) gettimeofday.c
-
-$(LIBRARY)(getopt.o): getopt.c
- $(CC1) getopt.c
-
-$(LIBRARY)(priority.o): priority.c
- $(CC1) priority.c
-
-$(LIBRARY)(readlink.o): readlink.c
- $(CC1) readlink.c
-
-$(LIBRARY)(lstat.o): lstat.c
- $(CC1) lstat.c
-
-$(LIBRARY)(symlink.o): symlink.c
- $(CC1) symlink.c
-
-$(LIBRARY)(usleep.o): usleep.c
- $(CC1) usleep.c
+LIBRARIES = libc
+
+libc_OBJECTS = \
+ __exit.o \
+ _access.o \
+ _alarm.o \
+ _cfgetispeed.o \
+ _cfgetospeed.o \
+ _cfsetispeed.o \
+ _cfsetospeed.o \
+ _chdir.o \
+ _chmod.o \
+ _chown.o \
+ _chroot.o \
+ _close.o \
+ _closedir.o \
+ _creat.o \
+ _dup.o \
+ _dup2.o \
+ _execl.o \
+ _execle.o \
+ _execlp.o \
+ _execv.o \
+ _execve.o \
+ _execvp.o \
+ _fcntl.o \
+ _fork.o \
+ _fpathconf.o \
+ _fstat.o \
+ _fstatfs.o \
+ _fsync.o \
+ _getcwd.o \
+ _getegid.o \
+ _geteuid.o \
+ _getgid.o \
+ _getgroups.o \
+ _getpgrp.o \
+ _getpid.o \
+ _getppid.o \
+ _getuid.o \
+ _ioctl.o \
+ _isatty.o \
+ _kill.o \
+ _link.o \
+ _lseek.o \
+ _mkdir.o \
+ _mkfifo.o \
+ _mknod.o \
+ _mount.o \
+ _open.o \
+ _opendir.o \
+ _pathconf.o \
+ _pause.o \
+ _pipe.o \
+ _ptrace.o \
+ _read.o \
+ _readdir.o \
+ _rename.o \
+ _rewinddir.o \
+ _rmdir.o \
+ _select.o \
+ _setgid.o \
+ _setsid.o \
+ _setuid.o \
+ _sigaction.o \
+ _sigpending.o \
+ _sigprocmask.o \
+ _sigreturn.o \
+ _sigset.o \
+ _sigsuspend.o \
+ _sleep.o \
+ _stat.o \
+ _stime.o \
+ _sync.o \
+ _tcdrain.o \
+ _tcflow.o \
+ _tcflush.o \
+ _tcgetattr.o \
+ _tcsendbreak.o \
+ _tcsetattr.o \
+ _time.o \
+ _times.o \
+ _umask.o \
+ _umount.o \
+ _uname.o \
+ _unlink.o \
+ _utime.o \
+ _wait.o \
+ _waitpid.o \
+ _write.o \
+ gettimeofday.o \
+ getopt.o \
+ lstat.o \
+ priority.o \
+ readlink.o \
+ symlink.o \
+ usleep.o \
+
+include ../Makefile.inc
+
+$(call ADDDEPENDENCIES,_uname.o,/usr/include/minix/config.h)
PUBLIC void _exit(status)
int status;
{
+ void (*suicide)(void);
message m;
m.m1_i1 = status;
_syscall(MM, EXIT, &m);
+
+ /* If exiting nicely through PM fails for some reason, try to
+ * commit suicide. E.g., message to PM might fail due to deadlock.
+ */
+ suicide = (void (*)(void)) -1;
+ suicide();
+
+ /* If committing suicide fails for some reason, hang. */
+ for(;;) { }
}
+
+++ /dev/null
-/* mktemp - make a name for a temporary file */
-
-#include <lib.h>
-#define access _access
-#define getpid _getpid
-#define mktemp _mktemp
-#include <unistd.h>
-
-PUBLIC char *mktemp(template)
-char *template;
-{
- register int k;
- register char *p;
- register pid_t pid;
-
- pid = getpid(); /* get process id as semi-unique number */
- p = template;
- while (*p != 0) p++; /* find end of string */
-
- /* Replace XXXXXX at end of template with a letter, then as many of the
- * trailing digits of the pid as fit.
- */
- while (*--p == 'X') {
- *p = '0' + (pid % 10);
- pid /= 10;
- }
- if (*++p != 0) {
- for (k = 'a'; k <= 'z'; k++) {
- *p = k;
- if (access(template, F_OK) < 0) return(template);
- }
- }
- return("/");
-}
# Makefile for lib/regex.
CFLAGS = -O -D_MINIX -D_POSIX_SOURCE
-CC1 = $(CC) $(CFLAGS) -c
-LIBRARY = ../libc.a
+LIBRARIES = libc
-all: $(LIBRARY)
+libc_OBJECTS = \
+ regcomp.o \
+ regerror.o \
+ regexec.o \
+ regfree.o \
-OBJ = \
- $(LIBRARY)(regcomp.o) \
- $(LIBRARY)(regerror.o) \
- $(LIBRARY)(regexec.o) \
- $(LIBRARY)(regfree.o) \
-
-$(LIBRARY): $(OBJ)
- aal cr $@ *.o
- rm *.o
-
-$(LIBRARY)(regcomp.o): regcomp.c
- $(CC1) regcomp.c
-
-$(LIBRARY)(regerror.o): regerror.c
- $(CC1) regerror.c
-
-$(LIBRARY)(regexec.o): regexec.c
- $(CC1) regexec.c
-
-$(LIBRARY)(regfree.o): regfree.c
- $(CC1) regfree.c
+include ../Makefile.inc
# Makefile for lib/stdio.
CFLAGS = -O -D_MINIX -D_POSIX_SOURCE
-CC1 = $(CC) $(CFLAGS) -c
-LIBRARY = ../libc.a
-all: $(LIBRARY)
-
-OBJECTS = \
- $(LIBRARY)(clearerr.o) \
- $(LIBRARY)(data.o) \
- $(LIBRARY)(doprnt.o) \
- $(LIBRARY)(doscan.o) \
- $(LIBRARY)(ecvt.o) \
- $(LIBRARY)(fclose.o) \
- $(LIBRARY)(feof.o) \
- $(LIBRARY)(ferror.o) \
- $(LIBRARY)(fflush.o) \
- $(LIBRARY)(fgetc.o) \
- $(LIBRARY)(fgetpos.o) \
- $(LIBRARY)(fgets.o) \
- $(LIBRARY)(fileno.o) \
- $(LIBRARY)(fillbuf.o) \
- $(LIBRARY)(flushbuf.o) \
- $(LIBRARY)(fopen.o) \
- $(LIBRARY)(fprintf.o) \
- $(LIBRARY)(fputc.o) \
- $(LIBRARY)(fputs.o) \
- $(LIBRARY)(fread.o) \
- $(LIBRARY)(freopen.o) \
- $(LIBRARY)(fscanf.o) \
- $(LIBRARY)(fseek.o) \
- $(LIBRARY)(fsetpos.o) \
- $(LIBRARY)(ftell.o) \
- $(LIBRARY)(fwrite.o) \
- $(LIBRARY)(getc.o) \
- $(LIBRARY)(getchar.o) \
- $(LIBRARY)(gets.o) \
- $(LIBRARY)(icompute.o) \
- $(LIBRARY)(mktemp.o) \
- $(LIBRARY)(perror.o) \
- $(LIBRARY)(printf.o) \
- $(LIBRARY)(putc.o) \
- $(LIBRARY)(putchar.o) \
- $(LIBRARY)(puts.o) \
- $(LIBRARY)(remove.o) \
- $(LIBRARY)(rewind.o) \
- $(LIBRARY)(scanf.o) \
- $(LIBRARY)(setbuf.o) \
- $(LIBRARY)(setvbuf.o) \
- $(LIBRARY)(sprintf.o) \
- $(LIBRARY)(sscanf.o) \
- $(LIBRARY)(tmpfile.o) \
- $(LIBRARY)(tmpnam.o) \
- $(LIBRARY)(ungetc.o) \
- $(LIBRARY)(vfprintf.o) \
- $(LIBRARY)(vprintf.o) \
- $(LIBRARY)(vscanf.o) \
- $(LIBRARY)(vsprintf.o) \
- $(LIBRARY)(vsscanf.o) \
-
-$(LIBRARY): $(OBJECTS)
- aal cr $@ *.o
- rm *.o
-
-$(LIBRARY)(clearerr.o): clearerr.c
- $(CC1) clearerr.c
-
-$(LIBRARY)(data.o): data.c
- $(CC1) data.c
-
-$(LIBRARY)(doprnt.o): doprnt.c
- $(CC1) doprnt.c
-
-$(LIBRARY)(doscan.o): doscan.c
- $(CC1) doscan.c
-
-$(LIBRARY)(ecvt.o): ecvt.c
- $(CC1) ecvt.c
-
-$(LIBRARY)(fclose.o): fclose.c
- $(CC1) fclose.c
-
-$(LIBRARY)(feof.o): feof.c
- $(CC1) feof.c
-
-$(LIBRARY)(ferror.o): ferror.c
- $(CC1) ferror.c
-
-$(LIBRARY)(fflush.o): fflush.c
- $(CC1) fflush.c
-
-$(LIBRARY)(fgetc.o): fgetc.c
- $(CC1) fgetc.c
-
-$(LIBRARY)(fgetpos.o): fgetpos.c
- $(CC1) fgetpos.c
-
-$(LIBRARY)(fgets.o): fgets.c
- $(CC1) fgets.c
-
-$(LIBRARY)(fileno.o): fileno.c
- $(CC1) fileno.c
-
-$(LIBRARY)(fillbuf.o): fillbuf.c
- $(CC1) fillbuf.c
-
-$(LIBRARY)(flushbuf.o): flushbuf.c
- $(CC1) flushbuf.c
-
-$(LIBRARY)(fopen.o): fopen.c
- $(CC1) fopen.c
-
-$(LIBRARY)(fprintf.o): fprintf.c
- $(CC1) fprintf.c
-
-$(LIBRARY)(fputc.o): fputc.c
- $(CC1) fputc.c
-
-$(LIBRARY)(fputs.o): fputs.c
- $(CC1) fputs.c
-
-$(LIBRARY)(fread.o): fread.c
- $(CC1) fread.c
-
-$(LIBRARY)(freopen.o): freopen.c
- $(CC1) freopen.c
-
-$(LIBRARY)(fscanf.o): fscanf.c
- $(CC1) fscanf.c
-
-$(LIBRARY)(fseek.o): fseek.c
- $(CC1) fseek.c
-
-$(LIBRARY)(fsetpos.o): fsetpos.c
- $(CC1) fsetpos.c
-
-$(LIBRARY)(ftell.o): ftell.c
- $(CC1) ftell.c
-
-$(LIBRARY)(fwrite.o): fwrite.c
- $(CC1) fwrite.c
-
-$(LIBRARY)(getc.o): getc.c
- $(CC1) getc.c
-
-$(LIBRARY)(getchar.o): getchar.c
- $(CC1) getchar.c
-
-$(LIBRARY)(gets.o): gets.c
- $(CC1) gets.c
-
-$(LIBRARY)(icompute.o): icompute.c
- $(CC1) icompute.c
-
-$(LIBRARY)(mktemp.o): mktemp.c
- $(CC1) mktemp.c
-
-$(LIBRARY)(perror.o): perror.c
- $(CC1) perror.c
-
-$(LIBRARY)(printf.o): printf.c
- $(CC1) printf.c
-
-$(LIBRARY)(putc.o): putc.c
- $(CC1) putc.c
-
-$(LIBRARY)(putchar.o): putchar.c
- $(CC1) putchar.c
-
-$(LIBRARY)(puts.o): puts.c
- $(CC1) puts.c
-
-$(LIBRARY)(remove.o): remove.c
- $(CC1) remove.c
-
-$(LIBRARY)(rewind.o): rewind.c
- $(CC1) rewind.c
-
-$(LIBRARY)(scanf.o): scanf.c
- $(CC1) scanf.c
-
-$(LIBRARY)(setbuf.o): setbuf.c
- $(CC1) setbuf.c
-
-$(LIBRARY)(setvbuf.o): setvbuf.c
- $(CC1) setvbuf.c
-
-$(LIBRARY)(sprintf.o): sprintf.c
- $(CC1) sprintf.c
-
-$(LIBRARY)(sscanf.o): sscanf.c
- $(CC1) sscanf.c
-
-$(LIBRARY)(tmpfile.o): tmpfile.c
- $(CC1) tmpfile.c
-
-$(LIBRARY)(tmpnam.o): tmpnam.c
- $(CC1) tmpnam.c
-
-$(LIBRARY)(ungetc.o): ungetc.c
- $(CC1) ungetc.c
-
-$(LIBRARY)(vfprintf.o): vfprintf.c
- $(CC1) vfprintf.c
-
-$(LIBRARY)(vprintf.o): vprintf.c
- $(CC1) vprintf.c
-
-$(LIBRARY)(vscanf.o): vscanf.c
- $(CC1) vscanf.c
-
-$(LIBRARY)(vsprintf.o): vsprintf.c
- $(CC1) vsprintf.c
-
-$(LIBRARY)(vsscanf.o): vsscanf.c
- $(CC1) vsscanf.c
+LIBRARIES = libc
+
+libc_OBJECTS = \
+ clearerr.o \
+ data.o \
+ doprnt.o \
+ doscan.o \
+ ecvt.o \
+ fclose.o \
+ feof.o \
+ ferror.o \
+ fflush.o \
+ fgetc.o \
+ fgetpos.o \
+ fgets.o \
+ fileno.o \
+ fillbuf.o \
+ flushbuf.o \
+ fopen.o \
+ fprintf.o \
+ fputc.o \
+ fputs.o \
+ fread.o \
+ freopen.o \
+ fscanf.o \
+ fseek.o \
+ fsetpos.o \
+ ftell.o \
+ fwrite.o \
+ getc.o \
+ getchar.o \
+ gets.o \
+ icompute.o \
+ mktemp.o \
+ perror.o \
+ printf.o \
+ putc.o \
+ putchar.o \
+ puts.o \
+ remove.o \
+ rewind.o \
+ scanf.o \
+ setbuf.o \
+ setvbuf.o \
+ sprintf.o \
+ sscanf.o \
+ tmpfile.o \
+ tmpnam.o \
+ ungetc.o \
+ vfprintf.o \
+ vprintf.o \
+ vscanf.o \
+ vsprintf.o \
+ vsscanf.o \
+
+include ../Makefile.inc
# Makefile for lib/syscall.
-CC1 = $(CC) -c
-
-LIBRARY = ../libc.a
-all: $(LIBRARY)
-
-OBJECTS = \
- $(LIBRARY)(_exit.o) \
- $(LIBRARY)(access.o) \
- $(LIBRARY)(alarm.o) \
- $(LIBRARY)(allocmem.o) \
- $(LIBRARY)(freemem.o) \
- $(LIBRARY)(brk.o) \
- $(LIBRARY)(cfgetispeed.o) \
- $(LIBRARY)(cfgetospeed.o) \
- $(LIBRARY)(cfsetispeed.o) \
- $(LIBRARY)(cfsetospeed.o) \
- $(LIBRARY)(chdir.o) \
- $(LIBRARY)(chmod.o) \
- $(LIBRARY)(chown.o) \
- $(LIBRARY)(chroot.o) \
- $(LIBRARY)(close.o) \
- $(LIBRARY)(closedir.o) \
- $(LIBRARY)(creat.o) \
- $(LIBRARY)(devctl.o) \
- $(LIBRARY)(dup.o) \
- $(LIBRARY)(dup2.o) \
- $(LIBRARY)(execl.o) \
- $(LIBRARY)(execle.o) \
- $(LIBRARY)(execlp.o) \
- $(LIBRARY)(execv.o) \
- $(LIBRARY)(execve.o) \
- $(LIBRARY)(execvp.o) \
- $(LIBRARY)(fcntl.o) \
- $(LIBRARY)(fork.o) \
- $(LIBRARY)(fpathconf.o) \
- $(LIBRARY)(fstat.o) \
- $(LIBRARY)(fstatfs.o) \
- $(LIBRARY)(getcwd.o) \
- $(LIBRARY)(getegid.o) \
- $(LIBRARY)(geteuid.o) \
- $(LIBRARY)(getgid.o) \
- $(LIBRARY)(getgroups.o) \
- $(LIBRARY)(getpgrp.o) \
- $(LIBRARY)(getpid.o) \
- $(LIBRARY)(getnpid.o) \
- $(LIBRARY)(getppid.o) \
- $(LIBRARY)(getuid.o) \
- $(LIBRARY)(getprocnr.o) \
- $(LIBRARY)(getpprocnr.o) \
- $(LIBRARY)(getnprocnr.o) \
- $(LIBRARY)(getsysinfo.o) \
- $(LIBRARY)(findproc.o) \
- $(LIBRARY)(ioctl.o) \
- $(LIBRARY)(isatty.o) \
- $(LIBRARY)(kill.o) \
- $(LIBRARY)(link.o) \
- $(LIBRARY)(lseek.o) \
- $(LIBRARY)(mkdir.o) \
- $(LIBRARY)(mkfifo.o) \
- $(LIBRARY)(mknod.o) \
- $(LIBRARY)(mktemp.o) \
- $(LIBRARY)(mount.o) \
- $(LIBRARY)(open.o) \
- $(LIBRARY)(opendir.o) \
- $(LIBRARY)(pathconf.o) \
- $(LIBRARY)(pause.o) \
- $(LIBRARY)(pipe.o) \
- $(LIBRARY)(ptrace.o) \
- $(LIBRARY)(read.o) \
- $(LIBRARY)(readdir.o) \
- $(LIBRARY)(reboot.o) \
- $(LIBRARY)(rename.o) \
- $(LIBRARY)(rewinddir.o) \
- $(LIBRARY)(rmdir.o) \
- $(LIBRARY)(sbrk.o) \
- $(LIBRARY)(seekdir.o) \
- $(LIBRARY)(setgid.o) \
- $(LIBRARY)(setsid.o) \
- $(LIBRARY)(setuid.o) \
- $(LIBRARY)(sigaction.o) \
- $(LIBRARY)(sigaddset.o) \
- $(LIBRARY)(sigdelset.o) \
- $(LIBRARY)(sigemptyset.o) \
- $(LIBRARY)(sigfillset.o) \
- $(LIBRARY)(sigismember.o) \
- $(LIBRARY)(sigpending.o) \
- $(LIBRARY)(sigprocmask.o) \
- $(LIBRARY)(sigreturn.o) \
- $(LIBRARY)(sigsuspend.o) \
- $(LIBRARY)(sleep.o) \
- $(LIBRARY)(stat.o) \
- $(LIBRARY)(stime.o) \
- $(LIBRARY)(sync.o) \
- $(LIBRARY)(svrctl.o) \
- $(LIBRARY)(tcdrain.o) \
- $(LIBRARY)(tcflow.o) \
- $(LIBRARY)(tcflush.o) \
- $(LIBRARY)(tcgetattr.o) \
- $(LIBRARY)(tcsendbreak.o) \
- $(LIBRARY)(tcsetattr.o) \
- $(LIBRARY)(time.o) \
- $(LIBRARY)(times.o) \
- $(LIBRARY)(umask.o) \
- $(LIBRARY)(umount.o) \
- $(LIBRARY)(uname.o) \
- $(LIBRARY)(unlink.o) \
- $(LIBRARY)(utime.o) \
- $(LIBRARY)(wait.o) \
- $(LIBRARY)(waitpid.o) \
- $(LIBRARY)(write.o) \
-
-$(LIBRARY): $(OBJECTS)
- aal cr $@ *.o
- rm *.o
-
-$(LIBRARY)(_exit.o): _exit.s
- $(CC1) _exit.s
-
-$(LIBRARY)(access.o): access.s
- $(CC1) access.s
-
-$(LIBRARY)(alarm.o): alarm.s
- $(CC1) alarm.s
-
-$(LIBRARY)(allocmem.o): allocmem.s
- $(CC1) allocmem.s
-
-$(LIBRARY)(freemem.o): freemem.s
- $(CC1) freemem.s
-
-$(LIBRARY)(brk.o): brk.s
- $(CC1) brk.s
-
-$(LIBRARY)(cfgetispeed.o): cfgetispeed.s
- $(CC1) cfgetispeed.s
-
-$(LIBRARY)(cfgetospeed.o): cfgetospeed.s
- $(CC1) cfgetospeed.s
-
-$(LIBRARY)(cfsetispeed.o): cfsetispeed.s
- $(CC1) cfsetispeed.s
-
-$(LIBRARY)(cfsetospeed.o): cfsetospeed.s
- $(CC1) cfsetospeed.s
-
-$(LIBRARY)(chdir.o): chdir.s
- $(CC1) chdir.s
-
-$(LIBRARY)(chmod.o): chmod.s
- $(CC1) chmod.s
-
-$(LIBRARY)(chown.o): chown.s
- $(CC1) chown.s
-
-$(LIBRARY)(chroot.o): chroot.s
- $(CC1) chroot.s
-
-$(LIBRARY)(close.o): close.s
- $(CC1) close.s
-
-$(LIBRARY)(closedir.o): closedir.s
- $(CC1) closedir.s
-
-$(LIBRARY)(creat.o): creat.s
- $(CC1) creat.s
-
-$(LIBRARY)(devctl.o): devctl.s
- $(CC1) devctl.s
-
-$(LIBRARY)(dup.o): dup.s
- $(CC1) dup.s
-
-$(LIBRARY)(dup2.o): dup2.s
- $(CC1) dup2.s
-
-$(LIBRARY)(execl.o): execl.s
- $(CC1) execl.s
-
-$(LIBRARY)(execle.o): execle.s
- $(CC1) execle.s
-
-$(LIBRARY)(execlp.o): execlp.s
- $(CC1) execlp.s
-
-$(LIBRARY)(execv.o): execv.s
- $(CC1) execv.s
-
-$(LIBRARY)(execve.o): execve.s
- $(CC1) execve.s
-
-$(LIBRARY)(execvp.o): execvp.s
- $(CC1) execvp.s
-
-$(LIBRARY)(fcntl.o): fcntl.s
- $(CC1) fcntl.s
-
-$(LIBRARY)(fork.o): fork.s
- $(CC1) fork.s
-
-$(LIBRARY)(fpathconf.o): fpathconf.s
- $(CC1) fpathconf.s
-
-$(LIBRARY)(fstat.o): fstat.s
- $(CC1) fstat.s
-
-$(LIBRARY)(fstatfs.o): fstatfs.s
- $(CC1) fstatfs.s
-
-$(LIBRARY)(getcwd.o): getcwd.s
- $(CC1) getcwd.s
-
-$(LIBRARY)(getegid.o): getegid.s
- $(CC1) getegid.s
-
-$(LIBRARY)(geteuid.o): geteuid.s
- $(CC1) geteuid.s
-
-$(LIBRARY)(getgid.o): getgid.s
- $(CC1) getgid.s
-
-$(LIBRARY)(getgroups.o): getgroups.s
- $(CC1) getgroups.s
-
-$(LIBRARY)(getpgrp.o): getpgrp.s
- $(CC1) getpgrp.s
-
-$(LIBRARY)(getpid.o): getpid.s
- $(CC1) getpid.s
-
-$(LIBRARY)(getnpid.o): getnpid.s
- $(CC1) getnpid.s
-
-$(LIBRARY)(getppid.o): getppid.s
- $(CC1) getppid.s
-
-$(LIBRARY)(getsysinfo.o): getsysinfo.s
- $(CC1) getsysinfo.s
-
-$(LIBRARY)(getprocnr.o): getprocnr.s
- $(CC1) getprocnr.s
-
-$(LIBRARY)(getnprocnr.o): getnprocnr.s
- $(CC1) getnprocnr.s
-
-$(LIBRARY)(getpprocnr.o): getpprocnr.s
- $(CC1) getpprocnr.s
-
-$(LIBRARY)(findproc.o): findproc.s
- $(CC1) findproc.s
-
-$(LIBRARY)(getuid.o): getuid.s
- $(CC1) getuid.s
-
-$(LIBRARY)(ioctl.o): ioctl.s
- $(CC1) ioctl.s
-
-$(LIBRARY)(isatty.o): isatty.s
- $(CC1) isatty.s
-
-$(LIBRARY)(kill.o): kill.s
- $(CC1) kill.s
-
-$(LIBRARY)(link.o): link.s
- $(CC1) link.s
-
-$(LIBRARY)(lseek.o): lseek.s
- $(CC1) lseek.s
-
-$(LIBRARY)(mkdir.o): mkdir.s
- $(CC1) mkdir.s
-
-$(LIBRARY)(mkfifo.o): mkfifo.s
- $(CC1) mkfifo.s
-
-$(LIBRARY)(mknod.o): mknod.s
- $(CC1) mknod.s
-
-$(LIBRARY)(mktemp.o): mktemp.s
- $(CC1) mktemp.s
-
-$(LIBRARY)(mount.o): mount.s
- $(CC1) mount.s
-
-$(LIBRARY)(open.o): open.s
- $(CC1) open.s
-
-$(LIBRARY)(opendir.o): opendir.s
- $(CC1) opendir.s
-
-$(LIBRARY)(pathconf.o): pathconf.s
- $(CC1) pathconf.s
-
-$(LIBRARY)(pause.o): pause.s
- $(CC1) pause.s
-
-$(LIBRARY)(pipe.o): pipe.s
- $(CC1) pipe.s
-
-$(LIBRARY)(ptrace.o): ptrace.s
- $(CC1) ptrace.s
-
-$(LIBRARY)(read.o): read.s
- $(CC1) read.s
-
-$(LIBRARY)(readdir.o): readdir.s
- $(CC1) readdir.s
-
-$(LIBRARY)(reboot.o): reboot.s
- $(CC1) reboot.s
-
-$(LIBRARY)(rename.o): rename.s
- $(CC1) rename.s
-
-$(LIBRARY)(rewinddir.o): rewinddir.s
- $(CC1) rewinddir.s
-
-$(LIBRARY)(rmdir.o): rmdir.s
- $(CC1) rmdir.s
-
-$(LIBRARY)(sbrk.o): sbrk.s
- $(CC1) sbrk.s
-
-$(LIBRARY)(seekdir.o): seekdir.s
- $(CC1) seekdir.s
-
-$(LIBRARY)(setgid.o): setgid.s
- $(CC1) setgid.s
-
-$(LIBRARY)(setsid.o): setsid.s
- $(CC1) setsid.s
-
-$(LIBRARY)(setuid.o): setuid.s
- $(CC1) setuid.s
-
-$(LIBRARY)(sigaction.o): sigaction.s
- $(CC1) sigaction.s
-
-$(LIBRARY)(sigaddset.o): sigaddset.s
- $(CC1) sigaddset.s
-
-$(LIBRARY)(sigdelset.o): sigdelset.s
- $(CC1) sigdelset.s
-
-$(LIBRARY)(sigemptyset.o): sigemptyset.s
- $(CC1) sigemptyset.s
-
-$(LIBRARY)(sigfillset.o): sigfillset.s
- $(CC1) sigfillset.s
-
-$(LIBRARY)(sigismember.o): sigismember.s
- $(CC1) sigismember.s
-
-$(LIBRARY)(sigpending.o): sigpending.s
- $(CC1) sigpending.s
-
-$(LIBRARY)(sigprocmask.o): sigprocmask.s
- $(CC1) sigprocmask.s
-
-$(LIBRARY)(sigreturn.o): sigreturn.s
- $(CC1) sigreturn.s
-
-$(LIBRARY)(sigsuspend.o): sigsuspend.s
- $(CC1) sigsuspend.s
-
-$(LIBRARY)(sleep.o): sleep.s
- $(CC1) sleep.s
-
-$(LIBRARY)(stat.o): stat.s
- $(CC1) stat.s
-
-$(LIBRARY)(stime.o): stime.s
- $(CC1) stime.s
-
-$(LIBRARY)(sync.o): sync.s
- $(CC1) sync.s
-
-$(LIBRARY)(svrctl.o): svrctl.s
- $(CC1) svrctl.s
-
-$(LIBRARY)(tcdrain.o): tcdrain.s
- $(CC1) tcdrain.s
-
-$(LIBRARY)(tcflow.o): tcflow.s
- $(CC1) tcflow.s
-
-$(LIBRARY)(tcflush.o): tcflush.s
- $(CC1) tcflush.s
-
-$(LIBRARY)(tcgetattr.o): tcgetattr.s
- $(CC1) tcgetattr.s
-
-$(LIBRARY)(tcsendbreak.o): tcsendbreak.s
- $(CC1) tcsendbreak.s
-
-$(LIBRARY)(tcsetattr.o): tcsetattr.s
- $(CC1) tcsetattr.s
-
-$(LIBRARY)(time.o): time.s
- $(CC1) time.s
-
-$(LIBRARY)(times.o): times.s
- $(CC1) times.s
-
-$(LIBRARY)(umask.o): umask.s
- $(CC1) umask.s
-
-$(LIBRARY)(umount.o): umount.s
- $(CC1) umount.s
-
-$(LIBRARY)(uname.o): uname.s
- $(CC1) uname.s
-
-$(LIBRARY)(unlink.o): unlink.s
- $(CC1) unlink.s
-
-$(LIBRARY)(utime.o): utime.s
- $(CC1) utime.s
-
-$(LIBRARY)(wait.o): wait.s
- $(CC1) wait.s
-
-$(LIBRARY)(waitpid.o): waitpid.s
- $(CC1) waitpid.s
-
-$(LIBRARY)(write.o): write.s
- $(CC1) write.s
+LIBRARIES = libc
+
+libc_OBJECTS = \
+ _exit.o \
+ access.o \
+ alarm.o \
+ allocmem.o \
+ freemem.o \
+ brk.o \
+ cfgetispeed.o \
+ cfgetospeed.o \
+ cfsetispeed.o \
+ cfsetospeed.o \
+ chdir.o \
+ chmod.o \
+ chown.o \
+ chroot.o \
+ close.o \
+ closedir.o \
+ creat.o \
+ devctl.o \
+ dup.o \
+ dup2.o \
+ execl.o \
+ execle.o \
+ execlp.o \
+ execv.o \
+ execve.o \
+ execvp.o \
+ fcntl.o \
+ fork.o \
+ fpathconf.o \
+ fstat.o \
+ fstatfs.o \
+ getcwd.o \
+ getegid.o \
+ geteuid.o \
+ getgid.o \
+ getgroups.o \
+ getnpid.o \
+ getnprocnr.o \
+ getpprocnr.o \
+ getpgrp.o \
+ getpid.o \
+ getppid.o \
+ getuid.o \
+ getprocnr.o \
+ getsysinfo.o \
+ findproc.o \
+ ioctl.o \
+ isatty.o \
+ kill.o \
+ link.o \
+ lseek.o \
+ mkdir.o \
+ mkfifo.o \
+ mknod.o \
+ mount.o \
+ open.o \
+ opendir.o \
+ pathconf.o \
+ pause.o \
+ pipe.o \
+ ptrace.o \
+ read.o \
+ readdir.o \
+ reboot.o \
+ rename.o \
+ rewinddir.o \
+ rmdir.o \
+ sbrk.o \
+ seekdir.o \
+ setgid.o \
+ setsid.o \
+ setuid.o \
+ sigaction.o \
+ sigaddset.o \
+ sigdelset.o \
+ sigemptyset.o \
+ sigfillset.o \
+ sigismember.o \
+ sigpending.o \
+ sigprocmask.o \
+ sigreturn.o \
+ sigsuspend.o \
+ sleep.o \
+ stat.o \
+ stime.o \
+ sync.o \
+ svrctl.o \
+ tcdrain.o \
+ tcflow.o \
+ tcflush.o \
+ tcgetattr.o \
+ tcsendbreak.o \
+ tcsetattr.o \
+ time.o \
+ times.o \
+ umask.o \
+ umount.o \
+ uname.o \
+ unlink.o \
+ utime.o \
+ wait.o \
+ waitpid.o \
+ write.o \
+
+include ../Makefile.inc
+++ /dev/null
-.sect .text
-.extern __mktemp
-.define _mktemp
-.align 2
-
-_mktemp:
- jmp __mktemp
# Makefile for lib/syslib.
CFLAGS = -O -D_MINIX -D_POSIX_SOURCE
-CC1 = $(CC) $(CFLAGS) -c
-
-LIBSYS = ../libsys.a
-all: $(LIBSYS)
-
-clean:
- rm *.o
-
-OBJECTS = \
- $(LIBSYS)(sys_times.o) \
- $(LIBSYS)(sys_abort.o) \
- $(LIBSYS)(sys_exec.o) \
- $(LIBSYS)(sys_fork.o) \
- $(LIBSYS)(sys_int86.o) \
- $(LIBSYS)(sys_kill.o) \
- $(LIBSYS)(sys_newmap.o) \
- $(LIBSYS)(sys_sigsend.o) \
- $(LIBSYS)(sys_sigreturn.o) \
- $(LIBSYS)(sys_endsig.o) \
- $(LIBSYS)(sys_getsig.o) \
- $(LIBSYS)(sys_svrctl.o) \
- $(LIBSYS)(sys_trace.o) \
- $(LIBSYS)(sys_exit.o) \
- $(LIBSYS)(sys_sdevio.o) \
- $(LIBSYS)(sys_getinfo.o) \
- $(LIBSYS)(sys_irqctl.o) \
- $(LIBSYS)(sys_segctl.o) \
- $(LIBSYS)(sys_nice.o) \
- $(LIBSYS)(sys_umap.o) \
- $(LIBSYS)(sys_physcopy.o) \
- $(LIBSYS)(sys_vircopy.o) \
- $(LIBSYS)(sys_in.o) \
- $(LIBSYS)(sys_out.o) \
- $(LIBSYS)(sys_vinb.o) \
- $(LIBSYS)(sys_vinw.o) \
- $(LIBSYS)(sys_vinl.o) \
- $(LIBSYS)(sys_voutb.o) \
- $(LIBSYS)(sys_voutw.o) \
- $(LIBSYS)(sys_voutl.o) \
- $(LIBSYS)(sys_setalarm.o) \
- $(LIBSYS)(sys_memset.o) \
- $(LIBSYS)(sys_vm_setbuf.o) \
- $(LIBSYS)(sys_vm_map.o) \
- $(LIBSYS)(taskcall.o) \
-
-$(LIBSYS): $(OBJECTS)
- aal cr $@ *.o
- rm *.o
-
-$(LIBSYS)(sys_times.o): sys_times.c
- $(CC1) sys_times.c
-
-$(LIBSYS)(sys_getuptm.o): sys_getuptm.c
- $(CC1) sys_getuptm.c
-
-$(LIBSYS)(sys_abort.o): sys_abort.c
- $(CC1) sys_abort.c
-
-$(LIBSYS)(sys_exec.o): sys_exec.c
- $(CC1) sys_exec.c
-
-$(LIBSYS)(sys_fork.o): sys_fork.c
- $(CC1) sys_fork.c
-
-$(LIBSYS)(sys_int86.o): sys_int86.c
- $(CC1) sys_int86.c
-
-$(LIBSYS)(sys_kill.o): sys_kill.c
- $(CC1) sys_kill.c
-
-$(LIBSYS)(sys_newmap.o): sys_newmap.c
- $(CC1) sys_newmap.c
-
-$(LIBSYS)(sys_svrctl.o): sys_svrctl.c
- $(CC1) sys_svrctl.c
-
-$(LIBSYS)(sys_trace.o): sys_trace.c
- $(CC1) sys_trace.c
-
-$(LIBSYS)(sys_exit.o): sys_exit.c
- $(CC1) sys_exit.c
-
-$(LIBSYS)(sys_sdevio.o): sys_sdevio.c
- $(CC1) sys_sdevio.c
-
-$(LIBSYS)(sys_getinfo.o): sys_getinfo.c
- $(CC1) sys_getinfo.c
-
-$(LIBSYS)(sys_irqctl.o): sys_irqctl.c
- $(CC1) sys_irqctl.c
-
-$(LIBSYS)(sys_eniop.o): sys_eniop.c
- $(CC1) sys_eniop.c
-
-$(LIBSYS)(sys_nice.o): sys_nice.c
- $(CC1) sys_nice.c
-
-$(LIBSYS)(sys_segctl.o): sys_segctl.c
- $(CC1) sys_segctl.c
-
-$(LIBSYS)(sys_umap.o): sys_umap.c
- $(CC1) sys_umap.c
-
-$(LIBSYS)(sys_getsig.o): sys_getsig.c
- $(CC1) sys_getsig.c
-
-$(LIBSYS)(sys_endsig.o): sys_endsig.c
- $(CC1) sys_endsig.c
-
-$(LIBSYS)(sys_sigsend.o): sys_sigsend.c
- $(CC1) sys_sigsend.c
-
-$(LIBSYS)(sys_sigreturn.o): sys_sigreturn.c
- $(CC1) sys_sigreturn.c
-
-$(LIBSYS)(sys_physcopy.o): sys_physcopy.c
- $(CC1) sys_physcopy.c
-
-$(LIBSYS)(sys_vircopy.o): sys_vircopy.c
- $(CC1) sys_vircopy.c
-
-$(LIBSYS)(sys_out.o): sys_out.c
- $(CC1) sys_out.c
-
-$(LIBSYS)(sys_in.o): sys_in.c
- $(CC1) sys_in.c
-
-$(LIBSYS)(sys_voutb.o): sys_voutb.c
- $(CC1) sys_voutb.c
-
-$(LIBSYS)(sys_voutw.o): sys_voutw.c
- $(CC1) sys_voutw.c
-
-$(LIBSYS)(sys_voutl.o): sys_voutl.c
- $(CC1) sys_voutl.c
-
-$(LIBSYS)(sys_vinb.o): sys_vinb.c
- $(CC1) sys_vinb.c
-
-$(LIBSYS)(sys_vinw.o): sys_vinw.c
- $(CC1) sys_vinw.c
-
-$(LIBSYS)(sys_vinl.o): sys_vinl.c
- $(CC1) sys_vinl.c
-
-$(LIBSYS)(sys_setalarm.o): sys_setalarm.c
- $(CC1) sys_setalarm.c
-
-$(LIBSYS)(sys_memset.o): sys_memset.c
- $(CC1) sys_memset.c
-
-$(LIBSYS)(sys_vm_setbuf.o): sys_vm_setbuf.c
- $(CC1) sys_vm_setbuf.c
-
-$(LIBSYS)(sys_vm_map.o): sys_vm_map.c
- $(CC1) sys_vm_map.c
-
-$(LIBSYS)(taskcall.o): taskcall.c
- $(CC1) taskcall.c
+LIBRARIES = libsys
+
+libsys_OBJECTS = \
+ sys_times.o \
+ sys_abort.o \
+ sys_exec.o \
+ sys_fork.o \
+ sys_int86.o \
+ sys_kill.o \
+ sys_newmap.o \
+ sys_sigsend.o \
+ sys_sigreturn.o \
+ sys_endsig.o \
+ sys_getsig.o \
+ sys_svrctl.o \
+ sys_trace.o \
+ sys_exit.o \
+ sys_sdevio.o \
+ sys_getinfo.o \
+ sys_irqctl.o \
+ sys_segctl.o \
+ sys_nice.o \
+ sys_umap.o \
+ sys_physcopy.o \
+ sys_vircopy.o \
+ sys_in.o \
+ sys_out.o \
+ sys_vinb.o \
+ sys_vinw.o \
+ sys_vinl.o \
+ sys_voutb.o \
+ sys_voutw.o \
+ sys_voutl.o \
+ sys_setalarm.o \
+ sys_memset.o \
+ taskcall.o \
+ sys_vm_setbuf.o \
+ sys_vm_map.o \
+
+include ../Makefile.inc
# Makefile for lib/utils.
CFLAGS = -O -D_MINIX -D_POSIX_SOURCE
-CC1 = $(CC) $(CFLAGS) -c
-
-LIBUTILS = ../libsysutil.a
-all: $(LIBUTILS)
-
-OBJECTS = \
- $(LIBUTILS)(kmalloc.o) \
- $(LIBUTILS)(kprintf.o) \
- $(LIBUTILS)(kputc.o) \
- $(LIBUTILS)(tickdelay.o) \
- $(LIBUTILS)(getuptime.o) \
- $(LIBUTILS)(env_get_prm.o) \
- $(LIBUTILS)(env_parse.o) \
- $(LIBUTILS)(env_panic.o) \
- $(LIBUTILS)(env_prefix.o) \
- $(LIBUTILS)(fkey_ctl.o) \
- $(LIBUTILS)(panic.o) \
- $(LIBUTILS)(report.o) \
- $(LIBUTILS)(taskcall.o) \
-
-
-$(LIBUTILS): $(OBJECTS)
- aal cr $@ *.o
- rm *.o
-
-$(LIBUTILS)(kmalloc.o): kmalloc.c
- $(CC1) kmalloc.c
-
-$(LIBUTILS)(kprintf.o): kprintf.c
- $(CC1) kprintf.c
-
-$(LIBUTILS)(kputc.o): kputc.c
- $(CC1) kputc.c
-
-$(LIBUTILS)(getuptime.o): getuptime.c
- $(CC1) getuptime.c
-
-$(LIBUTILS)(tickdelay.o): tickdelay.c
- $(CC1) tickdelay.c
-
-$(LIBUTILS)(env_get_prm.o): env_get_prm.c
- $(CC1) env_get_prm.c
-
-$(LIBUTILS)(env_parse.o): env_parse.c
- $(CC1) env_parse.c
-
-$(LIBUTILS)(env_prefix.o): env_prefix.c
- $(CC1) env_prefix.c
-
-$(LIBUTILS)(env_panic.o): env_panic.c
- $(CC1) env_panic.c
-
-$(LIBUTILS)(fkey_ctl.o): fkey_ctl.c
- $(CC1) fkey_ctl.c
-
-$(LIBUTILS)(panic.o): panic.c
- $(CC1) panic.c
-
-$(LIBUTILS)(report.o): report.c
- $(CC1) report.c
-
-$(LIBUTILS)(taskcall.o): taskcall.c
- $(CC1) taskcall.c
-
+LIBRARIES = libsysutil
+
+libsysutil_OBJECTS = \
+ kmalloc.o \
+ kprintf.o \
+ kputc.o \
+ tickdelay.o \
+ getuptime.o \
+ env_get_prm.o \
+ env_parse.o \
+ env_panic.o \
+ env_prefix.o \
+ fkey_ctl.o \
+ panic.o \
+ report.o \
+ taskcall.o \
+
+include ../Makefile.inc
# Makefile for lib/tmrslib.
CFLAGS = -O -D_MINIX -D_POSIX_SOURCE
-CC1 = $(CC) $(CFLAGS) -c
-LIBTMRS = ../libtimers.a
-all: $(LIBTMRS)
-
-OBJECTS = \
- $(LIBTMRS)(tmrs_set.o) \
- $(LIBTMRS)(tmrs_clr.o) \
- $(LIBTMRS)(tmrs_exp.o) \
-
-
-$(LIBTMRS): $(OBJECTS)
- aal cr $@ *.o
- rm *.o
-
-$(LIBTMRS)(tmrs_set.o): tmrs_set.c
- $(CC1) tmrs_set.c
-
-$(LIBTMRS)(tmrs_clr.o): tmrs_clr.c
- $(CC1) tmrs_clr.c
-
-$(LIBTMRS)(tmrs_exp.o): tmrs_exp.c
- $(CC1) tmrs_exp.c
+LIBRARIES = libtimers
+libtimers_OBJECTS = \
+ tmrs_set.o \
+ tmrs_clr.o \
+ tmrs_exp.o \
+include ../Makefile.inc
# Makefile for lib/util.
CFLAGS = -O -D_MINIX -D_POSIX_SOURCE
-CC1 = $(CC) $(CFLAGS) -c
-LIBUTIL = ../libutil.a
-all: $(LIBUTIL)
+LIBRARIES = libutil
-OBJECTS = \
- $(LIBUTIL)(openpty.o)
-
-
-$(LIBUTIL): $(OBJECTS)
- aal cr $@ *.o
- rm *.o
-
-$(LIBUTIL)(openpty.o): openpty.c
- $(CC1) openpty.c
+libutil_OBJECTS = \
+ openpty.o
+include ../Makefile.inc
# Makefile for zlib
-# Copyright (C) 1995-2005 Jean-loup Gailly.
+# Copyright (C) 1995-2003 Jean-loup Gailly.
# For conditions of distribution and use, see copyright notice in zlib.h
# To compile and test, type:
# To install in $HOME instead of /usr/local, use:
# make install prefix=$HOME
-CC=cc
+#CC=cc
-CFLAGS=-O -DNO_snprintf -DHAS_sprintf_void -DNO_ERRNO_H
+CFLAGS=-D_MINIX=1 -D_POSIX_SOURCE=1
#CFLAGS=-O -DMAX_WBITS=14 -DMAX_MEM_LEVEL=7
#CFLAGS=-g -DDEBUG
#CFLAGS=-O3 -Wall -Wwrite-strings -Wpointer-arith -Wconversion \
# -Wstrict-prototypes -Wmissing-prototypes
-LDFLAGS=-L. libz.a
-LDSHARED=cc
-CPP=cc -E
-
-LIBS=libz.a
-SHAREDLIB=libz.so
-SHAREDLIBV=libz.so.1.2.3
-SHAREDLIBM=libz.so.1
-
-AR=ar rc
-RANLIB=ranlib
-TAR=tar
-SHELL=/bin/sh
-EXE=
-
-prefix =/usr/local
-exec_prefix =${prefix}
-libdir =${exec_prefix}/lib
-includedir =${prefix}/include
-mandir =${prefix}/share/man
-man3dir = ${mandir}/man3
-
-OBJS = adler32.o compress.o crc32.o gzio.o uncompr.o deflate.o trees.o \
- zutil.o inflate.o infback.o inftrees.o inffast.o
-
-OBJA =
+#LDFLAGS=-L. libz.a
+#LDSHARED=cc
+#CPP=cc -E
+
+#LIBS=libz.a
+LIBRARIES=libz
+#SHAREDLIB=libz.so
+#SHAREDLIBV=libz.so.1.2.2
+#SHAREDLIBM=libz.so.1
+
+#AR=ar rc
+#RANLIB=ranlib
+#TAR=tar
+#SHELL=/bin/sh
+#EXE=
+
+#prefix =/usr/local
+#exec_prefix =${prefix}
+#libdir =${exec_prefix}/lib
+#includedir =${prefix}/include
+#mandir =/usr/local/man
+#man3dir = ${mandir}/man3
+
+#OBJS = adler32.o compress.o crc32.o gzio.o uncompr.o deflate.o trees.o \
+# zutil.o inflate.o infback.o inftrees.o inffast.o
+
+#OBJA =
# to use the asm code: make OBJA=match.o
-TEST_OBJS = example.o minigzip.o
-
-all: example$(EXE) minigzip$(EXE)
-
-check: test
-test: all
- @LD_LIBRARY_PATH=.:$(LD_LIBRARY_PATH) ; export LD_LIBRARY_PATH; \
- echo hello world | ./minigzip | ./minigzip -d || \
- echo ' *** minigzip test FAILED ***' ; \
- if ./example; then \
- echo ' *** zlib test OK ***'; \
- else \
- echo ' *** zlib test FAILED ***'; \
- fi
-
-libz.a: $(OBJS) $(OBJA)
- $(AR) $@ $(OBJS) $(OBJA)
- -@ ($(RANLIB) $@ || true) >/dev/null 2>&1
-
-match.o: match.S
- $(CPP) match.S > _match.s
- $(CC) -c _match.s
- mv _match.o match.o
- rm -f _match.s
-
-$(SHAREDLIBV): $(OBJS)
- $(LDSHARED) -o $@ $(OBJS)
- rm -f $(SHAREDLIB) $(SHAREDLIBM)
- ln -s $@ $(SHAREDLIB)
- ln -s $@ $(SHAREDLIBM)
-
-example$(EXE): example.o $(LIBS)
- $(CC) $(CFLAGS) -o $@ example.o $(LDFLAGS)
-
-minigzip$(EXE): minigzip.o $(LIBS)
- $(CC) $(CFLAGS) -o $@ minigzip.o $(LDFLAGS)
-
-install: $(LIBS)
- -@if [ ! -d $(exec_prefix) ]; then mkdir -p $(exec_prefix); fi
- -@if [ ! -d $(includedir) ]; then mkdir -p $(includedir); fi
- -@if [ ! -d $(libdir) ]; then mkdir -p $(libdir); fi
- -@if [ ! -d $(man3dir) ]; then mkdir -p $(man3dir); fi
- cp zlib.h zconf.h $(includedir)
- chmod 644 $(includedir)/zlib.h $(includedir)/zconf.h
- cp $(LIBS) $(libdir)
- cd $(libdir); chmod 755 $(LIBS)
- -@(cd $(libdir); $(RANLIB) libz.a || true) >/dev/null 2>&1
- cd $(libdir); if test -f $(SHAREDLIBV); then \
- rm -f $(SHAREDLIB) $(SHAREDLIBM); \
- ln -s $(SHAREDLIBV) $(SHAREDLIB); \
- ln -s $(SHAREDLIBV) $(SHAREDLIBM); \
- (ldconfig || true) >/dev/null 2>&1; \
- fi
- cp zlib.3 $(man3dir)
- chmod 644 $(man3dir)/zlib.3
+libz_OBJECTS = adler32.o compress.o crc32.o gzio.o uncompr.o deflate.o trees.o \
+ zutil.o inflate.o infback.o inftrees.o inffast.o
+
+# to use the asm code: add match.o to liz_OBJECTS
+
+#TEST_OBJS = example.o minigzip.o
+
+#all:: example$(EXE) minigzip$(EXE)
+
+#check: test
+#test: all
+# @LD_LIBRARY_PATH=.:$(LD_LIBRARY_PATH) ; export LD_LIBRARY_PATH; \
+# echo hello world | ./minigzip | ./minigzip -d || \
+# echo ' *** minigzip test FAILED ***' ; \
+# if ./example; then \
+# echo ' *** zlib test OK ***'; \
+# else \
+# echo ' *** zlib test FAILED ***'; \
+# fi
+
+#libz.a: $(OBJS) $(OBJA)
+# $(AR) $@ $(OBJS) $(OBJA)
+# -@ ($(RANLIB) $@ || true) >/dev/null 2>&1
+
+#match.o: match.S
+# $(CPP) match.S > _match.s
+# $(CC) -c _match.s
+# mv _match.o match.o
+# rm -f _match.s
+
+#$(SHAREDLIBV): $(OBJS)
+# $(LDSHARED) -o $@ $(OBJS)
+# rm -f $(SHAREDLIB) $(SHAREDLIBM)
+# ln -s $@ $(SHAREDLIB)
+# ln -s $@ $(SHAREDLIBM)
+
+#example$(EXE): example.o $(LIBS)
+# $(CC) $(CFLAGS) -o $@ example.o $(LDFLAGS)
+
+#minigzip$(EXE): minigzip.o $(LIBS)
+# $(CC) $(CFLAGS) -o $@ minigzip.o $(LDFLAGS)
+
+#install: $(LIBS)
+# -@if [ ! -d $(exec_prefix) ]; then mkdir -p $(exec_prefix); fi
+# -@if [ ! -d $(includedir) ]; then mkdir -p $(includedir); fi
+# -@if [ ! -d $(libdir) ]; then mkdir -p $(libdir); fi
+# -@if [ ! -d $(man3dir) ]; then mkdir -p $(man3dir); fi
+# install -o bin zlib.h zconf.h $(includedir)
+# chmod 644 $(includedir)/zlib.h $(includedir)/zconf.h
+# install -o bin $(LIBS) $(libdir)
+# cd $(libdir); chmod 755 $(LIBS)
+# -@(cd $(libdir); $(RANLIB) libz.a || true) >/dev/null 2>&1
+# cd $(libdir); if test -f $(SHAREDLIBV); then \
+# rm -f $(SHAREDLIB) $(SHAREDLIBM); \
+# ln -s $(SHAREDLIBV) $(SHAREDLIB); \
+# ln -s $(SHAREDLIBV) $(SHAREDLIBM); \
+# (ldconfig || true) >/dev/null 2>&1; \
+# fi
+# install -o bin zlib.3 $(man3dir)
+# chmod 644 $(man3dir)/zlib.3
# The ranlib in install is needed on NeXTSTEP which checks file times
# ldconfig is for Linux
-uninstall:
- cd $(includedir); \
- cd $(libdir); rm -f libz.a; \
- if test -f $(SHAREDLIBV); then \
- rm -f $(SHAREDLIBV) $(SHAREDLIB) $(SHAREDLIBM); \
- fi
- cd $(man3dir); rm -f zlib.3
+#uninstall:
+# cd $(includedir); \
+# cd $(libdir); rm -f libz.a; \
+# if test -f $(SHAREDLIBV); then \
+# rm -f $(SHAREDLIBV) $(SHAREDLIB) $(SHAREDLIBM); \
+# fi
+# cd $(man3dir); rm -f zlib.3
mostlyclean: clean
-clean:
+clean::
rm -f *.o *~ example$(EXE) minigzip$(EXE) \
libz.* foo.gz so_locations \
_match.s maketree contrib/infback9/*.o
-maintainer-clean: distclean
-distclean: clean
- cp -p Makefile.in Makefile
- cp -p zconf.in.h zconf.h
- rm -f .DS_Store
-
-tags:
- etags *.[ch]
-
-depend:
- makedepend -- $(CFLAGS) -- *.[ch]
-
-# DO NOT DELETE THIS LINE -- make depend depends on it.
-
-adler32.o: zlib.h zconf.h
-compress.o: zlib.h zconf.h
-crc32.o: crc32.h zlib.h zconf.h
-deflate.o: deflate.h zutil.h zlib.h zconf.h
-example.o: zlib.h zconf.h
-gzio.o: zutil.h zlib.h zconf.h
-inffast.o: zutil.h zlib.h zconf.h inftrees.h inflate.h inffast.h
-inflate.o: zutil.h zlib.h zconf.h inftrees.h inflate.h inffast.h
-infback.o: zutil.h zlib.h zconf.h inftrees.h inflate.h inffast.h
-inftrees.o: zutil.h zlib.h zconf.h inftrees.h
-minigzip.o: zlib.h zconf.h
-trees.o: deflate.h zutil.h zlib.h zconf.h trees.h
-uncompr.o: zlib.h zconf.h
-zutil.o: zutil.h zlib.h zconf.h
+#maintainer-clean: distclean
+#distclean: clean
+# cp -p Makefile.in Makefile
+# cp -p zconf.in.h zconf.h
+# rm -f .DS_Store
+
+#tags:
+# etags *.[ch]
+#
+#depend:
+# makedepend -- $(CFLAGS) -- *.[ch]
+
+## DO NOT DELETE THIS LINE -- make depend depends on it.
+
+#adler32.o: zlib.h zconf.h
+#compress.o: zlib.h zconf.h
+#crc32.o: crc32.h zlib.h zconf.h
+#deflate.o: deflate.h zutil.h zlib.h zconf.h
+#example.o: zlib.h zconf.h
+#gzio.o: zutil.h zlib.h zconf.h
+#inffast.o: zutil.h zlib.h zconf.h inftrees.h inflate.h inffast.h
+#inflate.o: zutil.h zlib.h zconf.h inftrees.h inflate.h inffast.h
+#infback.o: zutil.h zlib.h zconf.h inftrees.h inflate.h inffast.h
+#inftrees.o: zutil.h zlib.h zconf.h inftrees.h
+#minigzip.o: zlib.h zconf.h
+#trees.o: deflate.h zutil.h zlib.h zconf.h trees.h
+#uncompr.o: zlib.h zconf.h
+#zutil.o: zutil.h zlib.h zconf.h
+
+include ../Makefile.inc
+
+$(call ADDDEPENDENCIES,libz_OBJECTS,zlib.h zconf.h)
+$(call ADDDEPENDENCIES,deflate.o gzio.o inffast.o inflate.o infback.o inftrees.o trees.o zutil.o,zutil.h)
+$(call ADDDEPENDENCIES,deflate.o trees.o,deflate.h)
+$(call ADDDEPENDENCIES,inffast.o inflate.o infback.o inftrees.o,inftrees.h)
+$(call ADDDEPENDENCIES,inffast.o inflate.o infback.o,inflate.h inffast.h)
+$(call ADDDEPENDENCIES,crc32.o,crc32.h)
+
# Makefile for zlib
-# Copyright (C) 1995-2005 Jean-loup Gailly.
+# Copyright (C) 1995-2003 Jean-loup Gailly.
# For conditions of distribution and use, see copyright notice in zlib.h
# To compile and test, type: