Bug 179955 - databases/tablelog: does not build with pgsql 92
Summary: databases/tablelog: does not build with pgsql 92
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: John Marino
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-06-25 12:00 UTC by John Marino
Modified: 2014-01-22 13:10 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description John Marino 2013-06-25 12:00:01 UTC
This port won't build with the non-default pgsql 92 client.

table_log.c: In function 'table_log':
table_log.c:134: warning: implicit declaration of function 'RelationGetNamespace'
table_log.c:140: error: dereferencing pointer to incomplete type
table_log.c: In function '__table_log':
table_log.c:301: error: dereferencing pointer to incomplete type
table_log.c:310: error: dereferencing pointer to incomplete type
table_log.c:312: error: dereferencing pointer to incomplete type
table_log.c:346: error: dereferencing pointer to incomplete type
table_log.c:354: error: dereferencing pointer to incomplete type
table_log.c:373: error: dereferencing pointer to incomplete type
table_log.c:381: error: dereferencing pointer to incomplete type
table_log.c: In function 'table_log_restore_table':
table_log.c:794: error: 'timestamptz_out' undeclared (first use in this function)
table_log.c:794: error: (Each undeclared identifier is reported only once
table_log.c:794: error: for each function it appears in.)

Fix: 

The project looks stagnant, last release in 2007.
Suggest adding makefile directives to indicate that pgsql 92 not supported, e.g. WANT_PGSQL_VERSION= 91-
How-To-Repeat: Set the default pgsql version to 92, then rebuild everything including this port
Comment 1 Edwin Groothuis freebsd_committer freebsd_triage 2013-06-25 12:00:15 UTC
Maintainer of databases/tablelog,

Please note that PR ports/179955 has just been submitted.

If it contains a patch for an upgrade, an enhancement or a bug fix
you agree on, reply to this email stating that you approve the patch
and a committer will take care of it.

The full text of the PR can be found at:
    http://www.freebsd.org/cgi/query-pr.cgi?pr=ports/179955

-- 
Edwin Groothuis via the GNATS Auto Assign Tool
edwin@FreeBSD.org
Comment 2 Edwin Groothuis freebsd_committer freebsd_triage 2013-06-25 12:00:16 UTC
State Changed
From-To: open->feedback

Awaiting maintainers feedback (via the GNATS Auto Assign Tool)
Comment 3 John Marino freebsd_committer freebsd_triage 2013-07-21 20:47:33 UTC
State Changed
From-To: feedback->open

maintainer timeout, > 4 weeks
Comment 4 John Marino freebsd_committer freebsd_triage 2013-07-21 20:47:55 UTC
Responsible Changed
From-To: freebsd-ports-bugs->marino

I'll take it.
Comment 5 dfilter service freebsd_committer freebsd_triage 2013-07-22 07:47:14 UTC
Author: marino
Date: Mon Jul 22 06:47:06 2013
New Revision: 323428
URL: http://svnweb.freebsd.org/changeset/ports/323428

Log:
  databases/tablelog: Restrict to postgresql 9.1 and earlier
  
  This version of Tablelog fails to build with postgresql 9.2
  
  PR:		ports/179955
  submitted by:	marino
  Approved by:	bapt (mentor), maintainer timeout

Modified:
  head/databases/tablelog/Makefile

Modified: head/databases/tablelog/Makefile
==============================================================================
--- head/databases/tablelog/Makefile	Mon Jul 22 06:44:10 2013	(r323427)
+++ head/databases/tablelog/Makefile	Mon Jul 22 06:47:06 2013	(r323428)
@@ -1,9 +1,5 @@
-# New ports collection makefile for:	tablelog
-# Date created:				11 July 2007
-# Whom:					Robert Gogolok <gogo@cs.uni-sb.de>
-#
+# Created by: Robert Gogolok <gogo@cs.uni-sb.de>
 # $FreeBSD$
-#
 
 PORTNAME=	tablelog
 PORTVERSION=	0.4.4
@@ -16,11 +12,9 @@ COMMENT=	Logs changes on a table in Post
 
 WRKSRC=		${WRKDIR}/table_log-${DISTVERSION}
 
-USE_GMAKE=	yes
+USES=		gmake
 USE_PGSQL=	yes
-
-IGNORE_WITH_PGSQL=	73
-
+WANT_PGSQL_VER=	91-
 MAKE_ARGS=	USE_PGXS=1
 
 PORTDOCS=	README.table_log table_log.sql
_______________________________________________
svn-ports-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-ports-all
To unsubscribe, send any mail to "svn-ports-all-unsubscribe@freebsd.org"
Comment 6 John Marino freebsd_committer freebsd_triage 2013-07-22 07:58:48 UTC
State Changed
From-To: open->closed

Committed, with minor changes. Thanks!
Comment 7 ken.tanzer 2014-01-22 03:08:51 UTC
FWIW, here's a couple of pieces of related information:

1)  I was able to build table_log for Centos and PG 9.2, so I'm not sure
it's exactly 9.2-specific

2)  Trying to do the same with 9.3, I got the same error messages as listed
in this bug.  With help from the Postgres mailing list (*), I was able to
fix this by adding these two lines to table_log.c:

#include <utils/rel.h>
#include <utils/timestamp.h>

