--- Makefile.org 2003-12-31 14:12:16.000000000 -0800 +++ Makefile 2006-05-03 00:17:35.000000000 -0700 @@ -9,6 +9,9 @@ ## environment GLOBAL_INSTALL_PATH ?= /usr/lib/gkrellm2/plugins USER_INSTALL_PATH ?= $(HOME)/.gkrellm2/plugins +GTK_CONFIG = pkg-config gtk+-2.0 +GTK_INCLUDE = `$(GTK_CONFIG) --cflags` +GTK_LIB = `$(GTK_CONFIG) --libs` ## executables CC = gcc @@ -18,8 +21,8 @@ ## Compiler and Linker flags ## Theoretically, you should not need to change these ## but if the make does not work look into it -CFLAGS = -fPIC -Wall -I. $(shell pkg-config gtk+-2.0 --cflags) -LIBFLAGS = -shared $(shell pkg-config gtk+-2.0 --libs) +CFLAGS += -fPIC -Wall -I. $(GTK_INCLUDE) +LIBFLAGS += -bundle -undefined suppress -flat_namespace ## Set all the locale converstion stuff ## if necessary @@ -72,14 +75,10 @@ chmod 755 $@ install: $(TARGET) install_trans - @strip -s $(TARGET) - @if [ -d $(GLOBAL_INSTALL_PATH) -a -w $(GLOBAL_INSTALL_PATH) ]; then \ - echo "Installing to global location: $(GLOBAL_INSTALL_PATH)"; \ - install -m 644 $(TARGET) $(GLOBAL_INSTALL_PATH)/$(TARGET); \ - else \ - echo "Installing to user location: $(USER_INSTALL_PATH)"; \ - install -D -m 644 $(TARGET) $(USER_INSTALL_PATH)/$(TARGET); \ - fi + @strip -x $(TARGET) + echo "Installing to global location: $(GLOBAL_INSTALL_PATH)"; \ + install -d -m 644 $(DESTDIR)$(GLOBAL_INSTALL_PATH); \ + install -m 644 $(TARGET) $(DESTDIR)$(GLOBAL_INSTALL_PATH)/$(TARGET); \ install_trans: ifeq ($(enable_nls),1)