summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSamuli Suominen <ssuominen@gentoo.org>2009-04-29 06:50:47 +0000
committerSamuli Suominen <ssuominen@gentoo.org>2009-04-29 06:50:47 +0000
commitfe58bf2818132439161f971ae9c37c316b6637d9 (patch)
treecdae36bd3b9c5f3c40d9b0c5db692c03cd6cb93c /net-analyzer/nethogs/files
parent29 Apr 2009; Zac Medico <zmedico@gentoo.org> calibre-0.5.9-r1.ebuild: (diff)
downloadgentoo-2-fe58bf2818132439161f971ae9c37c316b6637d9.tar.gz
gentoo-2-fe58bf2818132439161f971ae9c37c316b6637d9.tar.bz2
gentoo-2-fe58bf2818132439161f971ae9c37c316b6637d9.zip
Version bump.
(Portage version: 2.1.6.11/cvs/Linux x86_64)
Diffstat (limited to 'net-analyzer/nethogs/files')
-rw-r--r--net-analyzer/nethogs/files/nethogs-0.6.0-gcc34.diff34
-rw-r--r--net-analyzer/nethogs/files/nethogs-0.7.0-Makefile.patch83
2 files changed, 83 insertions, 34 deletions
diff --git a/net-analyzer/nethogs/files/nethogs-0.6.0-gcc34.diff b/net-analyzer/nethogs/files/nethogs-0.6.0-gcc34.diff
deleted file mode 100644
index c85fb464010b..000000000000
--- a/net-analyzer/nethogs/files/nethogs-0.6.0-gcc34.diff
+++ /dev/null
@@ -1,34 +0,0 @@
---- decpcap.c~ 2005-04-04 01:53:06.000000000 -0300
-+++ decpcap.c 2005-04-04 01:56:13.000000000 -0300
-@@ -76,6 +76,7 @@
- break;
- default:
- // TODO
-+ break;
- }
- }
-
-@@ -98,6 +99,7 @@
- break;
- default:
- // TODO
-+ break;
- }
- }
-
-@@ -128,6 +130,7 @@
- break;
- default:
- // TODO
-+ break;
- }
- }
-
-@@ -173,6 +176,7 @@
- break;
- default:
- // TODO
-+ break;
- }
- }
-
diff --git a/net-analyzer/nethogs/files/nethogs-0.7.0-Makefile.patch b/net-analyzer/nethogs/files/nethogs-0.7.0-Makefile.patch
new file mode 100644
index 000000000000..5a3285a1cf9a
--- /dev/null
+++ b/net-analyzer/nethogs/files/nethogs-0.7.0-Makefile.patch
@@ -0,0 +1,83 @@
+Replace CFLAGS for CXX target with CXXFLAGS. Add LDFLAGS to respect them.
+Use DESTDIR correctly, and fix typing error of sbin. - ssuominen@gentoo.org
+
+diff -ur nethogs.orig/Makefile nethogs/Makefile
+--- nethogs.orig/Makefile 2009-03-12 23:08:17.000000000 +0000
++++ nethogs/Makefile 2009-04-29 09:41:11.000000000 +0000
+@@ -2,17 +2,17 @@
+ SUBVERSION := 7
+ MINORVERSION := 0
+
+-#DESTDIR := /usr
+-DESTDIR := /usr/local
+-
+-sbin := $(DESTDIR)/sbin
+-man8 := $(DESTDIR)/share/man/man8/
++prefix := /usr
++# prefix := /usr/local
++sbin := $(prefix)/sbin
++man8 := $(prefix)/share/man/man8
+
+ all: nethogs decpcap_test
+ # nethogs_testsum
+
+-CFLAGS=-g -Wall -Wextra
+-#CFLAGS=-O2
++CFLAGS += -Wall
++CXXFLAGS += -Wall
++
+ OBJS=packet.o connection.o process.o refresh.o decpcap.o cui.o inode2prog.o conninode.o
+ .PHONY: tgz
+
+@@ -24,37 +24,37 @@
+ echo "Not implemented"
+
+ install: nethogs nethogs.8
+- install -d -m 755 $(bin)
+- install -m 755 nethogs $(bin)
+- install -d -m 755 $(man8)
+- install -m 644 nethogs.8 $(man8)
++ install -d -m 755 $(DESTDIR)$(sbin)
++ install -m 755 nethogs $(DESTDIR)$(sbin)
++ install -d -m 755 $(DESTDIR)$(man8)
++ install -m 644 nethogs.8 $(DESTDIR)$(man8)
+
+ nethogs: nethogs.cpp $(OBJS)
+- $(CXX) $(CFLAGS) nethogs.cpp $(OBJS) -o nethogs -lpcap -lm -lncurses -DVERSION=\"$(VERSION)\" -DSUBVERSION=\"$(SUBVERSION)\" -DMINORVERSION=\"$(MINORVERSION)\"
++ $(CXX) $(CXXFLAGS) $(LDFLAGS) nethogs.cpp $(OBJS) -o nethogs -lpcap -lm -lncurses -DVERSION=\"$(VERSION)\" -DSUBVERSION=\"$(SUBVERSION)\" -DMINORVERSION=\"$(MINORVERSION)\"
+ nethogs_testsum: nethogs_testsum.cpp $(OBJS)
+- $(CXX) $(CFLAGS) -g nethogs_testsum.cpp $(OBJS) -o nethogs_testsum -lpcap -lm -lncurses -DVERSION=\"$(VERSION)\" -DSUBVERSION=\"$(SUBVERSION)\" -DMINORVERSION=\"$(MINORVERSION)\"
++ $(CXX) $(CXXFLAGS) -g $(LDFLAGS) nethogs_testsum.cpp $(OBJS) -o nethogs_testsum -lpcap -lm -lncurses -DVERSION=\"$(VERSION)\" -DSUBVERSION=\"$(SUBVERSION)\" -DMINORVERSION=\"$(MINORVERSION)\"
+
+ decpcap_test: decpcap_test.cpp decpcap.o
+- $(CXX) $(CFLAGS) decpcap_test.cpp decpcap.o -o decpcap_test -lpcap -lm
++ $(CXX) $(CXXFLAGS) $(LDFLAGS) decpcap_test.cpp decpcap.o -o decpcap_test -lpcap -lm
+
+ #-lefence
+
+ refresh.o: refresh.cpp refresh.h nethogs.h
+- $(CXX) $(CFLAGS) -c refresh.cpp
++ $(CXX) $(CXXFLAGS) -c refresh.cpp
+ process.o: process.cpp process.h nethogs.h
+- $(CXX) $(CFLAGS) -c process.cpp
++ $(CXX) $(CXXFLAGS) -c process.cpp
+ packet.o: packet.cpp packet.h nethogs.h
+- $(CXX) $(CFLAGS) -c packet.cpp
++ $(CXX) $(CXXFLAGS) -c packet.cpp
+ connection.o: connection.cpp connection.h nethogs.h
+- $(CXX) $(CFLAGS) -c connection.cpp
++ $(CXX) $(CXXFLAGS) -c connection.cpp
+ decpcap.o: decpcap.c decpcap.h
+ $(CC) $(CFLAGS) -c decpcap.c
+ inode2prog.o: inode2prog.cpp inode2prog.h nethogs.h
+- $(CXX) $(CFLAGS) -c inode2prog.cpp
++ $(CXX) $(CXXFLAGS) -c inode2prog.cpp
+ conninode.o: conninode.cpp nethogs.h conninode.h
+- $(CXX) $(CFLAGS) -c conninode.cpp
++ $(CXX) $(CXXFLAGS) -c conninode.cpp
+ cui.o: cui.cpp cui.h nethogs.h
+- $(CXX) $(CFLAGS) -c cui.cpp -DVERSION=\"$(VERSION)\" -DSUBVERSION=\"$(SUBVERSION)\" -DMINORVERSION=\"$(MINORVERSION)\"
++ $(CXX) $(CXXFLAGS) -c cui.cpp -DVERSION=\"$(VERSION)\" -DSUBVERSION=\"$(SUBVERSION)\" -DMINORVERSION=\"$(MINORVERSION)\"
+
+ .PHONY: clean
+ clean: