$NetBSD: patch-aa,v 1.11 2005/12/28 04:58:01 reed Exp $ --- Makefile.orig 2004-10-04 08:32:26.000000000 +1000 +++ Makefile @@ -11,7 +11,7 @@ # Where to install things: -PREFIX=/usr/local +#PREFIX=/usr/local # Program: @@ -27,16 +27,9 @@ DATA_PREFIX=$(PREFIX)/share/tuxpaint/ # Docs and man page: DOC_PREFIX=$(PREFIX)/share/doc/tuxpaint/ -MAN_PREFIX=$(PREFIX)/share/man/ +MAN_PREFIX=$(PREFIX)/$(PKGMANDIR) -# 'System-wide' Config file: - -ifeq ($(PREFIX),/usr) - CONFDIR=/etc/tuxpaint -else - CONFDIR=$(PREFIX)/etc/tuxpaint -endif # Commands useful to other arch's (e.g., BeOS) @@ -88,7 +81,7 @@ SDL_CFLAGS=$(shell sdl-config --cflags) # The entire set of CFLAGS: -CFLAGS=-O2 -Wall -Isrc/$(MOUSEDIR) -D$(CURSOR_SHAPES)_CURSOR_SHAPES +CFLAGS+=-Wall -Isrc/$(MOUSEDIR) -D$(CURSOR_SHAPES)_CURSOR_SHAPES DEFS=-DDATA_PREFIX=\"$(DATA_PREFIX)\" \ -D$(NOSOUNDFLAG) -DDOC_PREFIX=\"$(DOC_PREFIX)\" \ -DLOCALEDIR=\"$(LOCALE_PREFIX)\" -DCONFDIR=\"$(CONFDIR)\" @@ -143,10 +136,9 @@ beos: # to do this as superuser ("root")) install: install-bin install-data install-man install-doc \ - install-icon install-gettext install-importscript \ + install-gettext install-importscript \ install-default-config install-example-stamps \ - install-example-starters \ - install-gnome install-kde install-kde-icons + install-example-starters @echo @echo "--------------------------------------------------------------" @echo @@ -288,9 +280,9 @@ uninstall: install-default-config: @echo @echo "...Installing default config file..." - @install -d $(CONFDIR) - @cp src/tuxpaint.conf $(CONFDIR) - @chmod 644 $(CONFDIR)/tuxpaint.conf + @$(BSD_INSTALL_DATA_DIR) $(PREFIX)/share/examples/tuxpaint + @$(CP) src/tuxpaint.conf $(PREFIX)/share/examples/tuxpaint + @$(CHMOD) 644 $(PREFIX)/share/examples/tuxpaint/tuxpaint.conf # Install example stamps @@ -698,10 +690,10 @@ install-man: tuxpaint: obj/tuxpaint.o $(HQXX_O) $(ARCH_LIBS) @echo @echo "...Linking Tux Paint..." - @$(CC) $(CFLAGS) $(SDL_CFLAGS) $(DEFS) \ + @$(CC) $(CFLAGS) $(LDFLAGS) $(SDL_CFLAGS) $(DEFS) \ -o tuxpaint obj/tuxpaint.o $(HQXX_O) \ $(ARCH_LIBS) $(SDL_LIBS) \ - -lm $(ARCH_LINKS) + -lm $(ARCH_LINKS) $(LIBS) @$(RSRC_CMD) @$(MIMESET_CMD)