]> git.ipfire.org Git - thirdparty/sarg.git/commitdiff
Have a more compatible Makefile ?
authorFrédéric Marchal <fmarchal@users.sourceforge.net>
Thu, 27 Jan 2011 19:51:25 +0000 (19:51 +0000)
committerFrédéric Marchal <fmarchal@users.sourceforge.net>
Thu, 27 Jan 2011 19:51:25 +0000 (19:51 +0000)
The patsubst function introduced in sarg 2.3 to avoid the duplicate
file name lists in Makefile.in is a GNU make extension that is not
supported by BSD make. Therefore sarg 2.3 fails to compile on that
system with the default make command.

According to the GNU make documentation, the variable substitution
should be more compatible with other implementations but it isn't
clear whether it is accepted by BSD make or not. Let's try it.

Makefile.in

index ff5370eedf59704cd1f3a93a9a4e4aeb167ca02a..477c9fbd45f8df297568b25a56ee8ce3bd18e437 100644 (file)
@@ -40,7 +40,7 @@ SRCS = util.c log.c report.c topuser.c email.c sort.c html.c \
        dansguardian_log.c dansguardian_report.c realtime.c btree_cache.c \
        usertab.c userinfo.c longline.c
 
-OBJS = $(patsubst %.c,%.o,$(SRCS))
+OBJS = $(SRCS:.c=.o)
 
 DISTFILES = $(SRCS) ABOUT-NLS