Update diff for patched Makefile,v 1.14
Tested on amd64-current
2013/11/18 Roman Kravchuk kravchuk...@gmail.com
OK maintainer.
2013/11/18 Alexey Suslikov alexey.susli...@gmail.com
Ok regress tests on -current amd64 with PostgreSQL 9.3. Earlier version
was tested on 5.4 amd64 with PostgreSQL 9.2.
OKs? Comments?
Index: Makefile
===
RCS file: /cvs/ports/databases/node-pg/Makefile,v
retrieving revision 1.14
diff -u -p -u -p -r1.14 Makefile
--- Makefile5 Nov 2013 16:24:51 - 1.14
+++ Makefile18 Nov 2013 15:28:45 -
@@ -2,10 +2,9 @@
COMMENT = postgresql client for Node.js
-NPM_VERSION = 1.1.0
+NPM_VERSION = 2.8.2
NPM_NAME = pg
CATEGORIES = databases
-REVISION = 2
MAINTAINER = Roman Kravchuk kravchuk...@gmail.com
@@ -26,13 +25,15 @@ RUN_DEPENDS = devel/node-generic-pool \
devel/node-buffer-writer
MODNODE_DEPENDS = generic-pool \
- buffer-writer
+ buffer-writer \
+ node-gyp
pre-configure:
${SUBST_CMD} ${WRKSRC}/binding.gyp
# Must have a database setup running on localhost with
# user=postgres and password=1234
-TEST_TARGET = test-all
+TEST_TARGET = test-all
+TEST_FLAGS = WRKDIR=${WRKDIR}
.include bsd.port.mk
Index: distinfo
===
RCS file: /cvs/ports/databases/node-pg/distinfo,v
retrieving revision 1.3
diff -u -p -u -p -r1.3 distinfo
--- distinfo19 May 2013 15:22:51 - 1.3
+++ distinfo18 Nov 2013 15:28:45 -
@@ -1,2 +1,2 @@
-SHA256 (pg-1.1.0.tgz) = 81EW5BZgciba7hInOZg2vtBT+mhGh+30wz9t4iyAoPk=
-SIZE (pg-1.1.0.tgz) = 216884
+SHA256 (pg-2.8.2.tgz) = 8H0uPiC/Uu5rHg3MZN6gBz+4i7vyUMxxgkHC039NrlY=
+SIZE (pg-2.8.2.tgz) = 71625
Index: patches/patch-Makefile
===
RCS file: patches/patch-Makefile
diff -N patches/patch-Makefile
--- /dev/null 1 Jan 1970 00:00:00 -
+++ patches/patch-Makefile 18 Nov 2013 15:28:45 -
@@ -0,0 +1,76 @@
+$OpenBSD$
+--- Makefile.orig Fri Sep 6 00:14:17 2013
Makefile Thu Sep 12 12:32:08 2013
+@@ -1,9 +1,12 @@
+ SHELL := /bin/sh
+
+-connectionString=postgres://
++connectionString=postgres://postgres:1234@localhost:5432/postgres
+
+ params := $(connectionString)
+
++MODULES := $(WRKDIR)/node_modules
++PG := $(MODULES)/pg
++
+ node-command := xargs -n 1 -I file node file $(params)
+
+ .PHONY : test test-connection test-integration bench test-native \
+@@ -21,7 +24,7 @@ help:
+
+ test: test-unit
+
+-test-all: jshint test-unit test-integration test-native test-binary
++test-all: jshint prepare-test-db test-unit test-integration test-native
test-binary
+
+ test-travis: test-all upgrade-pg
+ @make test-all
connectionString=postgres://postgres@localhost:5433/postgres
+@@ -37,36 +40,38 @@ build/default/binding.node:
+ @node-gyp rebuild
+
+ test-unit:
+- @find test/unit -name *-tests.js | $(node-command)
++ @find $(PG)/test/unit -name *-tests.js | $(node-command)
+
+ test-connection:
+ @echo ***Testing connection***
+- @node script/test-connection.js $(params)
++ @node $(PG)/script/test-connection.js $(params)
+
+ test-connection-binary:
+ @echo ***Testing binary connection***
+- @node script/test-connection.js $(params) binary
++ @node $(PG)/script/test-connection.js $(params) binary
+
+-test-native: build/default/binding.node
++test-native:
+ @echo ***Testing native bindings***
+- @find test/native -name *-tests.js | $(node-command)
+- @find test/integration -name *-tests.js | $(node-command) native
++ @find $(PG)/test/native -name *-tests.js | $(node-command)
++ @find $(PG)/test/integration -name *-tests.js | $(node-command) native
+
+-test-integration: test-connection build/default/binding.node
++test-integration: test-connection
+ @echo ***Testing Pure Javascript***
+- @find test/integration -name *-tests.js | $(node-command)
++ @find $(PG)/test/integration -name *-tests.js | $(node-command)
+
+ test-binary: test-connection-binary
+ @echo ***Testing Pure Javascript (binary)***
+- @find test/integration -name *-tests.js | $(node-command) binary
++ @find $(PG)/test/integration -name *-tests.js | $(node-command) binary
+
+ prepare-test-db:
+ @echo ***Preparing the database for tests***
+- @find script/create-test-tables.js | $(node-command)
++ @find $(PG)/script/create-test-tables.js | $(node-command) down
++ @find $(PG)/script/create-test-tables.js | $(node-command)
+
+ jshint:
++ @test -s $(MODULES)/jshint/bin/jshint || { echo Please run: 'cd \`make
show=WRKDIR\`; npm install jshint; cd -'; exit 1; }
+ @echo ***Starting jshint***
+- @./node_modules/.bin/jshint lib
++ @$(MODULES)/jshint/bin/jshint $(PG)/lib
+
+ publish:
+ @rm -r build ||