$NetBSD: patch-aa,v 1.5 2017/09/21 14:37:40 bsiegert Exp $ --- libXg/Makefile.orig 2017-09-21 13:54:42.000000000 +0000 +++ libXg/Makefile @@ -1,24 +1,23 @@ # Copyright (c) 1992 AT&T - All rights reserved. # -# Prototype Makefile for libXg +# Prototype BSDi Makefile for libXg +# Courtesy of Boyd Roberts +# +# Define operating system type: -DBSDi # -# define operating system. ONE of: -# -DIRIX -DSUNOS -DUMIPS -DSYSVR3 -DAIX -DOSF1 -# -DHPUX -DAPOLLO -DCONVEX -DDYNIX -# # Additionally, -D_POSIX_SOURCE (or its equivalent) may be specified # if your compiler supports posix-compatible compilation -OS=-DIRIX -ansiposix +OS=-O2 -DBSDi # add -Iincludedir for any include directories that need to be searched -INCS=-I../include +INCS=-I../include -I${X11BASE}/include # set this if your X libraries are in different locations # or if you need extra libraries to load with X11 applications -XLIBS=/usr/local/X11R5/lib/libXt.a /usr/local/X11R5/lib/libX11.a +XLIBS=-L${X11BASE}/lib -Wl,-R${X11BASE}/lib -lXt -lX11 # add name of library orderer - use ":" if none -RANLIB=: +RANLIB=ranlib # add name of librarian AR=ar @@ -36,7 +35,7 @@ OBJS= arc.o arith.o balloc.o bitblt.o bi rdfontfile.o rectclip.o rune.o segment.o string.o strwidth.o texture.o\ wrbitmap.o wrbitmapfile.o xtbinit.o -all install: $(LIB) +all : $(LIB) compile: $(LIB) test: test.o $(CC) -o $@ $? $(LIB) $(XLIBS) -lm @@ -47,10 +46,12 @@ clean: nuke: clean rm -f $(LIB) +install: ${LIB} + cp ${LIB} ${PREFIX}/lib/${LIB} + ${RANLIB} ${PREFIX}/lib/${LIB} + $(LIB): $(OBJS) $(AR) rv $(LIB) $(OBJS) $(RANLIB) $(LIB) -$(LIB)(%.o): %.o - $(OBJS): ../include/libg.h libgint.h ../include/libc.h