From owner-freebsd-ports-bugs@FreeBSD.ORG Wed Dec 10 17:01:23 2014 Return-Path: Delivered-To: freebsd-ports-bugs@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id EF80FB24 for ; Wed, 10 Dec 2014 17:01:23 +0000 (UTC) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2001:1900:2254:206a::16:76]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id BEFD3E80 for ; Wed, 10 Dec 2014 17:01:23 +0000 (UTC) Received: from bugs.freebsd.org ([127.0.1.118]) by kenobi.freebsd.org (8.14.9/8.14.9) with ESMTP id sBAH1Np0015213 for ; Wed, 10 Dec 2014 17:01:23 GMT (envelope-from bugzilla-noreply@freebsd.org) From: bugzilla-noreply@freebsd.org To: freebsd-ports-bugs@FreeBSD.org Subject: [Bug 195856] New: bsd.database.mk DEFAULT_MYSQL_VER being clobbered... Date: Wed, 10 Dec 2014 17:01:23 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Ports Tree X-Bugzilla-Component: Infrastructure X-Bugzilla-Version: Latest X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Some People X-Bugzilla-Who: sean@chittenden.org X-Bugzilla-Status: New X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: freebsd-ports-bugs@FreeBSD.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version rep_platform op_sys bug_status bug_severity priority component assigned_to reporter attachments.created Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 10 Dec 2014 17:01:24 -0000 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=195856 Bug ID: 195856 Summary: bsd.database.mk DEFAULT_MYSQL_VER being clobbered... Product: Ports Tree Version: Latest Hardware: Any OS: Any Status: New Severity: Affects Some People Priority: --- Component: Infrastructure Assignee: freebsd-ports-bugs@FreeBSD.org Reporter: sean@chittenden.org Created attachment 150434 --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=150434&action=edit bsd.database.mk patch against r374417 When building ports via poudriere, it's possible to specify default versions of MySQL (or PostgreSQL), however when including default values, we see runtime dependencies still linking against the system default. For example, if we specify 5.6, we have a runtime dependency on MySQL 5.5. DEFAULT_VERSIONS= pgsql=9.4 mysql=56p This happens because _MYSQL_VER is overridden unconditionally based on the version information found in `${LOCALBASE}/bin/mysql --version`. Because we run with an internally modified version of MySQL, we have two options: 1) Patch the MySQL version string 2) Teach ports to honor the default version when specified We think option #2 is the more correct approach. The attached patch fixes our package environment so that runtime dependencies are correct. ``` Index: Mk/bsd.database.mk =================================================================== --- Mk/bsd.database.mk (revision 374417) +++ Mk/bsd.database.mk (working copy) @@ -116,6 +116,7 @@ MYSQL100m_LIBVER= 18 # Setting/finding MySQL version we want. +.if !defined(DEFAULT_MYSQL_VER) .if exists(${LOCALBASE}/bin/mysql) _MYSQL!= ${LOCALBASE}/bin/mysql --version | ${SED} -e 's/.*Distrib \([0-9]\{1,2\}\)\.\([0-9]*\).*/\1\2/' _PERCONA!= ${LOCALBASE}/bin/mysql --version | ${GREP} Percona | wc -l @@ -129,6 +130,7 @@ _MYSQL_VER= ${_MYSQL} .endif .endif +.endif .if defined(WANT_MYSQL_VER) .if defined(WITH_MYSQL_VER) && ${WITH_MYSQL_VER} != ${WANT_MYSQL_VER} ``` -- You are receiving this mail because: You are the assignee for the bug.