source: trunk/dports/x11/tk/Portfile

Last change on this file was 151783, checked in by mps@…, 13 months ago

tcl, tk: update to version 8.6.6.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 3.0 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 151783 2016-08-21 23:42:43Z ryandesign@macports.org $
3
4PortSystem      1.0
5
6name            tk
7version         8.6.6
8categories      x11
9license         Tcl/Tk
10maintainers     mww openmaintainer
11description     Tcl Tool Kit
12homepage        http://www.tcl.tk/
13long_description \
14  This is Tk version ${version}, a GUI toolkit for Tcl. The best way to get \
15  started with Tcl is to read ``Tcl and the Tk Toolkit'' by John K.         \
16  Ousterhout, Addison-Wesley, ISBN 0-201-63337-X.
17
18platforms       darwin
19
20master_sites    sourceforge:project/tcl/Tcl/${version}
21dist_subdir     tcltk
22distname        ${name}${version}-src
23
24# suck in Tcl as well so we can use it internally.
25distfiles-append    tcl${version}-src${extract.suffix}
26
27checksums           tk${version}-src.tar.gz \
28                    rmd160  619c250050bf8216855ea1c646207d1d147a95b8 \
29                    sha256  d62c371a71b4744ed830e3c21d27968c31dba74dd2c45f36b9b071e6d88eb19d \
30                    tcl${version}-src.tar.gz \
31                    rmd160  2386a69eb841f8af51c1b124f68e0b812a225cca \
32                    sha256  a265409781e4b3edcc4ef822533071b34c3dc6790b893963809b9fe221befe07
33
34depends_build   port:pkgconfig
35
36# force usage of MacPorts Tcl
37depends_lib \
38    port:tcl \
39    port:Xft2 \
40    port:xorg-libXScrnSaver \
41    port:fontconfig
42
43worksrcdir      ${name}${version}/unix
44
45patch.dir           ${workpath}/${name}${version}
46patchfiles          patch-unix-Makefile.in.diff
47
48post-patch {
49    reinplace s|@TCL_SRC_DIR@|${workpath}/tcl${version}/|g ${worksrcpath}/Makefile.in
50}
51
52configure.args      --mandir=${prefix}/share/man --with-tcl=${prefix}/lib
53configure.cppflags  -I${workpath}/tcl${version}/generic
54configure.ldflags   -L${worksrcpath} -L${prefix}/lib -lfontconfig
55
56destroot.destdir    INSTALL_ROOT=${destroot}
57post-destroot {
58    ln -s wish8.6 ${destroot}${prefix}/bin/wish
59    ln -s libtk8.6.dylib ${destroot}${prefix}/lib/libtk.dylib
60}
61
62if {${configure.build_arch} eq "x86_64" || ${configure.build_arch} eq "ppc64"} {
63    configure.args-append   --enable-64bit
64}
65
66if {${os.platform} eq "darwin" && ${os.subplatform} eq "macosx" && ${os.major} >= 10} {
67    variant quartz conflicts x11 {
68        depends_lib-delete port:Xft2 port:xorg-libXScrnSaver port:fontconfig
69        # tk.h still includes and uses types from X11/Xlib.h
70        depends_lib-append port:xorg-libX11
71        configure.ldflags-delete    -lfontconfig
72        configure.args-append   --enable-aqua
73        post-destroot {
74            delete ${destroot}${prefix}/include/X11
75        }
76    }
77
78    variant x11 conflicts quartz {}
79
80    if {![variant_isset quartz]} {
81        default_variants +x11
82    }
83} else {
84    # Even though X11 is the only option, make a variant so that other ports
85    # can check for it being set with require_active_variants.
86    variant x11 {}
87    default_variants +x11
88}
89
90platform darwin {
91    configure.args-append   tcl_cv_type_64bit="long long"
92}
93
94livecheck.type  regex
95livecheck.regex {Tcl/Tk (\d+(?:\.\d+)*)</a>}
Note: See TracBrowser for help on using the repository browser.