1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-12-21 04:06:46 +00:00
freebsd-ports/www/suphp/files/patch-src::Makefile.in
Volker Stolz 80e1966e4e - Fix "make -C"-issues
- Unregister from Apache through apxs on deinstall
- Cleanup

PR:		ports/70345
Submitted by:	Jeremy Chadwick (maintainer)
2004-08-12 09:31:51 +00:00

63 lines
2.0 KiB
Plaintext

--- src/Makefile.in.orig Tue Jul 13 02:43:41 2004
+++ src/Makefile.in Wed Aug 11 22:02:44 2004
@@ -28,37 +28,38 @@
INCLUDES = -I$(top_srcdir)/src
RM = rm -f
+SRCS= suphp.c filesystem.c check.c error.c log.c compat.c
+OBJS= ${SRCS:.c=.o}
+
all: suphp suphp.mod
-suphp: suphp.o filesystem.o check.o error.o log.o compat.o
- $(CC) $(LDFLAGS) $(DEFS) -o suphp \
- suphp.o filesystem.o check.o error.o log.o compat.o
+suphp: ${OBJS}
+ $(CC) $(LDFLAGS) $(DEFS) -o suphp ${OBJS}
suphp.mod:
@if test "$(APXS)" != "/notfound/"; then \
if test "$(APACHE_VERSION_2)" = "true"; then \
echo "*** INFO: Building mod_suphp for Apache 2.0 ***"; \
- $(MAKE) $(MAKEDEFS) -C apache2; \
+ cd apache2 && $(MAKE) $(MAKEDEFS); \
fi; \
if test "$(APACHE_VERSION_1_3)" = "true"; then \
echo "*** INFO: Building mod_suphp for Apache 1.3 ***"; \
- $(MAKE) $(MAKEDEFS) -C apache; \
+ cd apache && $(MAKE) $(MAKEDEFS); \
fi; \
else \
echo "*** WARNING: No 'apxs' found. Skipping mod_suphp! ***"; \
fi
install: suphp suphp.mod
- $(INSTALL_PROGRAM) -d $(DESTDIR)$(sbindir)
$(INSTALL_PROGRAM) -m 4755 suphp $(DESTDIR)$(sbindir)/suphp
@if test "$(APXS)" != "/notfound/"; then \
if test "$(APACHE_VERSION_2)" = "true"; then \
echo "*** INFO: Installing mod_suphp for Apache 2.0 ***"; \
- $(MAKE) $(MAKEDEFS) -C apache2 install; \
+ cd apache2 && $(MAKE) $(MAKEDEFS) install; \
fi; \
if test "$(APACHE_VERSION_1_3)" = "true"; then \
echo "*** INFO: Installing mod_suphp for Apache 1.3 ***"; \
- $(MAKE) $(MAKEDEFS) -C apache install; \
+ cd apache && $(MAKE) $(MAKEDEFS) install; \
fi; \
else \
echo "*** WARNING: No 'apxs' found. Skipping installation of mod_suphp! ***"; \
@@ -66,9 +67,9 @@
clean:
$(RM) suphp *.o
- @$(MAKE) $(MAKEDEFS) -C apache clean
- @$(MAKE) $(MAKEDEFS) -C apache2 clean
+ cd apache && $(MAKE) $(MAKEDEFS) clean
+ cd apache2 && $(MAKE) $(MAKEDEFS) clean
-%.o : %.c
+${OBJS}: ${SRCS}
$(CC) -c $(CFLAGS) $(DEFS) $(INCLUDES) -o $@ $<