Ticket #34346: aquaterm-v4.Portfile

File aquaterm-v4.Portfile, 3.0 KB (added by mojca (Mojca Miklavec), 12 years ago)

(supossedly) final Portfile for AquaTerm v. 1.1.1

Line 
1# $Id: Portfile 85443 2011-10-13 23:51:45Z dports@macports.org $
2
3PortSystem              1.0
4PortGroup               xcode 1.0
5PortGroup               github 1.0
6
7github.setup            AquaTerm AquaTerm 1.1.1 v
8name                    aquaterm
9categories              aqua math science
10maintainers             mcalhoun openmaintainer
11license                 BSD
12description             AquaTerm is a viewer that displays vector graphics on Mac OS X
13long_description        AquaTerm is a viewer app that displays vector \
14                        graphics.  Other apps connect to AquaTerm using a \
15                        simple remote object messaging protocol.  By adding \
16                        \"adapters\" to legacy code very little coding is \
17                        needed to bring it to OS X.
18platforms               darwin
19homepage                http://aquaterm.github.com/
20
21checksums               rmd160  007db0806a2b1b1263043647035fa428b15560e3 \
22                        sha256  8e35cb81f5f024382ba4b2c96569631b34cf798966aa2870258f272e551c0e34
23
24build.dir               ${worksrcpath}/aquaterm
25
26xcode.target            AquaTerm
27xcode.configuration     Default
28
29xcode.build.settings    LOCAL_APPS_DIR=${applications_dir} LOCAL_FRAMEWORKS_DIR=${frameworks_dir}
30xcode.destroot.settings LOCAL_APPS_DIR=${applications_dir} LOCAL_FRAMEWORKS_DIR=${frameworks_dir}
31xcode.destroot.type     mixed
32
33post-patch {
34    # Try to open the right version of AquaTerm.app.
35    # (If incompatible version is installed in /Applications,
36    #  we need to make sure that the one from MacPorts is found first.)
37    reinplace "s|/Applications/AquaTerm.app|${applications_dir}/AquaTerm.app|" \
38        ${worksrcpath}/aquaterm/AQTClientManager.m
39
40    ###############################
41    # temporary for testing before the release
42    reinplace "s|-laquaterm|-Wl,-framework -Wl,AquaTerm|" \
43        ${worksrcpath}/adapters/pgplot/g77_gcc_AQT.conf \
44        ${worksrcpath}/adapters/pgplot/xlf_gcc_AQT.conf
45    reinplace "s|.aquaterm/AQTAdapter.h.|<AquaTerm/AQTAdapter.h>|" \
46        ${worksrcpath}/adapters/pgplot/aqdriv.m
47    ###############################
48
49    reinplace "s|# FRAMEWORKS_DIR.*|FRAMEWORKS_DIR = ${frameworks_dir}|" \
50        ${worksrcpath}/adapters/c/Makefile \
51        ${worksrcpath}/adapters/fortran/Makefile
52
53    reinplace "s|/usr/local|${prefix}|g" \
54        ${worksrcpath}/adapters/pgplot/ChangeLog \
55        ${worksrcpath}/adapters/pgplot/g77_gcc_AQT.conf \
56        ${worksrcpath}/adapters/pgplot/xlf_gcc_AQT.conf
57
58    # those are not really needed, it's just cosmetics
59    reinplace "s|/*<PREFIX>|${prefix}|g" \
60        ${worksrcpath}/adapters/pgplot/g77_cc_AQT.conf \
61        ${worksrcpath}/adapters/pgplot/g77_gcc_AQT.conf \
62        ${worksrcpath}/adapters/pgplot/xlf_gcc_AQT.conf
63    reinplace "s|/sw|${prefix}|g" \
64        ${worksrcpath}/adapters/pgplot/ReadMe
65}
66
67post-destroot {
68    xinstall -d -m 0755 ${destroot}${prefix}/share/AquaTerm
69    copy ${worksrcpath}/adapters ${destroot}${prefix}/share/AquaTerm
70}