[125906] trunk/dports/x11/sunclock
jeremyhu at macports.org
jeremyhu at macports.org
Sun Sep 28 23:17:13 PDT 2014
Revision: 125906
https://trac.macports.org/changeset/125906
Author: jeremyhu at macports.org
Date: 2014-09-28 23:17:13 -0700 (Sun, 28 Sep 2014)
Log Message:
-----------
sunclock: Version bump and build without imake
Modified Paths:
--------------
trunk/dports/x11/sunclock/Portfile
trunk/dports/x11/sunclock/files/gzFile.patch
Modified: trunk/dports/x11/sunclock/Portfile
===================================================================
--- trunk/dports/x11/sunclock/Portfile 2014-09-29 05:59:05 UTC (rev 125905)
+++ trunk/dports/x11/sunclock/Portfile 2014-09-29 06:17:13 UTC (rev 125906)
@@ -3,11 +3,10 @@
PortSystem 1.0
name sunclock
-version 3.50pre1
-revision 4
-extract.suffix .tgz
+version 3.57
categories x11
maintainers nomaintainer
+license GPL-2
description shows Earth's surface illuminated by the Sun
long_description \
This program is a clock that shows which portion of the \
@@ -17,26 +16,58 @@
local time zone and UTC displayed.
homepage http://www.arvernes.com/wiki/index.php/Sunclock
platforms darwin
-master_sites ftp://ftp.ac-grenoble.fr/ge/geosciences/sunclock/ \
- openbsd:distfiles
-checksums md5 6e07964a99848018432825c5b3297cc6
-depends_lib port:jpeg port:xpm port:zlib
+distname ${name}_${version}.orig
+worksrcdir ${name}-${version}
+master_sites debian:s/${name}
+checksums rmd160 42ef99381405745bf2be13ad9c05c9f07e5ff1cd \
+ sha256 f3b3499b4a84c7a31411d2a9043e2d9171b745ec29a991ef9930ce582b9d41ab
+
+depends_lib port:jpeg port:xpm port:zlib port:libpng port:xorg-libX11
patchfiles gzFile.patch
-pre-configure {
- reinplace "s|DESTDIR=/usr|DESTDIR=${prefix}|" "${worksrcpath}/Imakefile"
- reinplace "s|MANDIR=/X11R6|MANDIR=/share|" "${worksrcpath}/Imakefile"
- reinplace "s|BINDIR=/X11R6/bin|BINDIR=/bin|" "${worksrcpath}/Imakefile"
- reinplace "s|#JLIBDIR=-L/usr/lib|JLIBDIR=-L${prefix}/lib|" "${worksrcpath}/Imakefile"
- reinplace "s|#JINC=-I/usr/include|JINC=-I${prefix}/include|" "${worksrcpath}/Imakefile"
+post-patch {
+ reinplace "/#include <malloc.h>/d" ${worksrcpath}/tildepath.c
}
-use_xmkmf yes
+use_configure no
-pre-build {
- reinplace "s|INCROOT = /usr/X11R6/include|INCROOT = ${prefix}/include|" "${worksrcpath}/Makefile"
- reinplace "s|#include <malloc.h>||" "${worksrcpath}/tildepath.c"
+set datadir ${prefix}/share/${name}
+set docdir ${prefix}/share/doc/${name}
+
+configure.cflags-append -Wall -DZLIB
+configure.cflags-append {-DSHAREDIR=\\\"${datadir}\\\"}
+configure.cflags-append {-DEMXBINDIR=\\\"${prefix}/bin\\\"}
+configure.cflags-append {-DDOCDIR=\\\"${docdir}\\\"}
+configure.ldflags-append -lXpm -ljpeg -lpng -lz -lX11
+
+# I hate Tcl
+build.env-append prefix=${prefix} datadir=${datadir} docdir=${docdir}
+
+build.pre_args -f Makefile.noimake
+build.target all
+build.args \
+ DESTDIR=${prefix} \
+ MANDIR=/share/man/man1 \
+ XAPPLOADDIR=/share/X11/app-defaults \
+ XBINDIR=/bin \
+ CC=${configure.cc} \
+ CFLAGS="[join ${configure.cflags}] [get_canonical_archflags] ${configure.optflags}" \
+ LFLAGS="${configure.ldflags} [get_canonical_archflags]"
+
+destroot {
+ xinstall -m 755 -W ${worksrcpath} sunclock editkit/emx ${destroot}${prefix}/bin
+ xinstall -m 644 -W ${worksrcpath} sunclock.man ${destroot}${prefix}/share/man/man1/sunclock.1
+
+ xinstall -d -m 755 ${destroot}${datadir}
+ xinstall -m 644 -W ${worksrcpath} Sunclockrc ${destroot}${datadir}
+
+ xinstall -d -m 755 ${destroot}${datadir}/earthmaps/vmf
+ eval xinstall -m 644 [glob ${worksrcpath}/vmf/*.vmf] ${destroot}${datadir}/earthmaps/vmf
+
+ xinstall -d -m 755 ${destroot}${datadir}/earthmaps/i18n
+ eval xinstall -m 644 [glob ${worksrcpath}/i18n/Sunclock.??] ${destroot}${datadir}/earthmaps/i18n
+
+ xinstall -d -m 755 ${destroot}${docdir}
+ xinstall -m 644 -W ${worksrcpath}/editkit MANUAL.emacs README ${destroot}${docdir}
}
-
-destroot.destdir DESTDIR=${destroot}${prefix} DOCHTMLDIR=/share/doc
Modified: trunk/dports/x11/sunclock/files/gzFile.patch
===================================================================
--- trunk/dports/x11/sunclock/files/gzFile.patch 2014-09-29 05:59:05 UTC (rev 125905)
+++ trunk/dports/x11/sunclock/files/gzFile.patch 2014-09-29 06:17:13 UTC (rev 125906)
@@ -1,6 +1,6 @@
---- readvmf.c.orig 2001-08-12 00:03:18.000000000 +1000
-+++ readvmf.c 2012-06-02 04:04:18.000000000 +1000
-@@ -334,7 +334,7 @@ pixmap_image()
+--- readvmf.c.orig 2008-08-22 06:58:52.000000000 -0700
++++ readvmf.c 2014-09-28 22:23:14.000000000 -0700
+@@ -340,7 +340,7 @@ pixmap_image()
char *
getdata(fd)
#ifdef ZLIB
@@ -9,12 +9,12 @@
#else
FILE *fd;
#endif
-@@ -426,7 +426,7 @@ struct Sundata * Context;
+@@ -433,7 +433,7 @@ struct Sundata * Context;
double theta, phi;
- char *str;
+ char *str, *ptr;
#ifdef ZLIB
- gzFile * fd;
+ gzFile fd;
+ int plen;
+ char *zpath;
#else
- FILE *fd;
- #endif
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/macports-changes/attachments/20140928/9539ad8a/attachment.html>
More information about the macports-changes
mailing list