Cheers,
Ken


(*)
http://www.postgresql.org/message-id/CAD3a31VzxnfwxiQ4MfTLvX2P+EFS+opDggNeHO+JkGOaM3XN7w@mail.gmail.com
)

-- 
AGENCY Software
A data system that puts you in control
100% Free Software
*http://agency-software.org/ <http://agency-software.org/>*
ken.tanzer@agency-software.org
(253) 245-3801

Subscribe to the mailing
list<agency-general-request@lists.sourceforge.net?body=subscribe>
 to
learn more about AGENCY or
follow the discussion.
Comment 8 John Marino freebsd_committer freebsd_triage 2014-01-22 07:42:10 UTC
State Changed
From-To: closed->open

3rd party additional fix offered
Comment 9 dfilter service freebsd_committer freebsd_triage 2014-01-22 11:20:25 UTC
Author: marino
Date: Wed Jan 22 11:20:17 2014
New Revision: 340704
URL: http://svnweb.freebsd.org/changeset/ports/340704
QAT: https://qat.redports.org/buildarchive/r340704/

Log:
  databases/tablelog: Fix pgsql 9.2+ and stage support
  
  PR: ports/179955

Added:
  head/databases/tablelog/files/
  head/databases/tablelog/files/patch-table__log.c   (contents, props changed)
Modified:
  head/databases/tablelog/Makefile
  head/databases/tablelog/pkg-plist

Modified: head/databases/tablelog/Makefile
==============================================================================
--- head/databases/tablelog/Makefile	Wed Jan 22 11:03:44 2014	(r340703)
+++ head/databases/tablelog/Makefile	Wed Jan 22 11:20:17 2014	(r340704)
@@ -14,21 +14,21 @@ WRKSRC=		${WRKDIR}/table_log-${DISTVERSI
 
 USES=		gmake
 USE_PGSQL=	yes
-WANT_PGSQL_VER=	91-
 MAKE_ARGS=	USE_PGXS=1
 
-PORTDOCS=	README.table_log table_log.sql
+.include <bsd.port.options.mk>
 
-NO_STAGE=	yes
 do-install:
-	@${MKDIR} ${PREFIX}/lib/postgresql/
-	@${INSTALL_PROGRAM} ${WRKSRC}/table_log.so ${PREFIX}/lib/postgresql/
-	@${MKDIR} ${PREFIX}/share/postgresql/contrib/
+	@${MKDIR} ${STAGEDIR}${PREFIX}/lib/postgresql/
+	@${INSTALL_PROGRAM} ${WRKSRC}/table_log.so \
+		${STAGEDIR}${PREFIX}/lib/postgresql/
+	@${MKDIR} ${STAGEDIR}${PREFIX}/share/postgresql/contrib/
 	@${INSTALL_DATA} ${WRKSRC}/table_log_init.sql \
-		${PREFIX}/share/postgresql/contrib/
-.if !defined(NOPORTDOCS)
-	@${MKDIR} ${DOCSDIR}/
-	cd ${WRKSRC} && ${INSTALL_DATA} ${PORTDOCS} ${DOCSDIR}/
+		${STAGEDIR}${PREFIX}/share/postgresql/contrib/
+.if ${PORT_OPTIONS:MDOCS}
+	@${MKDIR} ${STAGEDIR}${DOCSDIR}/
+	cd ${WRKSRC} && ${INSTALL_DATA} README.table_log table_log.sql \
+		${STAGEDIR}${DOCSDIR}/
 .endif
 
 .include <bsd.port.mk>

Added: head/databases/tablelog/files/patch-table__log.c
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/databases/tablelog/files/patch-table__log.c	Wed Jan 22 11:20:17 2014	(r340704)
@@ -0,0 +1,11 @@
+--- table_log.c.orig	2007-05-16 23:14:04.000000000 +0000
++++ table_log.c
+@@ -22,6 +22,8 @@
+ #include "utils/formatting.h"
+ #include "utils/builtins.h"
+ #include <utils/lsyscache.h>
++#include <utils/rel.h>
++#include <utils/timestamp.h>
+ #include <funcapi.h>
+ 
+ /* for PostgreSQL >= 8.2.x */

Modified: head/databases/tablelog/pkg-plist
==============================================================================
--- head/databases/tablelog/pkg-plist	Wed Jan 22 11:03:44 2014	(r340703)
+++ head/databases/tablelog/pkg-plist	Wed Jan 22 11:20:17 2014	(r340704)
@@ -1,5 +1,8 @@
 lib/postgresql/table_log.so
 share/postgresql/contrib/table_log_init.sql
+%%PORTDOCS%%%%DOCSDIR%%/README.table_log
+%%PORTDOCS%%%%DOCSDIR%%/table_log.sql
+%%PORTDOCS%%@dirrm %%DOCSDIR%%
 @dirrmtry lib/postgresql
 @dirrmtry share/postgresql/contrib
 @dirrmtry share/postgresql
_______________________________________________
svn-ports-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-ports-all
To unsubscribe, send any mail to "svn-ports-all-unsubscribe@freebsd.org"
Comment 10 John Marino freebsd_committer freebsd_triage 2014-01-22 13:10:51 UTC
State Changed
From-To: open->closed

Committed. Thanks!