source: trunk/dports/editors/emacs/Portfile @ 97387

Last change on this file since 97387 was 97387, checked in by dports@…, 7 years ago

emacs, emacs22, emacs23, emacs-snapshot: revbump for libpng update
(really only needed for +x11/+gtk variants)

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 4.3 KB
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 97387 2012-09-04 19:48:38Z dports@macports.org $
3
4PortSystem 1.0
5PortGroup  muniversal 1.0
6
7name            emacs
8conflicts       xemacs
9version         24.2
10revision        1
11
12categories      editors
13license         GPL-3+
14maintainers     dports openmaintainer
15description     The GNU Emacs text editor
16long_description \
17    GNU Emacs is a self-documenting, customizable, extensible real-time \
18    display editor. Users new to Emacs will be able to use basic        \
19    features fairly rapidly by studying the tutorial and using the      \
20    self-documentation features. Emacs also has an extensive            \
21    interactive manual browser. It is easily extensible since its       \
22    editing commands are written in Lisp.
23
24platforms       darwin freebsd
25homepage        http://www.gnu.org/software/emacs/emacs.html
26master_sites    gnu
27
28checksums       rmd160  26f6c2b671ed7f160875d62e47c89afec085110f \
29                sha256  6d9892dff6e1761d4a5eba20712beba4f37d77a196f8021081a2e69fcb5bd357
30
31patchfiles      patch-configure.diff
32
33configure.args  --without-x \
34                --without-dbus \
35                --without-gconf \
36                --without-libotf \
37                --without-m17n-flt \
38                --without-gpm \
39                --without-gnutls \
40                --without-xml2 \
41                --infodir ${prefix}/share/info/${name}
42
43depends_build   port:pkgconfig \
44                port:texinfo
45depends_lib     port:ncurses
46
47post-destroot {
48    xinstall -d ${destroot}${prefix}/share/emacs/${version}/leim
49    delete ${destroot}${prefix}/bin/ctags
50    delete ${destroot}${prefix}/share/man/man1/ctags.1.gz
51}
52
53livecheck.type  regex
54livecheck.url   http://ftp.gnu.org/gnu/emacs/?C=M&O=D
55livecheck.regex ${name}-(\\d+\\.\\d+\\w*)\\.tar
56
57variant x11 description {Builds emacs as a X11 program with Lucid widgets} {
58    configure.args-delete   --without-x
59    configure.args-append   --with-x-toolkit=lucid \
60                            --without-xaw3d \
61                            --with-xpm \
62                            --with-jpeg \
63                            --with-tiff \
64                            --with-gif \
65                            --with-png \
66                            --without-rsvg \
67                            --with-xft 
68    depends_lib-append      port:xorg-libXmu \
69                            port:xorg-libXaw \
70                            port:xpm \
71                            port:jpeg \
72                            port:tiff \
73                            port:giflib \
74                            port:libpng \
75                            port:Xft2
76
77    # autoconf appears to be dropping linker flags for freetype &
78    # fontconfig; work around this. See #28083
79    configure.ldflags-append -lfreetype -lfontconfig
80}
81
82platform darwin {
83    post-patch {
84        # Leopard's XCode 3.1.x ld(1) man page claims -no_pie is supported, but it's not
85        if {${os.major} < 9} {
86            reinplace "s:-fno-pie::" ${worksrcpath}/src/s/darwin.h
87        } elseif {${os.major} > 10} {
88            reinplace "s:-fno-pie:-fno-pie -Wl,-no_pie:" ${worksrcpath}/src/s/darwin.h
89
90            # I believe the above reinplace is sufficient, but I'm leaving this to be safe --jeremyhu
91            configure.ldflags-append -Wl,-no_pie
92        }
93    }
94}
95
96variant motif requires x11 description {Builds emacs as an X11 program with Motif widgets} {
97    configure.args-delete   --with-x-toolkit=lucid
98    configure.args-append   --with-x-toolkit=motif
99    depends_lib-append      lib:libXm:openmotif
100}
101
102variant gtk requires x11 description {Builds emacs as an X11 program with GTK+2 widgets} {
103    configure.args-delete   --with-x-toolkit=lucid
104    configure.args-delete   --without-gconf
105    configure.args-delete   --without-rsvg
106    configure.args-append   --with-x-toolkit=gtk
107    configure.args-append   --with-gconf
108    configure.args-append   --with-rsvg
109    depends_lib-append      port:gtk2 \
110                            path:lib/pkgconfig/glib-2.0.pc:glib2 \
111                            port:gconf \
112                            port:librsvg
113}
114
115variant dbus description {Builds emacs with D-Bus support} {
116    configure.args-delete   --without-dbus
117    configure.args-append   --with-dbus
118    depends_lib-append      port:dbus
119}
Note: See TracBrowser for help on using the repository browser.