[141129] trunk/dports/science/gr-fosphor

michaelld at macports.org michaelld at macports.org
Sun Oct 11 08:15:07 PDT 2015


Revision: 141129
          https://trac.macports.org/changeset/141129
Author:   michaelld at macports.org
Date:     2015-10-11 08:15:07 -0700 (Sun, 11 Oct 2015)
Log Message:
-----------
gr-fosphor: add a patch to fix finding Freetype2 headers, for those having issues (e.g., in 10.11).

Modified Paths:
--------------
    trunk/dports/science/gr-fosphor/Portfile

Added Paths:
-----------
    trunk/dports/science/gr-fosphor/files/
    trunk/dports/science/gr-fosphor/files/patch-cmake_Modules_FindFreetype2.cmake.diff

Modified: trunk/dports/science/gr-fosphor/Portfile
===================================================================
--- trunk/dports/science/gr-fosphor/Portfile	2015-10-11 14:57:58 UTC (rev 141128)
+++ trunk/dports/science/gr-fosphor/Portfile	2015-10-11 15:15:07 UTC (rev 141129)
@@ -46,6 +46,10 @@
 
 cmake.out_of_source yes
 
+# temporary patch to fix finding Freetype2 headers
+
+patchfiles-append patch-cmake_Modules_FindFreetype2.cmake.diff
+
 # remove top-level library path, such that internal libraries are used
 # instead of any already-installed ones.
 

Added: trunk/dports/science/gr-fosphor/files/patch-cmake_Modules_FindFreetype2.cmake.diff
===================================================================
--- trunk/dports/science/gr-fosphor/files/patch-cmake_Modules_FindFreetype2.cmake.diff	                        (rev 0)
+++ trunk/dports/science/gr-fosphor/files/patch-cmake_Modules_FindFreetype2.cmake.diff	2015-10-11 15:15:07 UTC (rev 141129)
@@ -0,0 +1,64 @@
+--- cmake/Modules/FindFreetype2.cmake.orig	2015-10-11 11:10:32.000000000 -0400
++++ cmake/Modules/FindFreetype2.cmake	2015-10-11 11:10:34.000000000 -0400
+@@ -23,47 +23,18 @@
+ 
+   if(FREETYPE2_INCLUDE_DIR_ft2build)
+ 
+-    # Freetype changed header locations between API release 16 and 17;
+-    # look for config/ftheader.h depending on the API release number.
+-
+-    if(NOT FREETYPE2_PKG_VERSION)
+-
+-      # PKGCONFIG failed to find a package, but ft2build.h was
+-      # located.  Guess API release version based on trailing
+-      # directory of ft2build.h location.
+-
+-      STRING(REGEX MATCH "[^/]*$" FREETYPE2_ft2build_DIR ${FREETYPE2_INCLUDE_DIR_ft2build})
+-      message("FREETYPE2_ft2build_DIR is '${FREETYPE2_ft2build_DIR}'")
+-      STRING(COMPARE NOTEQUAL ${FREETYPE2_ft2build_DIR} "freetype2" FREETYPE_IS_2_4_OR_EARLIER)
+-
+-    else(NOT FREETYPE2_PKG_VERSION)
+-
+-      # PKGCONFIG provides version information; use that
+-
+-      STRING(REGEX MATCH "[^.]*" FREETYPE2_RELEASE ${FREETYPE2_PKG_VERSION})
+-      STRING(COMPARE LESS ${FREETYPE2_RELEASE} 17 FREETYPE_IS_2_4_OR_EARLIER)
+-
+-    endif(NOT FREETYPE2_PKG_VERSION)
+-
+-    if(FREETYPE_IS_2_4_OR_EARLIER)
+-      # freetype 2.4 or earlier
+-      set(FTHEADER_NAME freetype/config/ftheader.h)
+-    else(FREETYPE_IS_2_4_OR_EARLIER)
+-      # freetype 2.5 or later
+-      set(FTHEADER_NAME config/ftheader.h)
+-    endif(FREETYPE_IS_2_4_OR_EARLIER)
++    # find config/ftheader.h; this could be in the top-level freetype2
++    # include directory or in the freetype subdirectory, depending on
++    # the version of freetype2.
+ 
+     find_path(FREETYPE2_INCLUDE_DIR_ftheader
+       NAMES
+-      ${FTHEADER_NAME}
++      config/ftheader.h
+       HINTS
+-      ${FREETYPE2_PKG_INCLUDE_DIRS}
+       ${FREETYPE2_INCLUDE_DIR_ft2build}
+       ENV FREETYPE2_DIR
+       PATH_SUFFIXES
+-      freetype2
+-      include/freetype2
+-      include
++      freetype
+       NO_DEFAULT_PATH
+     )
+ 
+@@ -93,7 +64,7 @@
+       if(FREETYPE2_LIBRARIES)
+         set(FREETYPE2_FOUND TRUE CACHE INTERNAL "freetype2 found")
+         message(STATUS "Found freetype2: ${FREETYPE2_INCLUDE_DIRS}, ${FREETYPE2_LIBRARIES}")
+-      else(FREETYPE2_INCLUDE_DIRS AND FREETYPE2_LIBRARIES)
++      else()
+         set(FREETYPE2_FOUND FALSE CACHE INTERNAL "freetype2 found")
+         message(STATUS "freetype2 not found.")
+       endif(FREETYPE2_LIBRARIES)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/macports-changes/attachments/20151011/669dc5bf/attachment.html>


More information about the macports-changes mailing list