From: rich Date: Sun, 26 Oct 2003 10:20:19 +0000 (+0000) Subject: Added META (package information) for perl4caml. X-Git-Url: http://git.annexia.org/?a=commitdiff_plain;h=fae1d1e9b2ea4b5f7995063ccb792298f1974afc;hp=2e31fdfb913ec085bb1e4d86affea9aa3b0a727e;p=perl4caml.git Added META (package information) for perl4caml. --- diff --git a/.cvsignore b/.cvsignore index aa3da54..571651f 100644 --- a/.cvsignore +++ b/.cvsignore @@ -4,4 +4,5 @@ *.cma *.cmxa perl4caml-*.tar.gz -html \ No newline at end of file +html +META \ No newline at end of file diff --git a/META.in b/META.in new file mode 100644 index 0000000..b6bce44 --- /dev/null +++ b/META.in @@ -0,0 +1,5 @@ +name="@PACKAGE@" +version="@VERSION@" +description="Perl bindings for OCaml" +archive(byte)="perl4caml.cma" +archive(native)="perl4caml.cmxa" diff --git a/Makefile b/Makefile index 7b1d5e5..079aef1 100644 --- a/Makefile +++ b/Makefile @@ -1,6 +1,6 @@ # Interface to Perl from OCaml. # Copyright (C) 2003 Merjis Ltd. -# $Id: Makefile,v 1.12 2003-10-22 10:18:26 rich Exp $ +# $Id: Makefile,v 1.13 2003-10-26 10:20:19 rich Exp $ include Makefile.config @@ -21,6 +21,8 @@ CFLAGS := -Wall -Wno-unused -I$(PERLINCDIR) LIBPERL := $(shell perl -MExtUtils::Embed -e ldopts) +SED := sed + # XXX Hack required by ocamlopt, and sometimes ocamlc. # To work out what this should be, try: # `shell perl -MExtUtils::Embed -e ldopts' @@ -43,7 +45,7 @@ WRAPPERS := \ wrappers/pl_HTTP_Response.cmo \ wrappers/pl_LWP_UserAgent.cmo -all: perl4caml.cma perl4caml.cmxa all-examples html +all: perl4caml.cma perl4caml.cmxa META all-examples html perl4caml.cma: perl.cmo perl_c.o $(WRAPPERS) $(OCAMLMKLIB) -o perl4caml $(LIBPERL) $^ @@ -86,12 +88,17 @@ examples/google.opt: examples/google.cmx .SUFFIXES: .mli .ml .cmi .cmo .cmx +META: META.in Makefile.config + $(SED) -e 's/@PACKAGE@/$(PACKAGE)/' \ + -e 's/@VERSION@/$(VERSION)/' \ + < $< > $@ + # Clean. JUNKFILES = core *~ *.bak *.cmi *.cmo *.cmx *.cma *.cmxa *.o *.a *.so clean: - rm -f examples/test examples/loadpage examples/google + rm -f META examples/test examples/loadpage examples/google for d in . examples wrappers; do (cd $$d; rm -f $(JUNKFILES)); done # Build dependencies. @@ -114,7 +121,7 @@ install: install -c -m 0755 -d $(OCAMLLIBDIR)/perl install -c -m 0755 -d $(OCAMLLIBDIR)/stublibs install -c -m 0644 perl.cmi perl.mli perl4caml.cma perl4caml.cmxa \ - perl4caml.a libperl4caml.a \ + perl4caml.a libperl4caml.a META \ $(WRAPPERS:.cmo=.ml) $(WRAPPERS:.cmo=.cmi) $(OCAMLLIBDIR)/perl install -c -m 0644 dllperl4caml.so $(OCAMLLIBDIR)/stublibs diff --git a/Makefile.config b/Makefile.config index 4ab9d60..043ba7a 100644 --- a/Makefile.config +++ b/Makefile.config @@ -1,5 +1,5 @@ # perl4caml configuration -*- Makefile -*- -# $Id: Makefile.config,v 1.10 2003-10-16 13:41:22 rich Exp $ +# $Id: Makefile.config,v 1.11 2003-10-26 10:20:19 rich Exp $ # PERLINCDIR # Directory containing the Perl include files, eg. . @@ -15,4 +15,4 @@ OCAMLLIBDIR := $(shell ocamlc -where) # PACKAGE and VERSION PACKAGE := perl4caml -VERSION := 0.3.5 +VERSION := 0.3.6