source: trunk/dports/devel/libftd2xx/Portfile

Last change on this file was 131388, checked in by ryandesign@…, 3 years ago

libftd2xx: update to 1.2.2 and also install static library and cfg file (#46462, maintainer)

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 2.1 KB
Line 
1# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4
2# $Id: Portfile 131388 2015-01-10 18:33:45Z ryandesign@macports.org $
3
4PortSystem 1.0
5
6name                libftd2xx
7version             1.2.2
8categories          devel
9maintainers         gmail.com:ranauei
10description         FTDI D2XX Driver
11long_description    D2XX Driver: allow direct access to the USB device through \
12                    a DLL. Devices supported: FT2232H, FT4232H, FT232R, \
13                    FT245R, FT2232, FT232B, FT245B, FT8U232AM, FT8U245AM
14                 
15homepage            http://www.ftdichip.com/Drivers/D2XX.htm
16platforms           macosx
17distname            D2XX${version}
18master_sites        http://www.ftdichip.com/Drivers/D2XX/MacOSX/
19
20checksums           rmd160  d9fb6ceba3de5aaa87978e04bd6eb3b27ce8c2ef \
21                    sha256  7d6f39b4d092be2687321729e70ff8d08c20e288f7f036e1fdc19116c20a3250
22
23use_dmg             yes
24use_configure       no
25
26variant universal {}
27
28if { ${os.major}=="8" } {
29    set os_dir 10.4
30    set static_dir static32
31    supported_archs     i386 ppc
32    configure.universal_archs i386 ppc
33} elseif { ${os.major}>=9 } {
34    set os_dir 10.5-10.7
35    set static_dir static64
36    supported_archs     i386 ppc x86_64
37    configure.universal_archs i386 ppc x86_64
38}
39
40build {
41    if {![variant_isset universal]} {
42        system "cd '${worksrcpath}/D2XX/bin/${os_dir}' && lipo -extract ${configure.build_arch} ${name}.${version}.dylib -output ${name}.${version}.dylib"
43    }
44}
45
46destroot {
47   xinstall ${worksrcpath}/D2XX/bin/${os_dir}/${name}.${version}.dylib ${destroot}${prefix}/lib
48   xinstall ${worksrcpath}/D2XX/bin/${static_dir}/${name}.a ${destroot}${prefix}/lib
49   xinstall -m 644 ${worksrcpath}/D2XX/bin/ftd2xx.cfg ${destroot}${prefix}/lib
50   xinstall -m 644 -W ${worksrcpath}/D2XX/bin ftd2xx.h WinTypes.h ${destroot}${prefix}/include
51   ln -s ${name}.${version}.dylib ${destroot}${prefix}/lib/${name}.dylib
52   system "install_name_tool -id ${prefix}/lib/${name}.${version}.dylib ${destroot}${prefix}/lib/${name}.${version}.dylib"
53}
54
55livecheck.type      regex
56livecheck.regex     D2XX(\[0-9.\]+)${extract.suffix}
Note: See TracBrowser for help on using the repository browser.