Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
emulab
emulab-devel
Commits
978c891a
Commit
978c891a
authored
Oct 12, 2007
by
Mike Hibler
Browse files
Different way of determining if pcap_breakloop exists
parent
840c68f2
Changes
1
Hide whitespace changes
Inline
Side-by-side
tools/pcapper/GNUmakefile.in
View file @
978c891a
...
...
@@ -9,7 +9,6 @@ TESTBED_SRCDIR = @top_srcdir@
OBJDIR = ../..
SUBDIR = tools/pcapper
SYSTEM := $(shell uname -s)
RHLVERSION := $(shell cat /etc/redhat-release | sed -e 's/Red Hat Linux release \([0-9]\).*/Linux\1/' | sed -e 's/Fedora Core release \([0-9]\).*/FC\1/')
include $(OBJDIR)/Makeconf
...
...
@@ -39,18 +38,31 @@ LDFLAGS = $(LDSTATIC)
CFLAGS_FBSD = $(CFLAGS) $(TBCFLAGS)
CFLAGS_FBSD_NE = $(CFLAGS)
CFLAGS_LINUX = $(CFLAGS) -I/usr/include/pcap $(TBCFLAGS)
ifneq (,$(findstring FC, $(RHLVERSION)))
# XXX should be configed
CFLAGS_LINUX += -DHAVE_PCAP_BREAKLOOP
endif
LIBS_FBSD = $(PTHREADLIBS) $(TBLIBS) $(PCAPLIBS)
LIBS_FBSD_NE = $(PTHREADLIBS) $(PCAPLIBS)
LIBS_LINUX = -L/usr/lib -lpthread -lpcap $(TBLIBS) -ldl -lz
#
# XXX dynamically-determined Linux stuff, only do on Linux
#
ifeq ($(SYSTEM),Linux)
ifneq ($(wildcard /usr/lib/libpcap.a),)
NOPBL := $(shell nm /usr/lib/libpcap.a | grep -q pcap_breakloop; echo $$?)
else
NOPBL := 1
endif
ifeq ($(NOPBL),0)
CFLAGS_LINUX += -DHAVE_PCAP_BREAKLOOP
endif
ifneq ($(wildcard /usr/kerberos/bin/krb5-config),)
LIBS_LINUX = -L/usr/lib -lpthread -lpcap $(TBLIBS) \
`/usr/kerberos/bin/krb5-config --libs krb5` -ldl -lz
ifneq ($(wildcard /usr/lib/libkrb5support.a),)
LIBS_LINUX += -lkrb5support
endif
endif
endif
# virtual (encapsulated) ethernet
#CFLAGS_FBSD += -DVETH
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment