Ticket #33670: Portfile-liboil.diff

File Portfile-liboil.diff, 3.0 KB (added by ajdudman, 12 years ago)
  • Portfile

    old new  
    11# $Id: Portfile 85757 2011-10-16 05:01:19Z dports@macports.org $
    22
    33PortSystem 1.0
    4 
    5 # -universal because of SnowLeopard host_cpu issue (see below)
    6 #PortGroup  muniversal 1.0
    7 universal_variant no
     4PortGroup               muniversal 1.0
    85
    96name            liboil
    107version         0.3.17
     8revision                1
    119description     A library of simple functions that are optimized for various CPUs.
    1210long_description        ${description}
    1311maintainers     landonf
    1412categories      devel
    1513license         BSD
    1614platforms       darwin
    17 homepage        http://liboil.freedesktop.org/
     15homepage                http://www.freedesktop.org/wiki/
    1816master_sites    http://liboil.freedesktop.org/download/
     17
    1918checksums           md5     47dc734f82faeb2964d97771cfd2e701 \
    2019                    sha1    f9d7103a3a4a4089f56197f81871ae9129d229ed \
    2120                    rmd160  de286350687a5d49868b0a45d4db007526220fec
    2221
    23 patchfiles      patch-liboil_liboilcpu-x86.c.diff
     22patchfiles              patch-configure.ac.diff patch-liboil_liboilcpu-x86.c.diff
    2423
    25 depends_build   port:pkgconfig
     24depends_build           port:pkgconfig path:share/automake-1.11/config.guess:automake
    2625depends_lib     path:lib/pkgconfig/glib-2.0.pc:glib2
    2726
     27# Must update the old "./config.guess"
     28use_autoreconf          yes
     29autoreconf.args         -fvi
     30
     31# Have icky inline asm; clang doesn't want to touch it, but we can force it.
     32if {${configure.compiler} == "clang"} {
     33        configure.cflags-append -fheinous-gnu-extensions
     34}
     35
     36# With muniversal configure needs help with AS_HOST_DEFINES in m4/as-host-defines.m4.
     37platform darwin {
     38        lappend merger_configure_args(i386)  --host=i686-apple-${os.platform}${os.version}
     39}
     40
    2841variant doc description {Install documentation} {
    2942    depends_build-append   port:gtk-doc
    3043    configure.args-append  --enable-gtk-doc
    3144}
    3245
    33 # Building muniversal, configure fails to figure this out
    34 #configure.cppflags-append -DHAVE_SYMBOL_UNDERSCORE
    35 
    36 #post-configure {
    37 #       # muniversal mucks up our glibtool
    38 #       foreach arch ${universal_archs_to_use} {
    39 #               copy -force ${prefix}/bin/glibtool ${worksrcpath}-${arch}/libtool
    40 #       }
    41 #}
     46test.run                yes
     47test.target             check
    4248
    4349livecheck.type          regex
    44 livecheck.url           [lindex ${master_sites} 0]?C=M&O=D
    45 livecheck.regex         ${name}-(\\d(?:\\.\\d+)*)
    46 
    47 platform darwin 10 {
    48         # NB: won't work for universal building, but this port doesn't support it yet
    49         patchfiles-append host_cpu.diff
    50         post-patch {
    51                 reinplace "s|__HOST_CPU__|${build_arch}|" ${worksrcpath}/configure
    52         }
    53 }
    54 
    55 platform darwin 11 {
    56         # NB: won't work for universal building, but this port doesn't support it yet
    57         patchfiles-append host_cpu.diff
    58         post-patch {
    59                 reinplace "s|__HOST_CPU__|${build_arch}|" ${worksrcpath}/configure
    60         }
    61 }
    62 
    63 # icky inline asm... clang doesn't want to touch it, but we can force it
    64 if {${configure.compiler} == "clang"} {
    65         configure.cflags-append -fheinous-gnu-extensions
    66 }
     50livecheck.url           [lindex ${master_sites} 0]
     51livecheck.regex         ${name}-(\[-0-9._\]+)${extract.suffix}