Ticket #45377: patch-lensfun-0.3.0-revised.diff
File patch-lensfun-0.3.0-revised.diff, 7.1 KB (added by dbevans (David B. Evans), 10 years ago) |
---|
-
Portfile
2 2 # $Id$ 3 3 4 4 PortSystem 1.0 5 PortGroup muniversal1.05 PortGroup cmake 1.0 6 6 7 7 name lensfun 8 8 epoch 1 9 version 0.2.8 10 revision 1 9 version 0.3.0 11 10 categories graphics 12 11 platforms darwin 13 12 maintainers devans openmaintainer 14 license GPL-3 LGPL-3 13 license GPL-3 LGPL-3 CC-BY-SA 15 14 16 15 description Library for fixing lens geometry distortion 17 16 … … 24 23 master_sites sourceforge:project/${name}/${version} 25 24 use_bzip2 yes 26 25 27 checksums rmd160 527b4ca0e9ce40f514e7340548d0d0635bdc875e\28 sha256 f88f97fbc78259a2b2edddef295caf50770901107c8469e54bb5e9699faa1a4826 checksums rmd160 dc39f4708b2632ed6795052d368f3ad847c6704f \ 27 sha256 c2c3c03873cb549d49d42f118fcb0ffa95d1e45b9ff395e19facb63bf699bec1 29 28 30 depends_build port:pkgconfig bin:makedep:gccmakedep 29 depends_build-append \ 30 port:pkgconfig 31 31 32 depends_lib path:lib/pkgconfig/glib-2.0.pc:glib2 32 depends_lib path:lib/pkgconfig/glib-2.0.pc:glib2 \ 33 port:libpng 33 34 34 # Ensure lensfun.pc is created 35 patchfiles patch-pkgconfig.diff 35 # installs python3 helper scripts lensfun-add-adapter lensfun-update-data 36 36 37 # Set the correct library install_name and current_version 38 patchfiles-append patch-build-tibs-target-mac-mak.diff 39 post-patch { 40 reinplace "s|@VERSION@|${version}|g" ${worksrcpath}/build/tibs/target/mac.mak 41 } 37 depends_run port:python34 42 38 43 set cxx_stdlibflags {} 44 if {[string match *clang* ${configure.cxx}]} { 45 set cxx_stdlibflags -stdlib=${configure.cxx_stdlib} 39 pre-patch { 40 copy ${worksrcpath}/docs/CMakeLists.txt ${worksrcpath}/docs/CMakeLists.txt.orig 46 41 } 47 42 48 configure.args -v 49 configure.env LD="${configure.cxx} ${cxx_stdlibflags}" 43 patchfiles patch-docs-CMakeLists.txt.diff 50 44 51 platform darwin 8 { 52 # lensfun requires make >= 3.81; Tiger comes with 3.80 53 depends_build-append port:gmake 54 # fix configure script check which is hardcoded to using "make" 55 post-extract { 56 xinstall -d ${workpath}/bin 57 ln -s ${prefix}/bin/gmake ${workpath}/bin/make 58 } 59 configure.env PATH=${workpath}/bin:$env(PATH) 60 # fix build and destroot 61 build.cmd ${prefix}/bin/gmake 45 post-patch { 46 reinplace "s|^#!.*|#!${prefix}/bin/python3.4|" \ 47 ${worksrcpath}/apps/lensfun-add-adapter \ 48 ${worksrcpath}/apps/lensfun-update-data 62 49 } 63 50 64 if {[variant_isset universal]} { 65 foreach arch ${configure.universal_archs} { 66 set merger_host($arch) "" 67 } 68 set merger_configure_args(ppc64) "--target=mac.powerpc64.G5 --vectorization=''" 69 set merger_configure_args(ppc) "--target=mac.powerpc.powerpc --vectorization=''" 70 set merger_configure_args(i386) "--target=mac.x86.i686" 71 set merger_configure_args(x86_64) "--target=mac.x86_64.generic" 72 } elseif {${build_arch} eq "ppc64"} { 73 configure.args-append --target=mac.powerpc64.G5 --vectorization='' 74 } elseif {${build_arch} eq "ppc"} { 75 configure.args-append --target=mac.powerpc.powerpc --vectorization='' 76 } elseif {${build_arch} eq "i386"} { 77 configure.args-append --target=mac.x86.i686 78 } elseif {${build_arch} eq "x86_64"} { 79 configure.args-append --target=mac.x86_64.generic 51 variant doc description {Build API and man documentation using doxygen, rst2man} { 52 depends_build-append \ 53 port:doxygen \ 54 port:py34-docutils 55 56 configure.args-append \ 57 -DBUILD_DOC=ON 80 58 } 81 59 82 configure.universal_args-delete --disable-dependency-tracking83 84 build.args V=1 GCC.LD="${configure.cxx} ${cxx_stdlibflags}"85 86 60 livecheck.regex "${name}-(\\d+(?:\\.\\d+)*)${extract.suffix}" -
files/patch-build-tibs-target-mac-mak.diff
1 --- build/tibs/target/mac.mak.orig 2011-01-17 20:34:03.000000000 +13002 +++ build/tibs/target/mac.mak 2011-01-17 20:35:12.000000000 +13003 @@ -12,6 +12,6 @@4 _EX =5 6 # Flag to tell Darwin linker to set the library name:7 -GCC.LDFLAGS.SHARED = -dynamiclib -Wl,"-dylib_install_name,$1"8 +GCC.LDFLAGS.SHARED = -dynamiclib -Wl,"-install_name,$(CONF_LIBDIR)$1" -Wl,"-current_version,@VERSION@"9 # Set to non-empty if platform supports versioned shared libraries10 SO.VERSION = 1 -
files/patch-docs-CMakeLists.txt.diff
1 --- docs/CMakeLists.txt.orig 2014-09-30 10:37:34.000000000 -0700 2 +++ docs/CMakeLists.txt 2015-03-06 08:19:31.000000000 -0800 3 @@ -26,9 +26,9 @@ 4 ADD_CUSTOM_TARGET(man ALL) 5 ADD_CUSTOM_COMMAND( 6 TARGET man 7 - COMMAND rst2man ${CMAKE_CURRENT_SOURCE_DIR}/man/g-lensfun-update-data.1.rst > ${CMAKE_CURRENT_BINARY_DIR}/g-lensfun-update-data.1 8 - COMMAND rst2man ${CMAKE_CURRENT_SOURCE_DIR}/man/lensfun-update-data.1.rst > ${CMAKE_CURRENT_BINARY_DIR}/lensfun-update-data.1 9 - COMMAND rst2man ${CMAKE_CURRENT_SOURCE_DIR}/man/lensfun-add-adapter.1.rst > ${CMAKE_CURRENT_BINARY_DIR}/lensfun-add-adapter.1 10 + COMMAND rst2man-3.4.py ${CMAKE_CURRENT_SOURCE_DIR}/man/g-lensfun-update-data.1.rst > ${CMAKE_CURRENT_BINARY_DIR}/g-lensfun-update-data.1 11 + COMMAND rst2man-3.4.py ${CMAKE_CURRENT_SOURCE_DIR}/man/lensfun-update-data.1.rst > ${CMAKE_CURRENT_BINARY_DIR}/lensfun-update-data.1 12 + COMMAND rst2man-3.4.py ${CMAKE_CURRENT_SOURCE_DIR}/man/lensfun-add-adapter.1.rst > ${CMAKE_CURRENT_BINARY_DIR}/lensfun-add-adapter.1 13 WORKING_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}" 14 ) 15 16 @@ -36,5 +36,5 @@ 17 ${CMAKE_CURRENT_BINARY_DIR}/g-lensfun-update-data.1 18 ${CMAKE_CURRENT_BINARY_DIR}/lensfun-update-data.1 19 ${CMAKE_CURRENT_BINARY_DIR}/lensfun-add-adapter.1 20 - DESTINATION ${CMAKE_INSTALL_PREFIX}/man/man1 21 + DESTINATION ${CMAKE_INSTALL_PREFIX}/share/man/man1 22 ) -
files/patch-pkgconfig.diff
1 --- build/tibs/compiler/pkgconfig.mak.orig 2010-03-23 09:32:47.000000000 +13002 +++ build/tibs/compiler/pkgconfig.mak 2011-01-16 13:37:03.000000000 +13003 @@ -3,8 +3,9 @@4 ifdef CONF_LIBDIR5 # Try to guess here if target supports pkgconfig6 # - Any POSIX platform7 +# - Macintosh8 # - Cross-compiling on a POSIX target for WINDOWS (mingw32)9 -ifneq ($(findstring /posix/,/$(TARGET)/)$(findstring /posix-windows/,/$(HOST)-$(TARGET)/),)10 +ifneq ($(findstring /posix/,/$(TARGET)/)$(findstring /mac/,/$(TARGET)/)$(findstring /posix-windows/,/$(HOST)-$(TARGET)/),)11 12 XFNAME.PKGCONFIG = $(addprefix $$(OUT),$1)13 MKDEPS.PKGCONFIG = $1