openbsd-ports/astro/sunclock/patches/patch-Imakefile
naddy 9ddae77c3d - update home page
- fix library order to allow static linking
- fix C99-ism to allow building with gcc2
2009-03-23 17:20:33 +00:00

60 lines
1.9 KiB
Plaintext

$OpenBSD: patch-Imakefile,v 1.5 2009/03/23 17:20:33 naddy Exp $
--- Imakefile.orig Sun Jun 18 21:58:50 2006
+++ Imakefile Mon Mar 23 17:28:30 2009
@@ -1,5 +1,5 @@
XCOMM Should install to /usr or /usr/local ??
-DESTDIR=/usr
+#DESTDIR=/usr
XCOMM Name of man subdirectory of DESTDIR:
MANDIR=/X11R6/man/man1
@@ -8,7 +8,7 @@ XCOMM Name of bin subdirectory of DESTDIR: /X11R6/bin
BINDIR=/X11R6/bin
XCOMM Name of share subdirectory of DESTDIR:
-SHAREDIR=/share/sunclock
+SHAREDIR=${PREFIX}/share/sunclock
XCOMM Name of DOCDIR's subdirectories of DESTDIR:
DOCDIR=/X11R6/lib/X11/doc
@@ -42,31 +42,25 @@ CCOPTIONS = -Ae $(XPMINC) $(JINC) -DZLIB -DSHAREDIR=\"
#CCOPTIONS=-O -DZLIB -DNEW_CTIME -DSHAREDIR=\"$(DESTDIR)$(SHAREDIR)\"
# Solaris, Linux
-#XPMLIBDIR=-L/usr/X11R6/lib
-#XPMINC=-I/usr/X11R6/include/X11
-#JLIBDIR=-L/usr/lib
-#ZLIBDIR=-L/usr/lib
-#JINC=-I/usr/include
+XPMLIBDIR=-L${X11BASE}/lib
+XPMINC=-I${X11BASE}/include/X11
+JLIBDIR=-L${DEPBASE}/lib
+ZLIBDIR=
+JINC=-I${DEPBASE}/include
+PINC=-I${DEPBASE}/include/libpng
-CCOPTIONS=-O -DZLIB -DSHAREDIR=\"$(DESTDIR)$(SHAREDIR)\"
+CCOPTIONS+= $(JINC) $(PINC) $(XPMINC) -DZLIB -DSHAREDIR=\"$(DESTDIR)$(SHAREDIR)\"
#endif
SRCS=sunclock.c astro.c widgets.c tildepath.c dirlist.c \
readvmf.c readxpm.c readgif.c readjpeg.c readpng.c
OBJS=sunclock.o astro.o widgets.o tildepath.o dirlist.o \
readvmf.o readxpm.o readgif.o readjpeg.o readpng.o
-LOCAL_LIBRARIES=$(XLIB) $(XPMLIBDIR) -lXpm $(ZLIBDIR) -lz \
+LOCAL_LIBRARIES=$(XPMLIBDIR) -lXpm $(XLIB) $(ZLIBDIR) -lz \
$(JLIBDIR) -ljpeg -lpng -lm
DEPLIBS= # I don't know what I'm doing, and I hate imake!
ComplexProgramTarget(sunclock)
-
-all::
- cd editkit ; xmkmf ; make emx \
- DESTDIR=$(DESTDIR) \
- BINDIR=$(SHAREDIR)/bin \
- MANDIR=$(SHAREDIR)/editkit \
- SHAREDIR=$(DESTDIR)$(SHAREDIR)/editkit
install.man::
if [ -r $(DESTDIR)$(MANDIR)/sunclock.1x.gz ] ; \