$NetBSD: patch-client_Makefile,v 1.5 2020/11/30 12:26:07 nia Exp $ Configure for pkgsrc. Don't build with -g or -Werror. Also, remove explicit depends on header files in /usr/include, many of which aren't actually used. --- client/Makefile.orig 2013-01-02 23:00:42.000000000 +0000 +++ client/Makefile @@ -18,14 +18,14 @@ CC = cc -CFLAGS+= -std=gnu99 -Wall -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith -Wno-sign-compare -Wno-traditional -Wa,--fatal-warnings -Wreturn-type -Wswitch -Wshadow -Wcast-qual -Wwrite-strings -Wextra -Wno-unused-parameter -Wno-sign-compare -Wold-style-definition -Wsign-compare -Wformat=2 -Wno-format-zero-length -Werror +CFLAGS+= -std=gnu99 -Wall -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith -Wno-sign-compare -Wa,--fatal-warnings -Wreturn-type -Wswitch -Wshadow -Wcast-qual -Wwrite-strings -Wextra -Wno-unused-parameter -Wno-sign-compare -Wold-style-definition -Wsign-compare -Wformat=2 -Wno-format-zero-length #CFLAGS = -O -DSERVICES -DLOCAL_ECHO -CFLAGS += -g -DSERVICES #-DLOCAL_ECHO +CFLAGS += -DSERVICES #-DLOCAL_ECHO LIBS = -lcurses -ltermlib #-lresolv LPR = lpr #RDEST = /usr/ucb/phone -RDEST = /usr/local/bin/phone +RDEST = ${PREFIX}/bin/phone HDRS = defs.h @@ -50,14 +50,14 @@ DEST = phone all: ${DEST} ${DEST}: ${OBJS} - /bin/rm -f ${DEST} + rm -f ${DEST} ${CC} ${CFLAGS} -o ${DEST} ${OBJS} ${LIBS} ${OBJS}: ${HDRS} install: ${DEST} - /bin/rm -f ${RDEST} - cp ${DEST} ${RDEST} + rm -f ${RDEST} + ${BSD_INSTALL_PROGRAM} ${DEST} ${DESTDIR}${RDEST} print: ${HDRS} ${SRCS} pr -f ${HDRS} ${SRCS} | expand -4 | ${LPR} @@ -99,60 +99,9 @@ depend: ${SRCS} # DO NOT DELETE THE FOLLOWING LINE # Dependencies follow -who.o: /usr/include/sys/file.h - -who.o: /usr/include/utmp.h - -runprog.o: /usr/include/fcntl.h - -runprog.o: /usr/include/sys/resource.h - -runprog.o: /usr/include/sys/wait.h - -tilde.o names.o: /usr/include/pwd.h - -windows.o stop.o runprog.o readstream.o misc.o kb.o: /usr/include/sgtty.h - -windows.o stop.o runprog.o readstream.o misc.o kb.o: /usr/include/curses.h - -windows.o stop.o sig.o runprog.o readstream.o misc.o kb.o: \ -/usr/include/sys/ttydev.h - -windows.o stop.o sig.o runprog.o readstream.o misc.o kb.o: \ -/usr/include/sys/ttychars.h - -windows.o windows.o stop.o sig.o runprog.o readstream.o misc.o kb.o: \ -/usr/include/sys/ioctl.h - -runprog.o main.o getdaemon.o: /usr/include/errno.h - -windows.o strsave.o stop.o sig.o message.o main.o getdaemon.o \ -connect_daemon.o: /usr/include/signal.h - -sendit.o runprog.o getdaemon.o calls.o: /usr/include/time.h - -sendit.o runprog.o getdaemon.o calls.o: /usr/include/sys/time.h - -who.o names.o connect_daemon.o calls.o: /usr/include/netdb.h - who.o runprog.o readstream.o readctl.o names.o main.o getdaemon.o \ connect_daemon.o check_invite.o calls.o: ./../common.h -windows.o strsave.o stop.o runprog.o readstream.o readrc.o names.o misc.o \ -message.o main.o kb.o connect_daemon.o calls.o: /usr/include/stdio.h - -windows.o who.o stop.o set.o sendit.o runprog.o readstream.o readrc.o \ -readctl.o names.o misc.o message.o main.o kb.o getdaemon.o connect_daemon.o \ -check_invite.o calls.o alias.o: /usr/include/netinet/in.h - -windows.o who.o stop.o set.o sendit.o runprog.o readstream.o readrc.o \ -readctl.o names.o misc.o message.o main.o kb.o getdaemon.o connect_daemon.o \ -check_invite.o calls.o alias.o: /usr/include/sys/socket.h - -windows.o who.o stop.o set.o sendit.o runprog.o runprog.o readstream.o \ -readrc.o readctl.o names.o misc.o message.o main.o kb.o getdaemon.o \ -connect_daemon.o check_invite.o calls.o alias.o: /usr/include/sys/types.h - windows.o who.o stop.o set.o sendit.o runprog.o readstream.o readrc.o \ readctl.o names.o misc.o message.o main.o kb.o getdaemon.o connect_daemon.o \ check_invite.o calls.o alias.o: ./defs.h