1 diff -Nuar camlzip-1.04/Makefile camlzip-1.04.nixpkgs/Makefile
2 --- camlzip-1.04/Makefile 2002-04-22 17:28:57.000000000 +0200
3 +++ camlzip-1.04.nixpkgs/Makefile 2010-12-12 18:30:49.000000000 +0100
7 # The directory containing the Zlib library (libz.a or libz.so)
8 -ZLIB_LIBDIR=/usr/local/lib
9 +ZLIB_LIBDIR=@ZLIB_LIBDIR@
11 # The directory containing the Zlib header file (zlib.h)
12 -ZLIB_INCLUDE=/usr/local/include
14 -# Where to install the library. By default: sub-directory 'zip' of
15 -# OCaml's standard library directory.
16 -INSTALLDIR=`$(OCAMLC) -where`/zip
17 +ZLIB_INCLUDE=@ZLIB_INCLUDE@
19 ### End of configuration section
27 OBJS=zlib.cmo zip.cmo gzip.cmo
30 +LIBINSTALL_FILES = $(wildcard *.mli *.cmi *.cma *.cmxa *.a *.so)
32 all: libcamlzip.a zip.cma
34 allopt: libcamlzip.a zip.cmxa
39 - mkdir -p $(INSTALLDIR)
40 - cp zip.cma zip.cmi gzip.cmi zip.mli gzip.mli libcamlzip.a $(INSTALLDIR)
41 - if test -f dllcamlzip.so; then \
42 - cp dllcamlzip.so $(INSTALLDIR); \
43 - ldconf=`$(OCAMLC) -where`/ld.conf; \
44 - installdir=$(INSTALLDIR); \
45 - if test `grep -s -c $$installdir'$$' $$ldconf || :` = 0; \
46 - then echo $$installdir >> $$ldconf; fi \
50 - cp zip.cmxa zip.a zip.cmx gzip.cmx $(INSTALLDIR)
51 + $(OCAMLFIND) install zip META $(LIBINSTALL_FILES)
54 gcc -MM -I$(ZLIB_INCLUDE) *.c > .depend