source: trunk/dports/devel/libsdl/Portfile @ 30546

Last change on this file since 30546 was 30546, checked in by ryandesign@…, 11 years ago

s/XCode/Xcode/g

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 3.2 KB
Line 
1# $Id: Portfile 30546 2007-10-31 03:44:59Z ryandesign@macports.org $
2
3PortSystem      1.0
4
5name            libsdl
6set my_name     SDL
7version         1.2.12
8categories      devel multimedia
9platforms       macosx freebsd
10maintainers     nox openmaintainer
11description     Cross-platform multi-media development API
12
13long_description \
14    Simple DirectMedia Layer is a cross-platform multimedia library designed \
15    to provide fast access to the graphics framebuffer and audio device. It is \
16    used by MPEG playback software, emulators, and many popular games, including \
17    the award winning Linux port of \"Civilization: Call To Power.\" Simple \
18    DirectMedia Layer supports Linux, Win32, BeOS, Mac OS, Solaris, IRIX, and FreeBSD.
19
20homepage        http://www.libsdl.org/
21master_sites    ${homepage}release/
22distname        ${my_name}-${version}
23
24checksums       md5 544b4554986e51eed6d34435cf9c5f3f \
25                sha1 2c37ff1683368369c0f555d4a742f0544153610d \
26                rmd160 3871023c63ea056eba43ce4f55ee8d3a73ff3022
27
28depends_lib     lib:libX11.6:XFree86
29
30configure.args  --enable-shared \
31                --mandir=${prefix}/share/man
32
33set docdir      ${prefix}/share/doc/${name}-${version}
34
35post-destroot {
36    xinstall -d ${destroot}${docdir}/html
37
38    xinstall -m 0644 -W ${worksrcpath} BUGS COPYING CREDITS INSTALL README README-SDL.txt \
39        README.MacOSX TODO ${destroot}${docdir}
40
41    xinstall -m 0644 -W ${worksrcpath} docs.html docs/index.html ${destroot}${docdir}/html
42    reinplace {s@docs/@@g} ${destroot}${docdir}/html/docs.html   
43
44    foreach {dir} {html images} {
45        xinstall -d ${destroot}${docdir}/html/${dir}
46        eval xinstall -m 0644 [glob ${worksrcpath}/docs/${dir}/*] ${destroot}${docdir}/html/${dir}
47    }
48}
49
50platform darwin 7 {
51    pre-fetch {
52        set qt_header [open /System/Library/Frameworks/QuickTime.framework/Headers/QuickTime.h r]
53
54        while {[gets $qt_header line] != -1} {
55            if {[regexp {Version:} $line]} {
56                regexp {(\d+\.\d+(?:\.(\d+))?$} $line qt_ver
57
58                if {[rpm-vercomp ${qt_ver} 7.0.3] > 0} {
59                    ui_error ""
60                    ui_error "Installation of libSDL is exiting because it believes you have"
61                    ui_error "QuickTime version ${qt_ver} installed."
62                    ui_error ""
63                    ui_error "On Mac OS 10.3/Xcode 1.5, you must have QuickTime 7.0.3 or lower if"
64                    ui_error "you want to install the libSDL port."
65                    ui_error ""
66                    ui_error "If you actually have QuickTime 7.0.3 or below and you think you should not be"
67                    ui_error "receiving this error message, you can report the problem here:"
68                    ui_error "http://trac.macports.org/projects/macports/ticket/6533"
69
70                    return -code 1 "${name} cannot build on Panther with QuickTime 7.0.4 or later."
71                }
72
73                break
74            }
75        }
76
77        close $qt_header
78    }
79}
80
81platform darwin 8 {
82    post-patch {
83        reinplace -E {/archivecmds=/s/CC/CXX/} ${worksrcpath}/configure
84    }
85}
86
87platform darwin 9 {
88    patchfiles-append patch-AudioFilePlayer.h patch-SDL_coreaudio.c
89}
90
91livecheck.check regex
92livecheck.url   ${homepage}download.php
93livecheck.regex ${my_name}-(\\d+(?:\\.\\d+)*)
94
Note: See TracBrowser for help on using the repository browser.