Date: Sat, 14 Nov 2015 21:58:33 +0100 From: Patrick Hess <patrickhess@gmx.net> To: freebsd-ports@freebsd.org Subject: How to best handle GCC plugins in pkg-plist? Message-ID: <25463892.IZhL4yp0Ht@desk8.phess.net>
next in thread | raw e-mail | index | archive | help
Hi there! The other day I came across an interesting-looking ORM framework, http://www.codesynthesis.com/products/odb/. My first tests were quite promising, and before going any further, I thought it might be useful to have a port for this. Didn't run into much trouble during the process, except for when I reviewed the plists and stumbled across this funny line: lib/gcc5/gcc/amd64-portbld-freebsd10.1/5.1.0/plugin/odb.so Now, I can use %%TARGETARCH%% and %%OSREL%% to get rid of the hard-coded platform and OS version strings, but how about the GCC version number? I skimmed through the Makefiles in /usr/ports/Mk but couldn't really figure out what to do here. So what would be the best way to go about this? If at all possible, I'd prefer not to require a specific version of GCC (other than USE_GCC=5.0+) and hard code that version number in the plist. Patrick PS: Below are the Makefiles for the 4 components that are required as an absolute minimum to get started with ODB, just in case someone might be interested. /usr/ports/databases/odb/Makefile: _______________________________________________________________________ # $FreeBSD$ PORTNAME= odb PORTVERSION= 2.4.0 CATEGORIES= databases MASTER_SITES= http://www.codesynthesis.com/download/odb/${PORTVERSION:C/^([0-9]+\.[0-9]+).*/\1/}/ MAINTAINER= patrickhess@gmx.net COMMENT= ODB: C++ Object-Relational Mapping -- Compiler LICENSE= GPLv3 LIB_DEPENDS= libcutl.so:${PORTSDIR}/devel/libcutl USE_GCC= 5.0+ GNU_CONFIGURE= yes USES= libtool USE_LDCONFIG= yes INSTALL_TARGET= install-strip .include <bsd.port.mk> _______________________________________________________________________ /usr/ports/databases/libodb/Makefile: _______________________________________________________________________ # $FreeBSD$ PORTNAME= libodb PORTVERSION= 2.4.0 CATEGORIES= databases MASTER_SITES= http://www.codesynthesis.com/download/odb/${PORTVERSION:C/^([0-9]+\.[0-9]+).*/\1/}/ MAINTAINER= patrickhess@gmx.net COMMENT= ODB: C++ Object-Relational Mapping -- Common Runtime Library LICENSE= GPLv2 GNU_CONFIGURE= yes USES= libtool USE_LDCONFIG= yes INSTALL_TARGET= install-strip .include <bsd.port.mk> _______________________________________________________________________ /usr/ports/databases/libodb-sqlite/Makefile: _______________________________________________________________________ # $FreeBSD$ PORTNAME= libodb-sqlite PORTVERSION= 2.4.0 CATEGORIES= databases MASTER_SITES= http://www.codesynthesis.com/download/odb/${PORTVERSION:C/^([0-9]+\.[0-9]+).*/\1/}/ MAINTAINER= patrickhess@gmx.net COMMENT= ODB: C++ Object-Relational Mapping -- SQLite Runtime Library LICENSE= GPLv2 LIB_DEPENDS= libodb.so:${PORTSDIR}/databases/libodb \ libsqlite3.so:${PORTSDIR}/databases/sqlite3 GNU_CONFIGURE= yes USES= libtool USE_LDCONFIG= yes INSTALL_TARGET= install-strip # Required for the configure script to find SQLite: CXXFLAGS+= -I/usr/local/include LDFLAGS+= -L/usr/local/lib .include <bsd.port.mk> _______________________________________________________________________ /usr/ports/devel/libcutl/Makefile: _______________________________________________________________________ # $FreeBSD$ PORTNAME= libcutl PORTVERSION= 1.9.0 CATEGORIES= devel MASTER_SITES= http://www.codesynthesis.com/download/libcutl/${PORTVERSION:C/^([0-9]+\.[0-9]+).*/\1/}/ MAINTAINER= patrickhess@gmx.net COMMENT= C++ utility library for use with databases/odb LICENSE= MIT USE_GCC= 5.0+ GNU_CONFIGURE= yes USES= libtool USE_LDCONFIG= yes INSTALL_TARGET= install-strip .include <bsd.port.mk> _______________________________________________________________________
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?25463892.IZhL4yp0Ht>