1995-05-08 08:18:32 -07:00
|
|
|
# Makefile for the Unix interface library
|
|
|
|
|
1996-02-13 08:28:24 -08:00
|
|
|
include ../../config/Makefile
|
1995-05-08 08:18:32 -07:00
|
|
|
|
|
|
|
# Compilation options
|
1995-08-08 06:37:34 -07:00
|
|
|
CC=$(BYTECC)
|
|
|
|
CFLAGS=-I../../byterun -O $(BYTECCCOMPOPTS)
|
1996-06-04 08:13:13 -07:00
|
|
|
CAMLC=../../boot/ocamlrun ../../boot/ocamlc -I ../../stdlib
|
1996-04-30 07:53:58 -07:00
|
|
|
CAMLOPT=../../boot/ocamlrun ../../ocamlopt -I ../../stdlib
|
1995-05-08 08:18:32 -07:00
|
|
|
|
|
|
|
OBJS=accept.o access.o addrofstr.o alarm.o bind.o chdir.o chmod.o \
|
|
|
|
chown.o chroot.o close.o closedir.o connect.o cst2constr.o cstringv.o \
|
|
|
|
dup.o dup2.o envir.o errmsg.o execv.o execve.o execvp.o exit.o \
|
|
|
|
fchmod.o fchown.o fcntl.o fork.o ftruncate.o getcwd.o getegid.o \
|
|
|
|
geteuid.o getgid.o getgr.o getgroups.o gethost.o gethostname.o \
|
1995-08-08 06:37:34 -07:00
|
|
|
getlogin.o getpeername.o getpid.o getppid.o getproto.o getpw.o \
|
1995-10-31 02:48:06 -08:00
|
|
|
gettimeofday.o getserv.o getsockname.o getuid.o \
|
1996-04-12 08:57:28 -07:00
|
|
|
gmtime.o ioctl.o itimer.o kill.o link.o listen.o lockf.o lseek.o mkdir.o \
|
1995-05-08 08:18:32 -07:00
|
|
|
mkfifo.o nice.o open.o opendir.o pause.o pipe.o read.o \
|
|
|
|
readdir.o readlink.o rename.o rewinddir.o rmdir.o select.o sendrecv.o \
|
|
|
|
setgid.o setuid.o shutdown.o sleep.o socket.o socketaddr.o \
|
1996-04-12 08:57:28 -07:00
|
|
|
socketpair.o sockopt.o stat.o strofaddr.o symlink.o termios.o \
|
|
|
|
time.o times.o truncate.o umask.o unixsupport.o unlink.o \
|
|
|
|
utimes.o wait.o write.o
|
1995-05-08 08:18:32 -07:00
|
|
|
|
1995-10-23 09:58:06 -07:00
|
|
|
all: libunix.a unix.cmi unix.cma
|
1995-05-08 08:18:32 -07:00
|
|
|
|
1995-10-23 09:58:06 -07:00
|
|
|
allopt: libunix.a unix.cmi unix.cmxa
|
1995-05-08 08:18:32 -07:00
|
|
|
|
|
|
|
libunix.a: $(OBJS)
|
|
|
|
rm -f libunix.a
|
|
|
|
ar rc libunix.a $(OBJS)
|
|
|
|
$(RANLIB) libunix.a
|
|
|
|
|
1995-10-23 09:58:06 -07:00
|
|
|
unix.cma: unix.cmo
|
1996-04-29 06:22:30 -07:00
|
|
|
$(CAMLC) -a -linkall -o unix.cma unix.cmo
|
1995-10-23 09:58:06 -07:00
|
|
|
|
|
|
|
unix.cmxa: unix.cmx
|
1996-04-29 06:22:30 -07:00
|
|
|
$(CAMLOPT) -a -linkall -o unix.cmxa unix.cmx
|
1995-05-08 08:18:32 -07:00
|
|
|
|
1996-04-30 07:53:58 -07:00
|
|
|
unix.cmx: ../../ocamlopt
|
1995-11-26 12:23:16 -08:00
|
|
|
|
1995-05-08 08:18:32 -07:00
|
|
|
clean:
|
1995-11-06 03:09:03 -08:00
|
|
|
rm -f *.cm*
|
|
|
|
|
|
|
|
realclean: clean
|
|
|
|
rm -f *.a *.o
|
1995-05-08 08:18:32 -07:00
|
|
|
|
|
|
|
install:
|
|
|
|
cp libunix.a $(LIBDIR)/libunix.a
|
|
|
|
cd $(LIBDIR); $(RANLIB) libunix.a
|
1995-10-23 09:58:06 -07:00
|
|
|
cp unix.cmi unix.cma $(LIBDIR)
|
|
|
|
|
|
|
|
installopt:
|
1995-11-09 05:23:22 -08:00
|
|
|
cp unix.cmx unix.cmxa unix.a $(LIBDIR)
|
1995-10-23 09:58:06 -07:00
|
|
|
cd $(LIBDIR); $(RANLIB) unix.a
|
1995-05-08 08:18:32 -07:00
|
|
|
|
1995-10-23 09:58:06 -07:00
|
|
|
.SUFFIXES: .ml .mli .cmo .cmi .cmx
|
1995-05-08 08:18:32 -07:00
|
|
|
|
|
|
|
.mli.cmi:
|
|
|
|
$(CAMLC) -c $(COMPFLAGS) $<
|
|
|
|
|
|
|
|
.ml.cmo:
|
|
|
|
$(CAMLC) -c $(COMPFLAGS) $<
|
|
|
|
|
1995-10-23 09:58:06 -07:00
|
|
|
.ml.cmx:
|
|
|
|
$(CAMLOPT) -c $(COMPFLAGS) $<
|
|
|
|
|
1995-05-08 08:18:32 -07:00
|
|
|
depend:
|
|
|
|
gcc -MM $(CFLAGS) *.c > .depend
|
1996-04-30 07:53:58 -07:00
|
|
|
../../tools/ocamldep *.mli *.ml >> .depend
|
1995-05-08 08:18:32 -07:00
|
|
|
|
|
|
|
include .depend
|