| 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$ |
| 3 | |
| 4 | PortSystem 1.0 |
| 5 | PortGroup github 1.0 |
| 6 | |
| 7 | name opensc |
| 8 | github.setup OpenSC OpenSC 0.16.0 |
| 9 | categories security |
| 10 | platforms darwin |
| 11 | license LGPL-2.1 |
| 12 | maintainers schenkel.net:leonardo |
| 13 | |
| 14 | description Tools and libraries for smart cards |
| 15 | long_description OpenSC provides a set of libraries and utilities to \ |
| 16 | work with smart cards. Its main focus is on cards that \ |
| 17 | support cryptographic operations, and facilitate their \ |
| 18 | use in security applications such as authentication, \ |
| 19 | mail encryption and digital signatures. \ |
| 20 | OpenSC implements the PKCS#11 API so applications \ |
| 21 | supporting this API (such as Mozilla Firefox and \ |
| 22 | Thunderbird) can use it. \ |
| 23 | On the card OpenSC implements the PKCS#15 standard and \ |
| 24 | aims to be compatible with every software/card that \ |
| 25 | does so, too. |
| 26 | |
| 27 | github.tarball_from releases |
| 28 | checksums rmd160 f785df816560493baceb71e2197346c724fc0834 \ |
| 29 | sha256 3ac8c29542bb48179e7086d35a1b8907a4e86aca3de3323c2f48bd74eaaf5729 |
| 30 | |
| 31 | |
| 32 | depends_build port:docbook-xsl port:libxslt port:pkgconfig |
| 33 | depends_lib path:lib/libcrypto.dylib:openssl port:zlib |
| 34 | |
| 35 | default_variants +readline |
| 36 | |
| 37 | patchfiles-append patch-bash_completion.diff patch-libressl.diff |
| 38 | patch.pre_args -p1 |
| 39 | |
| 40 | use_autoreconf yes |
| 41 | configure.args-append --disable-doc |
| 42 | configure.args-append --disable-readline |
| 43 | configure.args-append --disable-static |
| 44 | configure.args-append --enable-pcsc |
| 45 | configure.args-append --enable-sm |
| 46 | configure.args-append --with-pkcs11-provider=${prefix}/lib/opensc-pkcs11.so |
| 47 | |
| 48 | variant doc description "Build documentation" { |
| 49 | configure.args-replace --disable-doc --enable-doc |
| 50 | } |
| 51 | variant readline description "Enable readline support" { |
| 52 | depends_lib-append port:readline |
| 53 | configure.args-replace --disable-readline --enable-readline |
| 54 | } |
| 55 | |
| 56 | pre-configure { |
| 57 | reinplace -W ${worksrcpath} \ |
| 58 | "s|No Git revision info available|OpenSC-${version} (MacPorts)|g" \ |
| 59 | configure.ac configure |
| 60 | } |
| 61 | post-destroot { |
| 62 | system "${worksrcpath}/MacOSX/libtool-bundle ${destroot}${prefix}/lib/opensc-pkcs11.so ${destroot}${prefix}/lib" |
| 63 | } |
| 64 | |