2010-12-12 17:45:57 +00:00
|
|
|
diff -Nuar camlzip-1.04/Makefile camlzip-1.04.nixpkgs/Makefile
|
* Add ocaml packages findlib, camlzip, ocaml-ssl, ocaml-batteries, menhir, camomile, ocaml-lwt, cryptokit, ocaml-cryptgps, ounit, ocaml-react
svn path=/nixpkgs/trunk/; revision=25041
2010-12-09 15:40:04 +00:00
|
|
|
--- camlzip-1.04/Makefile 2002-04-22 17:28:57.000000000 +0200
|
2010-12-12 17:45:57 +00:00
|
|
|
+++ camlzip-1.04.nixpkgs/Makefile 2010-12-12 18:30:49.000000000 +0100
|
|
|
|
@@ -4,14 +4,10 @@
|
* Add ocaml packages findlib, camlzip, ocaml-ssl, ocaml-batteries, menhir, camomile, ocaml-lwt, cryptokit, ocaml-cryptgps, ounit, ocaml-react
svn path=/nixpkgs/trunk/; revision=25041
2010-12-09 15:40:04 +00:00
|
|
|
ZLIB_LIB=-lz
|
|
|
|
|
|
|
|
# The directory containing the Zlib library (libz.a or libz.so)
|
|
|
|
-ZLIB_LIBDIR=/usr/local/lib
|
|
|
|
+ZLIB_LIBDIR=@ZLIB_LIBDIR@
|
|
|
|
|
|
|
|
# The directory containing the Zlib header file (zlib.h)
|
|
|
|
-ZLIB_INCLUDE=/usr/local/include
|
2010-12-12 17:45:57 +00:00
|
|
|
-
|
|
|
|
-# Where to install the library. By default: sub-directory 'zip' of
|
|
|
|
-# OCaml's standard library directory.
|
* Add ocaml packages findlib, camlzip, ocaml-ssl, ocaml-batteries, menhir, camomile, ocaml-lwt, cryptokit, ocaml-cryptgps, ounit, ocaml-react
svn path=/nixpkgs/trunk/; revision=25041
2010-12-09 15:40:04 +00:00
|
|
|
-INSTALLDIR=`$(OCAMLC) -where`/zip
|
2010-12-12 17:45:57 +00:00
|
|
|
+ZLIB_INCLUDE=@ZLIB_INCLUDE@
|
* Add ocaml packages findlib, camlzip, ocaml-ssl, ocaml-batteries, menhir, camomile, ocaml-lwt, cryptokit, ocaml-cryptgps, ounit, ocaml-react
svn path=/nixpkgs/trunk/; revision=25041
2010-12-09 15:40:04 +00:00
|
|
|
|
|
|
|
### End of configuration section
|
|
|
|
|
2010-12-12 17:45:57 +00:00
|
|
|
@@ -19,10 +15,13 @@
|
|
|
|
OCAMLOPT=ocamlopt
|
|
|
|
OCAMLDEP=ocamldep
|
|
|
|
OCAMLMKLIB=ocamlmklib
|
|
|
|
+OCAMLFIND=ocamlfind
|
|
|
|
|
|
|
|
OBJS=zlib.cmo zip.cmo gzip.cmo
|
|
|
|
C_OBJS=zlibstubs.o
|
|
|
|
|
|
|
|
+LIBINSTALL_FILES = $(wildcard *.mli *.cmi *.cma *.cmxa *.a *.so)
|
|
|
|
+
|
|
|
|
all: libcamlzip.a zip.cma
|
|
|
|
|
|
|
|
allopt: libcamlzip.a zip.cmxa
|
|
|
|
@@ -55,18 +54,7 @@
|
|
|
|
rm -f *.o *.a
|
|
|
|
|
|
|
|
install:
|
|
|
|
- mkdir -p $(INSTALLDIR)
|
|
|
|
- cp zip.cma zip.cmi gzip.cmi zip.mli gzip.mli libcamlzip.a $(INSTALLDIR)
|
|
|
|
- if test -f dllcamlzip.so; then \
|
|
|
|
- cp dllcamlzip.so $(INSTALLDIR); \
|
* Add ocaml packages findlib, camlzip, ocaml-ssl, ocaml-batteries, menhir, camomile, ocaml-lwt, cryptokit, ocaml-cryptgps, ounit, ocaml-react
svn path=/nixpkgs/trunk/; revision=25041
2010-12-09 15:40:04 +00:00
|
|
|
- ldconf=`$(OCAMLC) -where`/ld.conf; \
|
|
|
|
- installdir=$(INSTALLDIR); \
|
|
|
|
- if test `grep -s -c $$installdir'$$' $$ldconf || :` = 0; \
|
|
|
|
- then echo $$installdir >> $$ldconf; fi \
|
2010-12-12 17:45:57 +00:00
|
|
|
- fi
|
|
|
|
-
|
|
|
|
-installopt:
|
|
|
|
- cp zip.cmxa zip.a zip.cmx gzip.cmx $(INSTALLDIR)
|
2016-07-07 14:29:13 +01:00
|
|
|
+ $(OCAMLFIND) install zip META $(LIBINSTALL_FILES)
|
* Add ocaml packages findlib, camlzip, ocaml-ssl, ocaml-batteries, menhir, camomile, ocaml-lwt, cryptokit, ocaml-cryptgps, ounit, ocaml-react
svn path=/nixpkgs/trunk/; revision=25041
2010-12-09 15:40:04 +00:00
|
|
|
|
2010-12-12 17:45:57 +00:00
|
|
|
depend:
|
|
|
|
gcc -MM -I$(ZLIB_INCLUDE) *.c > .depend
|