ports/81950: ruby-mysql Makefile broken for mysql dependency
Phil Pennock
pdp at nl.demon.net
Mon Jun 6 11:50:02 UTC 2005
>Number: 81950
>Category: ports
>Synopsis: ruby-mysql Makefile broken for mysql dependency
>Confidential: no
>Severity: non-critical
>Priority: medium
>Responsible: freebsd-ports-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: sw-bug
>Submitter-Id: current-users
>Arrival-Date: Mon Jun 06 11:50:01 GMT 2005
>Closed-Date:
>Last-Modified:
>Originator: Phil Pennock
>Release: FreeBSD 5.4-RELEASE-p1 i386
>Organization:
Thus Plc, Demon Netherlands
>Environment:
System: FreeBSD algemeen-01.server.nl.demon.net 5.4-RELEASE-p1 FreeBSD 5.4-RELEASE-p1 #0: Fri Jun 3 11:47:14 UTC 2005 root at xxxx.xxxx.xxx:/usr/src/sys/i386/compile/XXXXXXX i386
>Description:
The Port databases/ruby-mysql has a Makefile which attempts to depend
upon the correct version of mysqlclient, depending upon which version
exists in the file-system. It doesn't work, because it uses
${LOCALBASE} but only has a .include for bsd.port.mk at the end, so
${LOCALBASE} isn't defined at the point in parsing where it's required.
>How-To-Repeat:
install mysql41-client
attempt to install ruby-mysql
watch as system attempts to install mysql-4.0.x.
>Fix:
Patch against: ports/databases/ruby-mysql/Makefile,v 1.22
This patch moves to using bsd.port.pre.mk and bsd.port.post.mk; it
collapses a nested .else/.if into an .elif; it moves the USE_RUBY*
variables up, so that they're defined before bsd.port.pre.mk inclusion
so that the correct build methods are defined.
--- Makefile.old Mon Jan 31 17:10:40 2005
+++ Makefile Mon Jun 6 11:40:31 2005
@@ -16,18 +16,18 @@
MAINTAINER= knu at FreeBSD.org
COMMENT= Ruby module for accessing MySQL databases with a C API like interface
+USE_RUBY= yes
+USE_RUBY_EXTCONF= yes
+
+.include <bsd.port.pre.mk>
+
.if exists(${LOCALBASE}/lib/mysql/libmysqlclient.so.10)
LIB_DEPENDS= mysqlclient.10:${PORTSDIR}/databases/mysql323-client
-.else
-.if exists(${LOCALBASE}/lib/mysql/libmysqlclient.so.14)
+.elif exists(${LOCALBASE}/lib/mysql/libmysqlclient.so.14)
LIB_DEPENDS= mysqlclient.14:${PORTSDIR}/databases/mysql41-client
.else
LIB_DEPENDS= mysqlclient.12:${PORTSDIR}/databases/mysql40-client
.endif
-.endif
-
-USE_RUBY= yes
-USE_RUBY_EXTCONF= yes
CONFIGURE_ARGS= --with-mysql-dir="${LOCALBASE}"
INSTALL_TARGET= site-install
@@ -41,4 +41,4 @@
${LN} -fs ../tommy.css ${RUBY_MODDOCDIR}/ja/
.endif
-.include <bsd.port.mk>
+.include <bsd.port.post.mk>
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-ports-bugs
mailing list