[119774] trunk/dports/kde/amarok

nicos at macports.org nicos at macports.org
Tue May 6 05:31:01 PDT 2014


Revision: 119774
          https://trac.macports.org/changeset/119774
Author:   nicos at macports.org
Date:     2014-05-06 05:31:01 -0700 (Tue, 06 May 2014)
Log Message:
-----------
amarok: adding proper detection of the sql variant

Modified Paths:
--------------
    trunk/dports/kde/amarok/Portfile

Added Paths:
-----------
    trunk/dports/kde/amarok/files/patch-FindMySQLAmarok.diff

Modified: trunk/dports/kde/amarok/Portfile
===================================================================
--- trunk/dports/kde/amarok/Portfile	2014-05-06 12:19:25 UTC (rev 119773)
+++ trunk/dports/kde/amarok/Portfile	2014-05-06 12:31:01 UTC (rev 119774)
@@ -7,7 +7,7 @@
 name                amarok
 conflicts           amarok-devel
 version             2.6.0
-revision            1
+revision            2
 categories          kde kde4
 maintainers         nomaintainer
 license             LGPL-2.1+ GPL-2+
@@ -31,16 +31,27 @@
                     port:loudmouth port:qca port:libmtp port:libgpod
 
 patchfiles          patch-src-app_mac.cpp.diff \
-                    patch-TrayIcon.diff
+                    patch-TrayIcon.diff \
+                    patch-FindMySQLAmarok.diff
 
 # prototype for 'Dynamic::BiasPtr Dynamic::AbstractBiasFactory::createFromXml(QCoreXmlStreamReader*)' does not match any in class 'Dynamic::AbstractBiasFactory'
 universal_variant   no
 
+pre-configure {
+    reinplace "s|@PREFIX@|${prefix}|g" \
+        ${worksrcpath}/cmake/modules/FindMySQLAmarok.cmake
+}
+
 variant mysql51 \
     conflicts mysql55 mysql56 mariadb55 percona55 \
     description {build with mysql51 port} {
 
     depends_lib-append      port:mysql51
+
+    pre-configure {
+        reinplace "s|@MYSQL@|mysql51|g" \
+            ${worksrcpath}/cmake/modules/FindMySQLAmarok.cmake
+    }
 }
 
 variant mysql55 \
@@ -48,6 +59,11 @@
     description {build with mysql55 port} {
 
     depends_lib-append      port:mysql55
+
+    pre-configure {
+        reinplace "s|@MYSQL@|mysql55|g" \
+            ${worksrcpath}/cmake/modules/FindMySQLAmarok.cmake
+    }
 }
 
 variant mysql56 \
@@ -55,6 +71,11 @@
     description {build with mysql56 port} {
 
     depends_lib-append      port:mysql56
+
+    pre-configure {
+        reinplace "s|@MYSQL@|mysql56|g" \
+            ${worksrcpath}/cmake/modules/FindMySQLAmarok.cmake
+    }
 }
 
 variant mariadb55 \
@@ -62,6 +83,11 @@
     description {build with mariadb port} {
 
     depends_lib-append      port:mariadb
+
+    pre-configure {
+        reinplace "s|@MYSQL@|mariadb|g" \
+            ${worksrcpath}/cmake/modules/FindMySQLAmarok.cmake
+    }
 }
 
 variant percona55 \
@@ -69,6 +95,11 @@
     description {build with percona55 port} {
 
     depends_lib-append      port:percona
+
+    pre-configure {
+        reinplace "s|@MYSQL@|percona|g" \
+            ${worksrcpath}/cmake/modules/FindMySQLAmarok.cmake
+    }
 }
 
 if {![variant_isset mysql51] && ![variant_isset mysql55] && ![variant_isset mysql56] \

Added: trunk/dports/kde/amarok/files/patch-FindMySQLAmarok.diff
===================================================================
--- trunk/dports/kde/amarok/files/patch-FindMySQLAmarok.diff	                        (rev 0)
+++ trunk/dports/kde/amarok/files/patch-FindMySQLAmarok.diff	2014-05-06 12:31:01 UTC (rev 119774)
@@ -0,0 +1,24 @@
+--- cmake/modules/FindMySQLAmarok.cmake.orig	2014-05-06 20:23:58.000000000 +0900
++++ cmake/modules/FindMySQLAmarok.cmake	2014-05-06 21:08:32.000000000 +0900
+@@ -13,19 +13,10 @@
+ # For details see the accompanying COPYING-CMAKE-SCRIPTS file.
+ 
+ if(NOT WIN32)
+-    find_program(MYSQLCONFIG_EXECUTABLE NAMES mysql_config mysql_config5 PATHS ${BIN_INSTALL_DIR} ~/usr/bin /usr/local/bin)
++    set(MYSQLCONFIG_EXECUTABLE @PREFIX@/lib/@MYSQL@/bin/mysql_config)
+ endif(NOT WIN32)
+ 
+-find_path(MYSQL_INCLUDE_DIR mysql.h
+-    /opt/local/include/mysql5/mysql
+-    /opt/mysql/mysql/include
+-    /opt/mysqle/include/mysql
+-    /opt/ports/include/mysql5/mysql
+-    /usr/include/mysql
+-    /usr/local/include/mysql
+-    /usr/mysql/include/mysql
+-    ~/usr/include/mysql
+-)
++set(MYSQL_INCLUDE_DIR @PREFIX@/include/@MYSQL@/mysql)
+ 
+ if(MYSQLCONFIG_EXECUTABLE)
+     exec_program(${MYSQLCONFIG_EXECUTABLE} ARGS --cflags RETURN_VALUE _return_VALUE OUTPUT_VARIABLE MYSQL_CFLAGS)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/macports-changes/attachments/20140506/1d2bffca/attachment.html>


More information about the macports-changes mailing list