Ticket #49324: ghostscript.diff

File ghostscript.diff, 5.9 KB (added by neverpanic (Clemens Lang), 9 years ago)

Patch updating ghostscript to 9.19 and fixing a couple of bugs in the Portfile

  • print/ghostscript/Portfile

     
    55PortGroup           muniversal 1.0
    66
    77name                ghostscript
    8 version             9.16
    9 revision            1
     8version             9.19
    109categories          print
    11 license             AGPL-3
     10license             AGPL-3 BSD
    1211maintainers         nomaintainer
    1312description         GPL Ghostscript, An interpreter for PostScript and PDF
    1413long_description    Ghostscript is the well-known PostScript interpreter which \
    1514                    is available for all common and most esoteric platforms and \
    1615                    supports many different printers and some displays.
    1716platforms           darwin
    18 homepage            http://www.cs.wisc.edu/~ghost/
    19 master_sites        http://downloads.ghostscript.com/public/:source \
     17homepage            http://www.ghostscript.com/
     18master_sites        https://github.com/ArtifexSoftware/ghostpdl-downloads/releases/download/gs919:source \
    2019                    sourceforge:gs-fonts:fonts \
    2120                    https://github.com/adobe-type-tools/mapping-resources-pdf/archive/:misc
    2221
    2322# Note: this needs to be manually updated for new upstream commits
    2423set mappingresources_commit \
    25                     3128b3872aa14a4c066d5cbcdde66a3b6bba0982
     24                    0bdcfbe5e394d4519e5969918c34d4eebf76a386
    2625
    2726distfiles           ${distname}.tar.gz:source \
    2827                    ghostscript-fonts-other-6.0.tar.gz:fonts \
    2928                    ghostscript-fonts-std-8.11.tar.gz:fonts \
    3029                    ${mappingresources_commit}.zip:misc
    3130
    32 # Fix for github's "stealth update". I have no idea how or why that even happened.
    33 dist_subdir         ${name}/${version}_1
    34 
    3531patchfiles          patch-base_unix-dll.mak.diff \
    36                     patch-base_stdpre.h.diff \
    3732                    no-werror.diff
    3833
    3934checksums           ${distname}.tar.gz \
    40                     rmd160  9c483b93ccd106bae6db36b3335fae4e91177aec \
    41                     sha256  746d77280cca8afdd3d4c2c1389e332ed9b0605bd107bcaae1d761b061d1a68d \
     35                    rmd160  c2668bf0ec8824ad305c56a27cd6102d416bd536 \
     36                    sha256  fc07d5eb1b325f59d4bb3994975e9ab769e7c7353403c6420f42c54161c552ca \
    4237                    ghostscript-fonts-other-6.0.tar.gz \
    4338                    rmd160  ab60dbf71e7d91283a106c3df381cadfe173082f \
    4439                    sha256  4fa051e341167008d37fe34c19d241060cd17b13909932cd7ca7fe759243c2de \
     
    4641                    rmd160  10a19a10d0388bc084a7c1d3da845068d7169054 \
    4742                    sha256  0eb6f356119f2e49b2563210852e17f57f9dcc5755f350a69a46a0d641a0c401 \
    4843                    ${mappingresources_commit}.zip \
    49                     rmd160  b00725e3f5615ac6aaa20a7b4d0dd6e769dca6ee \
    50                     sha256  27f87e56092a8293d17f683b008327afbb79fad9f1328227a9916f9be69c9db2
     44                    rmd160  ee0acf3e8a37c75db1a22af0248a0be25b31de93 \
     45                    sha256  64b1a28060fe04518ee152d1d479a5e8989519db756c35848257d29478936d1c
    5146
    5247depends_lib         port:expat \
    5348                    port:fontconfig \
     
    5954                    port:libpaper \
    6055                    port:libpng \
    6156                    port:tiff \
    62                     port:zlib
    63 #                   port:lcms2
    64 #                   port:ijs
     57                    port:zlib \
     58                    port:lcms2
    6559
    6660depends_build       port:pkgconfig
    6761
     
    7367
    7468post-extract {
    7569    system -W ${workpath} "unzip '${distpath}/${mappingresources_commit}.zip'"
    76     system -W ${workpath} "unzip '${workpath}/mapping-resources-pdf-${mappingresources_commit}/mappingresources4pdf_2unicode.zip'"
    77     system -W ${workpath} "unzip '${workpath}/mapping-resources-pdf-${mappingresources_commit}/mappingresources4pdf_other.zip'"
    7870
    79 #   MacPorts's lcms2 is 2.4 and it doesn't support cmsPluginTHR() yet.
    80 #   foreach d {freetype jbig2dec jpeg lcms2 libpng tiff zlib}
    81     foreach d {freetype jbig2dec jpeg       libpng tiff zlib} {
     71    foreach d {freetype jbig2dec jpeg lcms2 libpng tiff zlib} {
    8272        move ${worksrcpath}/${d} ${worksrcpath}/${d}_local
    8373    }
    8474
    8575    #move ${workpath}/MappingOther/Adobe-CNS1-ETen-B5 ${workpath}/MappingOther/Adobe-CNS1-ETenms-B5
    86     copy -force {*}[glob ${workpath}/mappingresources4pdf_2unicode/*] ${worksrcpath}/Resource/CMap
    87     copy -force {*}[glob ${workpath}/mappingresources4pdf_other/*]    ${worksrcpath}/Resource/CMap
     76    copy -force {*}[glob ${workpath}/mapping-resources-pdf-${mappingresources_commit}/mappingresources4pdf_2unicode/*] ${worksrcpath}/Resource/CMap
     77    copy -force {*}[glob ${workpath}/mapping-resources-pdf-${mappingresources_commit}/mappingresources4pdf_other/*]    ${worksrcpath}/Resource/CMap
    8878}
    8979
    9080post-patch {
     
    116106                    --with-system-libtiff
    117107
    118108build.target        so
    119 use_parallel_build  yes
    120109
    121110destroot.target     soinstall
    122111post-destroot {
     
    145134    xinstall -m 0644 -W ${workpath}/fonts \
    146135            COPYING ChangeLog README README.tweaks TODO \
    147136            ${destroot}${prefix}/share/doc/${name}/fonts
     137
     138    # install missing header
     139    xinstall -m 0644 ${worksrcpath}/base/gserrors.h \
     140            ${destroot}${prefix}/include/ghostscript/
    148141}
    149142
    150143post-activate {
  • print/ghostscript/files/patch-base_stdpre.h.diff

     
    1 --- base/stdpre.h.orig  2013-08-30 19:37:28.000000000 +0900
    2 +++ base/stdpre.h       2013-09-10 14:14:00.000000000 +0900
    3 @@ -20,7 +20,7 @@
    4  #  define stdpre_INCLUDED
    5  
    6  /* Ghostscript uses transitional LFS functions. */
    7 -#define _LARGEFILE64_SOURCE 1
    8 +/* #define _LARGEFILE64_SOURCE 1 */
    9  
    10  #ifndef _FILE_OFFSET_BITS
    11  #define _FILE_OFFSET_BITS 64