Ticket #52542: Portfile

File Portfile, 3.3 KB (added by ken-cunningham-webuse, 8 years ago)
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 139308 2015-08-12 02:46:18Z jmr@macports.org $
3
4PortSystem          1.0
5PortGroup           cmake 1.0
6PortGroup           cxx11 1.0
7name                widelands-devel
8conflicts           widelands
9version             build19
10# Hold for later    revision            0
11categories          games
12platforms           darwin
13maintainers         nomaintainer
14license             GPL-2+
15
16description         open-source real-time strategy game inspired by Settlers
17long_description    Widelands is an open-source real-time strategy game. It \
18                    is built upon the SDL and other open source libraries and \
19                    is (and will always be) under heavy development. If you \
20                    knew Settlers I & II (© Bluebyte), then you already have \
21                    a rough idea what Widelands is all about because \
22                    widelands is heavily inspired by those two games.
23
24homepage            http://wl.widelands.org/
25# Hold for later    master_sites        https://launchpad.net/${name}/${version}/build-18/+download/
26
27fetch.type          bzr
28bzr.url             lp:widelands
29
30# Hold for later     use_bzip2           yes
31# Hold for later     distfiles           ${distname}-src${extract.suffix}
32# Hold for later     worksrcdir          ${distname}-src/
33# Hold for later     checksums           rmd160  9af8cf7b8108475bec23ac94c2ac05f4d9a60d67 \
34#                    sha256  6dffd9178f93ff7a9c3c0c9b31b7d3b8eb060c79fbd98901e6311837390b7de3
35
36depends_lib         port:libsdl2 \
37                    port:libsdl2_image \
38                    port:libsdl2_mixer \
39                    port:libsdl2_net \
40                    port:libsdl2_ttf \
41                    port:libsdl_gfx \
42                    port:boost \
43                    port:libpng \
44                    port:glew \
45                    port:lua
46
47cmake.out_of_source yes
48configure.args      -DCMAKE_INSTALL_PREFIX:PATH="${applications_dir}/Widelands.app/Contents/MacOS"
49
50
51pre-destroot {
52    xinstall -d ${destroot}${applications_dir}/Widelands.app/Contents/Resources \
53                ${destroot}${applications_dir}/Widelands.app/MacOS
54    file copy ${worksrcpath}/data/images/logos/widelands.icns ${destroot}${applications_dir}/Widelands.app/Contents/Resources/widelands.icns
55    set data    " {\n\
56                CFBundleName = widelands;\n\
57                CFBundleDisplayName = Widelands;\n\
58                CFBundleIdentifier = \"org.widelands.wl\";\n\
59                CFBundleVersion = ${version};\n\
60                \"CFBundleInfoDictionaryVersion\" = \"6.0\";\n\
61                CFBundlePackageType = APPL;\n\
62                CFBundleSignature = \"????\";\n\
63                CFBundleExecutable = widelands;\n\
64                CFBundleIconFile = \"widelands.icns\";\n\
65                }"
66    set filename "${destroot}${applications_dir}/Widelands.app/Contents/Info.plist"
67    set fileId [open $filename "w"]
68    puts -nonewline $fileId $data
69    close $fileId
70}
71
72notes \
73"On some systems, Widelands might demonstrate button artifacts or other visual \
74 \nanomalies. If this occurs, consider editing ~/.widelands/config to change \
75 \nthe opengl setting to opengl=\"false.\""
76