ports/palm/malsync/files/patch-aa
Dirk Froemberg f3e4528617 Fix build after movement of pilot-link's library.
PR:		ports/34191
Submitted by:	Steve Wills <steve@stevenwills.com>
2002-02-14 22:00:05 +00:00

48 lines
1 KiB
Text

--- Makefile.orig Sun May 14 21:17:35 2000
+++ Makefile Mon Feb 11 19:30:47 2002
@@ -1,4 +1,3 @@
-CC = gcc
TARGET = malsync
PLAT := $(shell uname)
@@ -12,10 +11,16 @@
endif
TREETOP = ../../..
-PILOT_LINK_DIR = $(TREETOP)/vendor/pilot/pilot-link.0.9.3
+PILOT_LINK_DIR = $(PREFIX)/pilot
+
+DEFINES = -DMALSYNC
-CFLAGS = -Wall -g -DMALSYNC -I$(TREETOP)/mal/common \
- -I$(TREETOP)/mal/client/common -I$(PILOT_LINK_DIR)/include -I.
+ifeq ($(PLAT),FreeBSD)
+LINKFLAGS = -Wl,--rpath -Wl,$(PREFIX)/lib
+endif
+
+CFLAGS += $(DEFINES) -I$(TREETOP)/mal/common \
+ -I$(TREETOP)/mal/client/common -I$(PREFIX)/include -I.
SRC = malsync.c MAL31ServerConfig.c MAL31DBConfig.c MAL31UserConfig.c \
@@ -55,17 +60,12 @@
OBJS = $(SRC:.c=.o)
+all: $(TARGET)
$(TARGET): $(OBJS)
- $(CC) -rdynamic $(CFLAGS) -o $@ $(OBJS) \
- -L${PILOT_LINK_DIR}/libsock -lpisock $(LINKLIBS)
+ $(CC) $(CFLAGS) -o $@ $(OBJS) \
+ -L${PREFIX}/lib -lpisock $(LINKLIBS) $(LINKFLAGS)
+
clean:
rm -f $(OBJS) $(TARGET)
-
-.c.o:
- gcc $(CFLAGS) -c -o $@ $<
-
-
-
-