summaryrefslogtreecommitdiff
path: root/databases
diff options
context:
space:
mode:
authorjaapb <jaapb@pkgsrc.org>2012-09-16 11:34:45 +0000
committerjaapb <jaapb@pkgsrc.org>2012-09-16 11:34:45 +0000
commitacbc1dc988fd85d1937c43716d715ca665552e7a (patch)
tree0600ec7f8fe04661e6de6ba67f175ff925eec369 /databases
parentcfb2ff3be5b5107f8104f69e536b3121fed01355 (diff)
downloadpkgsrc-acbc1dc988fd85d1937c43716d715ca665552e7a.tar.gz
Updated databases/ocaml-sqlite3 to version 2.0.2. Summary of changes:
2012-07-20: Downgraded findlib version requirement to support the Debian testing branch. 2012-07-16: Replaced String.trim function in myocamlbuild.ml to allow compiling with OCaml 3.12.1. 2012-07-15: New major release version 2.0.0: * Upgraded to OCaml 4.00 * Switched to Oasis for packaging * Switched to OCamlBuild for the build process * Rewrote README in Markdown * Added stricter compilation flags 2012-05-19: Fixed cpp warnings and removed superfluous check for dynamic linking library. The latter improves portability to FreeBSD. 2011-03-10: Added sqlite3_open_v2 functionality. There are also some changes to the package itself: the upstream distribution site changed; the maintainer e-mail address as well, and the package now uses PLIST_VARS.
Diffstat (limited to 'databases')
-rw-r--r--databases/ocaml-sqlite3/Makefile47
-rw-r--r--databases/ocaml-sqlite3/PLIST7
-rw-r--r--databases/ocaml-sqlite3/PLIST.opt5
-rw-r--r--databases/ocaml-sqlite3/distinfo12
-rw-r--r--databases/ocaml-sqlite3/patches/patch-Makefile.in41
-rw-r--r--databases/ocaml-sqlite3/patches/patch-configure.ac14
-rw-r--r--databases/ocaml-sqlite3/patches/patch-lib_sqlite3_stubs.c14
-rw-r--r--databases/ocaml-sqlite3/patches/patch-sqlite3_stubs.c15
8 files changed, 53 insertions, 102 deletions
diff --git a/databases/ocaml-sqlite3/Makefile b/databases/ocaml-sqlite3/Makefile
index 82e0ffdf467..f81b47439e0 100644
--- a/databases/ocaml-sqlite3/Makefile
+++ b/databases/ocaml-sqlite3/Makefile
@@ -1,37 +1,48 @@
-# $NetBSD: Makefile,v 1.1.1.1 2012/05/14 09:20:39 wiz Exp $
+# $NetBSD: Makefile,v 1.2 2012/09/16 11:34:45 jaapb Exp $
#
-DISTNAME= ocaml-sqlite3-1.6.1
+PKGNAME= ocaml-sqlite3-${VERSION}
+DISTNAME= sqlite3-ocaml-${VERSION}
+VERSION= 2.0.2
CATEGORIES= databases
-MASTER_SITES= http://www.ocaml.info/ocaml_sources/
+MASTER_SITES= https://bitbucket.org/mmottl/sqlite3-ocaml/downloads/
+FETCH_USING= curl
-MAINTAINER= jaapb@kerguelen.org
-HOMEPAGE= http://www.ocaml.info/home/ocaml_sources.html
+MAINTAINER= jaapb@NetBSD.org
+HOMEPAGE= https://bitbucket.org/mmottl/sqlite3-ocaml/
COMMENT= Sqlite bindings for OCaml
LICENSE= mit
PKG_DESTDIR_SUPPORT= user-destdir
-DEPENDS+= ocaml-findlib-[0-9]*:../../devel/ocaml-findlib
+HAS_CONFIGURE= yes
+CONFIGURE_ARGS+= --destdir "${DESTDIR}" --prefix "${PREFIX}"
+USE_TOOLS+= gmake
+USE_LANGUAGES= c
-GNU_CONFIGURE= yes
-USE_TOOLS+= gmake autoconf
-BUILD_TARGET= docs bytecode
-
-MAKE_ENV+= OCAML_SITELIBDIR="${PREFIX}/lib/ocaml/site-lib"
-MAKE_JOBS_SAFE= no
+SUBST_CLASSES+= destdir
+SUBST_STAGE.destdir= post-configure
+SUBST_MESSAGE.destdir= Changing install location to DESTDIR
+SUBST_FILES.destdir= setup.ml
+SUBST_SED.destdir= -e 's,"install" :: findlib_name,"install" :: "-destdir ${DESTDIR}${PREFIX}/lib/ocaml/site-lib" :: "-ldconf /var/null" :: findlib_name,'
+PLIST_VARS= opt
.if (${MACHINE_ARCH} == "i386") || (${MACHINE_ARCH} == "powerpc") || \
- (${MACHINE_ARCH} == "sparc") || (${MACHINE_ARCH} == "x86_64")
-PLIST_SRC+= PLIST.opt
-BUILD_TARGET+= opt sqlite3.cmxs
+ (${MACHINE_ARCH} == "sparc") || (${MACHINE_ARCH} == "x86_64") || \
+ (${MACHINE_ARCH} == "arm")
+PLIST.opt= yes
.endif
-PLIST_SRC+= PLIST
+do-configure:
+ cd ${WRKSRC} && ${CONFIGURE_ENV} ocaml setup.ml -configure ${CONFIGURE_ARGS}
+
+do-build:
+ cd ${WRKSRC} && ${MAKE_ENV} ocaml setup.ml -build
-pre-configure:
- cd ${WRKSRC} && autoconf
+do-install:
+ cd ${WRKSRC} && ${MAKE_ENV} ocaml setup.ml -install
.include "../../lang/ocaml/buildlink3.mk"
+.include "../../devel/ocaml-findlib/buildlink3.mk"
.include "../../databases/sqlite3/buildlink3.mk"
.include "../../mk/bsd.pkg.mk"
diff --git a/databases/ocaml-sqlite3/PLIST b/databases/ocaml-sqlite3/PLIST
index b8f6ecdc2a9..c0bf95b43a3 100644
--- a/databases/ocaml-sqlite3/PLIST
+++ b/databases/ocaml-sqlite3/PLIST
@@ -1,10 +1,13 @@
-@comment $NetBSD: PLIST,v 1.1.1.1 2012/05/14 09:20:39 wiz Exp $
+@comment $NetBSD: PLIST,v 1.2 2012/09/16 11:34:45 jaapb Exp $
@unexec %D/libexec/ocaml-findlib-register del %D/lib/ocaml/site-lib/sqlite3
-bin/sqlite3top
lib/ocaml/site-lib/sqlite3/META
lib/ocaml/site-lib/sqlite3/dllsqlite3_stubs.so
lib/ocaml/site-lib/sqlite3/libsqlite3_stubs.a
+${PLIST.opt}lib/ocaml/site-lib/sqlite3/sqlite3.a
lib/ocaml/site-lib/sqlite3/sqlite3.cma
lib/ocaml/site-lib/sqlite3/sqlite3.cmi
+${PLIST.opt}lib/ocaml/site-lib/sqlite3/sqlite3.cmx
+${PLIST.opt}lib/ocaml/site-lib/sqlite3/sqlite3.cmxa
+${PLIST.opt}lib/ocaml/site-lib/sqlite3/sqlite3.cmxs
lib/ocaml/site-lib/sqlite3/sqlite3.mli
@exec %D/libexec/ocaml-findlib-register add %D/lib/ocaml/site-lib/sqlite3
diff --git a/databases/ocaml-sqlite3/PLIST.opt b/databases/ocaml-sqlite3/PLIST.opt
deleted file mode 100644
index 560738852bd..00000000000
--- a/databases/ocaml-sqlite3/PLIST.opt
+++ /dev/null
@@ -1,5 +0,0 @@
-@comment $NetBSD: PLIST.opt,v 1.1.1.1 2012/05/14 09:20:39 wiz Exp $
-lib/ocaml/site-lib/sqlite3/sqlite3.a
-lib/ocaml/site-lib/sqlite3/sqlite3.cmx
-lib/ocaml/site-lib/sqlite3/sqlite3.cmxa
-lib/ocaml/site-lib/sqlite3/sqlite3.cmxs
diff --git a/databases/ocaml-sqlite3/distinfo b/databases/ocaml-sqlite3/distinfo
index 6eb0b2eed43..856591abaf2 100644
--- a/databases/ocaml-sqlite3/distinfo
+++ b/databases/ocaml-sqlite3/distinfo
@@ -1,8 +1,6 @@
-$NetBSD: distinfo,v 1.2 2012/09/01 12:48:10 marino Exp $
+$NetBSD: distinfo,v 1.3 2012/09/16 11:34:46 jaapb Exp $
-SHA1 (ocaml-sqlite3-1.6.1.tar.gz) = 1f67e2bd80907a755ac5689fc466020f5f2c394c
-RMD160 (ocaml-sqlite3-1.6.1.tar.gz) = dbfdb928041fdb8ccaac8f1d14223124d6bfe8ec
-Size (ocaml-sqlite3-1.6.1.tar.gz) = 59073 bytes
-SHA1 (patch-Makefile.in) = 4c60faa5c9e0e2b5ae55d6fc96d63a12fac369bd
-SHA1 (patch-configure.ac) = 18f762288c41c4e23cfc263108b20339ff9179cb
-SHA1 (patch-sqlite3_stubs.c) = b069cfda4e7aeb40ebedab1c531b1157a031428c
+SHA1 (sqlite3-ocaml-2.0.2.tar.gz) = c95ccd9652e9bfa01becde5c2241dc0c9e153fae
+RMD160 (sqlite3-ocaml-2.0.2.tar.gz) = 85bca16418a7864b4cb78a4dc729b66e12bad1f8
+Size (sqlite3-ocaml-2.0.2.tar.gz) = 60430 bytes
+SHA1 (patch-lib_sqlite3_stubs.c) = bd5970939a4ad748067337425992346de2b571a5
diff --git a/databases/ocaml-sqlite3/patches/patch-Makefile.in b/databases/ocaml-sqlite3/patches/patch-Makefile.in
deleted file mode 100644
index 55aa525263c..00000000000
--- a/databases/ocaml-sqlite3/patches/patch-Makefile.in
+++ /dev/null
@@ -1,41 +0,0 @@
-$NetBSD: patch-Makefile.in,v 1.1.1.1 2012/05/14 09:20:39 wiz Exp $
-
-change install procedure for DESTDIR, and build cmxs for dynamic linking
---- Makefile.in.orig 2011-03-10 17:47:28.000000000 +0000
-+++ Makefile.in
-@@ -37,18 +37,20 @@ test: bytecode opt
-
- clean:
- @cd test && $(MAKE) clean
-- rm -f *.o *.cmo *.cmx *.cmi *.so *.cma *.cmxa *.a sqlite3top
-+ rm -f *.o *.cmo *.cmx *.cmi *.so *.cma *.cmxa *.cmxs *.a sqlite3top
-
- distclean: clean
- rm -rf autom4te.* config.* META Makefile doc
-
- # install rebuilds sqlite3top to point to the findlib-managed dll and not the
- # one in .
--install: sqlite3.cma sqlite3.cmxa sqlite3top
-+install: sqlite3.cma sqlite3top
-+ ${BSD_INSTALL_DATA_DIR} ${DESTDIR}${OCAML_SITELIBDIR}
- [ -f *.so ] && SO_FILES=*.so; \
-- ocamlfind install sqlite3 META sqlite3.cmi sqlite3.mli sqlite3.cma *.cmxa *.a *.cmx $$SO_FILES
-- ocamlfind ocamlmktop -o sqlite3top -package "sqlite3" sqlite3.cma
-- $(INSTALL) sqlite3top $(bindir)/sqlite3top
-+ ocamlfind install -ldconf /dev/null -destdir ${DESTDIR}${OCAML_SITELIBDIR} -optional sqlite3 META sqlite3.cmi sqlite3.mli sqlite3.cma *.cmxa *.cmxs *.a *.cmx $$SO_FILES
-+ OCAMLPATH="${DESTDIR}${OCAML_SITELIBDIR}" ocamlfind ocamlmktop -o sqlite3top -package "sqlite3" sqlite3.cma
-+ ${BSD_INSTALL_SCRIPT_DIR} ${DESTDIR}$(bindir)
-+ ${BSD_INSTALL_SCRIPT} sqlite3top ${DESTDIR}$(bindir)/sqlite3top
-
- remove: uninstall
- uninstall:
-@@ -68,6 +70,9 @@ sqlite3.cma: sqlite3.cmo sqlite3_stubs.o
- sqlite3.cmxa: sqlite3.cmx sqlite3.o sqlite3_stubs.o
- ocamlmklib -o sqlite3 -oc sqlite3_stubs sqlite3.cmx sqlite3_stubs.o -L. $(LDFLAGS) $(LIBS) $(MKLIBFLAGS)
-
-+sqlite3.cmxs: sqlite3.cmxa
-+ ocamlopt -linkall -shared -o sqlite3.cmxs sqlite3.cmxa
-+
- sqlite3.cmo: sqlite3.cmi sqlite3.ml
-
- .SUFFIXES: .ml .mli .cmo .cmi .cmx
diff --git a/databases/ocaml-sqlite3/patches/patch-configure.ac b/databases/ocaml-sqlite3/patches/patch-configure.ac
deleted file mode 100644
index 9c6af0ca0f4..00000000000
--- a/databases/ocaml-sqlite3/patches/patch-configure.ac
+++ /dev/null
@@ -1,14 +0,0 @@
-$NetBSD: patch-configure.ac,v 1.1.1.1 2012/05/14 09:20:39 wiz Exp $
-
-disable linking to libdl which is not used
---- configure.ac.orig 2010-12-20 05:13:10.000000000 +0000
-+++ configure.ac
-@@ -26,7 +26,7 @@ AC_ARG_WITH(
- AC_CHECKING(for sqlite3 library)
- AC_CHECK_LIB(
- sqlite3, sqlite3_open,,
-- AC_ERROR([SQLite is required. See the --with-sqlite3 configure option.]), -ldl)
-+ AC_ERROR([SQLite is required. See the --with-sqlite3 configure option.]))
-
- AC_CHECKING(for Sqlite header files)
- AC_CHECK_HEADER(sqlite3.h,,
diff --git a/databases/ocaml-sqlite3/patches/patch-lib_sqlite3_stubs.c b/databases/ocaml-sqlite3/patches/patch-lib_sqlite3_stubs.c
new file mode 100644
index 00000000000..13e5a349c5c
--- /dev/null
+++ b/databases/ocaml-sqlite3/patches/patch-lib_sqlite3_stubs.c
@@ -0,0 +1,14 @@
+$NetBSD: patch-lib_sqlite3_stubs.c,v 1.1 2012/09/16 11:34:46 jaapb Exp $
+
+Correct system-dependent defines
+--- lib/sqlite3_stubs.c.orig 2012-07-20 15:39:49.000000000 +0000
++++ lib/sqlite3_stubs.c
+@@ -40,7 +40,7 @@
+
+ #if __GNUC__ >= 3
+ # define inline inline __attribute__ ((always_inline))
+-# if !defined(__FreeBSD__) && !__APPLE__
++# if !defined(__FreeBSD__) && !defined(__NetBSD__) && !defined(__DragonFly) && !__APPLE__
+ # define __unused __attribute__ ((unused))
+ # endif
+ #else
diff --git a/databases/ocaml-sqlite3/patches/patch-sqlite3_stubs.c b/databases/ocaml-sqlite3/patches/patch-sqlite3_stubs.c
deleted file mode 100644
index bf081b7c451..00000000000
--- a/databases/ocaml-sqlite3/patches/patch-sqlite3_stubs.c
+++ /dev/null
@@ -1,15 +0,0 @@
-$NetBSD: patch-sqlite3_stubs.c,v 1.2 2012/09/01 12:48:10 marino Exp $
-
-Avoiding redefinition of __unused on NetBSD and DragonFly
-
---- sqlite3_stubs.c.orig 2008-04-13 14:26:56.000000000 +0200
-+++ sqlite3_stubs.c 2008-04-13 14:27:35.000000000 +0200
-@@ -40,7 +40,7 @@
-
- #if __GNUC__ >= 3
- # define inline inline __attribute__ ((always_inline))
--# if !defined(__FreeBSD__) && !__APPLE__
-+# if !defined(__FreeBSD__) && !defined(__NetBSD__) && !defined(__DragonFly__) && !__APPLE__
- # define __unused __attribute__ ((unused))
- # endif
- #else