aboutsummaryrefslogtreecommitdiff
path: root/net/sntop/files/patch-Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'net/sntop/files/patch-Makefile')
-rw-r--r--net/sntop/files/patch-Makefile58
1 files changed, 58 insertions, 0 deletions
diff --git a/net/sntop/files/patch-Makefile b/net/sntop/files/patch-Makefile
new file mode 100644
index 000000000000..de724dd518f8
--- /dev/null
+++ b/net/sntop/files/patch-Makefile
@@ -0,0 +1,58 @@
+--- Makefile.in.orig 2001-11-12 05:54:15.000000000 +0800
++++ Makefile.in 2014-06-10 00:19:16.894102010 +0800
+@@ -36,7 +36,7 @@ DOWENEEDGETOPT = @LIBOBJS@
+ MANDIR = @mandir@/man1
+ SNTOPRC = $(ETCDIR)/sntoprc
+ CC = @CC@
+-CFLAGS = -Wall -Wstrict-prototypes -O2 @DEFS@ -DCONF_SFILE=\"$(SNTOPRC)\"
++CFLAGS+= -Wall -Wstrict-prototypes @DEFS@ -DCONF_SFILE=\"$(SNTOPRC)\"
+
+ proper: clean sntop
+
+@@ -56,34 +56,33 @@ clean:
+ -rm getopt_long.o
+
+ install: sntop
+- @if [ -d $(INSTDIR) ]; \
++ @if [ -d $(DESTDIR)$(INSTDIR) ]; \
+ then \
+- cp sntop $(INSTDIR); \
+- chmod 755 $(INSTDIR)/sntop; \
++ cp sntop $(DESTDIR)$(INSTDIR); \
++ chmod 755 $(DESTDIR)$(INSTDIR)/sntop; \
+ else \
+ echo "sntop: $(INSTDIR) does not exist"; false; \
+ fi
+- @if [ -d $(ETCDIR) ]; \
++ @if [ -d $(DESTDIR)$(ETCDIR) ]; \
+ then \
+- if [ ! -f $(ETCDIR)/sntoprc ]; \
++ if [ ! -f $(DESTDIR)$(ETCDIR)/sntoprc.sample ]; \
+ then \
+- cp sntoprc.EXAMPLE $(ETCDIR)/sntoprc; \
+- chmod 644 $(ETCDIR)/sntoprc; \
++ cp sntoprc.EXAMPLE $(DESTDIR)$(ETCDIR)/sntoprc.sample; \
++ chmod 644 $(DESTDIR)$(ETCDIR)/sntoprc.sample; \
+ fi; \
+- echo "sntop: Sample config exists at $(ETCDIR)/sntoprc"; \
++ echo "sntop: Sample config exists at $(ETCDIR)/sntoprc.sample"; \
+ else \
+ echo "sntop: $(ETCDIR) does not exist"; false; \
+ fi
+- @if [ -d $(MANDIR) ]; \
++ @if [ -d $(DESTDIR)$(MANDIR) ]; \
+ then \
+- cp sntop.1 $(MANDIR); \
+- chmod 644 $(MANDIR)/sntop.1; \
+- gzip -9 $(MANDIR)/sntop.1; \
++ cp sntop.1 $(DESTDIR)$(MANDIR); \
++ chmod 644 $(DESTDIR)$(MANDIR)/sntop.1; \
+ echo "sntop: Man file installed in $(MANDIR)"; \
+ else \
+ echo "sntop: $(MANDIR) does not exist, not installing man file"; \
+ fi
+- @if [ -f $(INSTDIR)/sntop ]; \
++ @if [ -f $(DESTDIR)$(INSTDIR)/sntop ]; \
+ then \
+ echo "sntop: Executable installed in $(INSTDIR)"; \
+ else \