Ticket #27093: libtommath-0.42.0.diff

File libtommath-0.42.0.diff, 2.3 KB (added by ryandesign (Ryan Carsten Schmidt), 13 years ago)

proposed patch

  • Portfile

     
    33PortSystem 1.0
    44
    55name                    libtommath
    6 version                 0.40
     6version                 0.42.0
    77categories              math
    88platforms               darwin
    99maintainers             mww
     10license                 Public-Domain
     11
    1012description             Comprehensive, modular and portable mathematical routines
    1113long_description        LibTomMath provides highly optimized and portable routines \
    1214                        for a vast majority of integer based number theoretic \
    1315                        applications (including public key cryptography).
    1416
    15 homepage                http://math.libtomcrypt.com/
    16 master_sites    http://libtom.org/files/ \
    17                                 http://www.atarininja.org/~wxs/distfiles/ \
     17homepage                http://www.libtom.org/?page=features&whatfile=ltm
     18master_sites    http://www.libtom.org/files/ \
    1819                                freebsd
    1920distname                ltm-${version}
    20 checksums               sha1 439899c06444c363eee527f75447d189ee4f93ba
     21
     22checksums               sha1    9b192701cf62b85e9bd65fbb4d622d04cfa5ee0d \
     23                                rmd160  9994d60d7e847a066715d8c644ce9b125932bf92
     24
    2125use_bzip2               yes
    2226patchfiles              patch-makefile
    2327
     
    2529
    2630use_configure   no
    2731
    28 build.args              LIBDIR=${prefix}/lib
     32variant universal {}
     33if {[variant_isset universal]} {
     34        set archflags ${configure.universal_cflags}
     35} else {
     36        set archflags ${configure.cc_archflags}
     37}
    2938
     39build.args              LIBDIR=${prefix}/lib \
     40                                CC="${configure.cc} ${archflags}"
     41
    3042destroot {
    3143        xinstall -m 755 -d ${destroot}${prefix}/include/${name}
    3244        xinstall -m 644 -W ${worksrcpath} tommath.h tommath_class.h \
    3345                tommath_superclass.h ${destroot}${prefix}/include/${name}
    3446        xinstall -m 644 -W ${worksrcpath} libtommath.a libtommath.${version}.dylib \
    3547                ${destroot}${prefix}/lib
    36         system "cd ${destroot}${prefix}/lib \
    37                 && ln -s libtommath.${version}.dylib libtommath.0.dylib \
    38                 && ln -s libtommath.${version}.dylib libtommath.dylib"
     48        ln -s libtommath.${version}.dylib ${destroot}${prefix}/lib/libtommath.0.dylib
     49        ln -s libtommath.${version}.dylib ${destroot}${prefix}/lib/libtommath.dylib
     50       
     51        set docdir ${destroot}${prefix}/share/doc/${name}
     52        xinstall -d ${docdir}
     53        xinstall -m 644 -W ${worksrcpath} \
     54                LICENSE \
     55                changes.txt \
     56                ${docdir}
    3957}
    4058
    41 platform darwin 8 {
    42         build.args-append       CC=/usr/bin/gcc-4.0
    43 }
    44 
     59livecheck.type  regex
     60livecheck.url   ${homepage}
     61livecheck.regex ltm-(\[0-9.\]+)${extract.suffix}