1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-12-30 05:40:06 +00:00
freebsd-ports/ftp/xrmftp/files/patch-aa
2002-07-04 08:09:05 +00:00

36 lines
1.4 KiB
Plaintext

--- Makefile.orig Tue Nov 17 19:25:43 1998
+++ Makefile Mon Jul 1 01:56:44 2002
@@ -1,17 +1,24 @@
-CC=gcc
-XFORMSLIBPATH=/usr/X11R6/lib # path to xforms library
-XFORMSINCPATH=/usr/X11R6/include # path to xforms header file <forms.h>
-XLIBSPATH=/usr/X11R6/lib # path to standard X libraries
-XINCPATH=/usr/X11R6/include # path to standard X header files
-LIBS= -lm -lX11 -lforms # libraries
+X11BASE?=/usr/X11R6
+CC ?=gcc
+XFORMSLIBPATH=${X11BASE}/lib # path to xforms library
+.if exists (${X11BASE}/include/X11/forms.h)
+XFORMSINCPATH=${X11BASE}/include/X11
+.else
+XFORMSINCPATH=${X11BASE}/include
+.endif
+XLIBSPATH=${X11BASE}/lib # path to standard X libraries
+XINCPATH=${X11BASE}/include # path to standard X header files
+LIBS= -lm -lX11 -lforms -lXpm # libraries
#EXTRALIBS=-lnsl -lsocket # additional libraries needed by some unices
SRC=xftp.c fd_xftp.c
OBJ=$(SRC:.c=.o)
EXE=xrmftp
-CFLAGS=-I/usr/include -I${XFORMSINCPATH} -I${XINCPATH}
-LDFLAGS=-L/usr/lib -L${XLIBSPATH} ${LIBS} ${EXTRALIBS} -L${XFORMSLIBPATH} -O3
+CFLAGS +=-I/usr/include -I${XFORMSINCPATH} -I${XINCPATH}
+LDFLAGS =-L/usr/lib -L${XLIBSPATH} ${LIBS} ${EXTRALIBS} -L${XFORMSLIBPATH}
#------------------------------------------------------------------------------
+
+all: ${EXE}
${EXE}: ${OBJ}
${CC} ${LDFLAGS} -o ${EXE} ${OBJ}