Ticket #26410: combined_patch-wxwidgets-devel.diff

File combined_patch-wxwidgets-devel.diff, 8.1 KB (added by anddam (Andrea D'Amore), 13 years ago)
  • files/patch-configure-change_install_names.diff

     
     1--- configure.orig      2011-01-13 02:34:25.000000000 -0800
     2+++ configure   2011-01-13 02:33:45.000000000 -0800
     3@@ -34968,16 +34968,18 @@
     4             DYLIB_RPATH_POSTLINK="${HOST_PREFIX}install_name_tool -id \$@ \$@"
     5             cat <<EOF >change-install-names
     6 #!/bin/sh
     7-libnames=\`cd \${1} ; ls -1 | grep '\.[0-9][0-9]*\.dylib\$'\`
     8-for i in \${libnames} ; do
     9-    ${HOST_PREFIX}install_name_tool -id \${1}/\${i} \${1}/\${i}
     10-    for dep in \${libnames} ; do
     11-        ${HOST_PREFIX}install_name_tool -change \${2}/\${dep} \${1}/\${dep} \${1}/\${i}
     12-    done
     13+libnames=\`find -E \$4  -type f -a -regex '.*\.[0-9]+\.dylib' -exec basename '{}' \;\`
     14+changes=''
     15+for dep in \$libnames; do
     16+    changes="\$changes -change \$4/\$dep \$3/\$dep"
     17 done
     18+for i in \$libnames; do
     19+    ${HOST_PREFIX}install_name_tool \$changes -id \$3/\$i \$1/\$i
     20+done
     21+${HOST_PREFIX}install_name_tool \$changes \$2/wxrc-2.9
     22 EOF
     23             chmod +x change-install-names
     24-            DYLIB_RPATH_INSTALL="\$(wx_top_builddir)/change-install-names \${libdir} \$(wx_top_builddir)/lib"
     25+            DYLIB_RPATH_INSTALL="\$(wx_top_builddir)/change-install-names \${DESTDIR}\${libdir} \${DESTDIR}\${bindir} \${libdir} \$(wx_top_builddir)/lib"
     26         fi
     27 
     28                                         HEADER_PAD_OPTION="-headerpad_max_install_names"
     29--- configure.in.orig   2011-01-13 02:34:15.000000000 -0800
     30+++ configure.in        2011-01-13 02:32:44.000000000 -0800
     31@@ -3989,16 +3989,18 @@
     32             DYLIB_RPATH_POSTLINK="${HOST_PREFIX}install_name_tool -id \$@ \$@"
     33             cat <<EOF >change-install-names
     34 #!/bin/sh
     35-libnames=\`cd \${1} ; ls -1 | grep '\.[[0-9]][[0-9]]*\.dylib\$'\`
     36-for i in \${libnames} ; do
     37-    ${HOST_PREFIX}install_name_tool -id \${1}/\${i} \${1}/\${i}
     38-    for dep in \${libnames} ; do
     39-        ${HOST_PREFIX}install_name_tool -change \${2}/\${dep} \${1}/\${dep} \${1}/\${i}
     40-    done
     41+libnames=\`find \$4  -type f -a -regex '.*\.[0-9]+\.dylib' -exec basename '{}' \;\`
     42+changes=''
     43+for dep in \$libnames; do
     44+    changes="\$changes -change \$4/\$dep \$3/\$dep"
     45 done
     46+for i in \$libnames; do
     47+    ${HOST_PREFIX}install_name_tool \$changes -id \$3/\$i \$1/\$i
     48+done
     49+${HOST_PREFIX}install_name_tool \$changes \$2/wxrc-2.9
     50 EOF
     51             chmod +x change-install-names
     52-            DYLIB_RPATH_INSTALL="\$(wx_top_builddir)/change-install-names \${libdir} \$(wx_top_builddir)/lib"
     53+            DYLIB_RPATH_INSTALL="\$(wx_top_builddir)/change-install-names \${DESTDIR}\${libdir} \${DESTDIR}\${bindir} \${libdir} \$(wx_top_builddir)/lib"
     54         fi
     55 
     56         dnl the HEADER_PAD_OPTION is required by some wx samples to avoid the error:
  • Portfile

     
    11# $Id$
    22
    33PortSystem 1.0
     4PortGroup               archcheck 1.0
    45
    56name                    wxWidgets-devel
     7conflicts               wxgtk wxWidgets
    68version                 2.9.1
    7 revision                1
     9revision        2
    810categories              graphics devel
    911platforms               darwin
    1012maintainers             jwa
     
    1820
    1921homepage                http://www.wxwidgets.org/
    2022distname                wxWidgets
    21 master_sites            http://biolpc22.york.ac.uk/pub/CVS_HEAD/v2/files/ \
    22     http://biolpc22.york.ac.uk/pub/${version}/ \
    23     ftp://ftp.wxwidgets.org/pub/${version}
     23master_sites    sourceforge:wxwindows \
     24                            http://biolpc22.york.ac.uk/pub/${version}/
     25
    2426use_bzip2               yes
    2527
    2628distfiles               ${distname}-${version}${extract.suffix}
    2729dist_subdir             ${distname}/${version}
     30checksums           md5     81c20d7b2ba31becb18e467dbe09be8f \
     31                    sha1    3ffe0614acce46448f5c14942176fb2daa6efd00 \
     32                    rmd160  106f5b0238e31e12bbede7f1c2cf0e0134076e29
     33                   
     34depends_lib             port:jpeg \
     35                            port:tiff \
     36                            port:libpng \
     37                            port:zlib \
     38                            port:libiconv \
     39                            port:expat \
     40                            path:lib/pkgconfig/sdl.pc:libsdl \
     41                            port:libsdl_mixer
    2842
    29 checksums               ${distname}-${version}${extract.suffix} \
    30     md5     81c20d7b2ba31becb18e467dbe09be8f \
    31     ${distname}-${version}${extract.suffix} \
    32     sha1    3ffe0614acce46448f5c14942176fb2daa6efd00 \
    33     ${distname}-${version}${extract.suffix} \
    34     rmd160  106f5b0238e31e12bbede7f1c2cf0e0134076e29
    3543
    36 depends_lib             port:jpeg \
    37     port:tiff \
    38     port:libpng \
    39     port:zlib \
    40     port:libiconv \
    41     port:expat \
    42     path:lib/pkgconfig/sdl.pc:libsdl \
    43     port:libsdl_mixer
     44archcheck.files lib/libjpeg.dylib \
     45                lib/libtiff.dylib \
     46                lib/libpng.dylib \
     47                lib/libz.dylib \
     48                lib/libiconv.dylib \
     49                lib/libexpat.dylib
    4450
    45 #set worksrcdir build
    46 set worksrcdir          ${distname}-${version}/build
     51set worksrcdir  ${distname}-${version}/build
    4752
    48 extract.only            ${distname}-${version}${extract.suffix}
     53extract.only    ${distname}-${version}${extract.suffix}
    4954
    50 set sub                 wx-devel
    51 configure.cmd           ../configure
     55patch.dir       ${worksrcpath}/..
     56patchfiles      patch-configure-change_install_names.diff
     57configure.cmd   ../configure
    5258configure.ldflags       -L${build.dir}/lib -L${prefix}/lib
    53 configure.args          --mandir=${prefix}/share/man \
    54     --libdir=${prefix}/lib/${sub} \
    55     --bindir=${prefix}/lib/${sub}/bin \
    56     --includedir=${prefix}/include/${sub} \
    57     --datadir=${prefix}/share/${sub} \
    58     --with-libiconv-prefix=${prefix} \
    59     --with-libjpeg \
    60     --with-libtiff \
    61     --with-libpng \
    62     --with-zlib \
    63     --with-sdl \
    64     --with-opengl \
    65     --with-mac \
    66     --disable-sdltest \
    67     --enable-unicode \
    68     --enable-display \
    69     --enable-monolithic \
    70     --with-macosx-version-min=${macosx_deployment_target}
    71 if {$build_arch == "x86_64" || $build_arch == "ppc64"} {
    72     # default carbon won't work on 64-bit
    73     configure.args-delete --with-mac
    74     configure.args-append --with-osx_cocoa
    75 #    patchfiles-append     patch-textctrl.diff
    76 }
     59configure.args  --mandir=${prefix}/share/man \
     60                            --with-libiconv-prefix=${prefix} \
     61                            --with-libjpeg \
     62                            --with-libtiff \
     63                            --with-libpng \
     64                            --with-zlib \
     65                            --with-opengl \
     66                            --with-cocoa \
     67                            --enable-unicode \
     68                            --enable-display \
     69                            --enable-monolithic
    7770
    78 set installtype         release
    79 #set contrib            "gizmos stc ogl"
    80 
    8171build.target
    8272
    83 #post-build {
    84 #    foreach c { ${contrib} } {
    85 #       system "cd ${build.dir} && make -C contrib/src/${c}"
    86 #    }
    87 #}
     73universal_variant       no
     74use_parallel_build      yes
    8875
     76supported_archs x86_64 ppc64 i386 ppc
     77configure.ccache = no
     78configure.cppflags-append -arch ${configure.build_arch}
     79
    8980post-destroot {
    90 #    foreach c { ${contrib} } {
    91 #       system "cd ${destroot.dir} && make -C contrib/src/${c} install ${destroot.destdir}"
    92 #    }
    93     xinstall -d -m 755 ${destroot}${prefix}/share/doc/${name}
    94 #    xinstall -m 644 -W ${workpath}/${distname}-${version} \
    95 #       install-mac.txt install-mgl.txt install-motif.txt \
    96 #       INSTALL-OS2.txt install-x11.txt readme-cocoa.txt \
    97 #       readme-gtk.txt readme-mac.txt \
    98 #       readme-mgl.txt readme-motif.txt readme-x11.txt \
    99 #       ${destroot}${prefix}/share/doc/${name}
    100 #    if {$build_arch == "x86_64" || $build_arch == "ppc64"} {
    101 #        reinplace "s|-L${build.dir}/lib||" ${destroot}${prefix}/lib/${sub}/wx/config/osx_cocoa-unicode-${installtype}-2.9
    102 #    } else {
    103 #        reinplace "s|-L${build.dir}/lib||" ${destroot}${prefix}/lib/${sub}/wx/config/osx_carbon-unicode-${installtype}-2.9
    104 #    }
     81    set confscript ${prefix}/lib/wx/config/osx_cocoa-unicode-2.9
     82    ln -sf ${confscript} ${destroot}${prefix}/bin/wx-config
    10583}
    10684
    10785variant nonmonolithic description {build libraries separately} {
     
    11088
    11189variant debug description {add debug info to libraries} {
    11290    configure.args-append       --enable-debug
    113     set installtype debug
    11491}
    11592
    11693livecheck.type          regex
    117 livecheck.url           http://biolpc22.york.ac.uk/pub/
    118 livecheck.regex         (2.\[0-9\]+.\[0-9a-z.-\]+)/
     94livecheck.url           ${homepage}/downloads/
     95livecheck.regex         Current Stable Release.*(2\\.\[0-9\]\\.\[0-9\]+)