source: lib/Makefile.am @ 035f8a7

4.0.1-hotfixescachetimestampsdevelopdpdk-ndagetsilivelibtrace4ndag_formatpfringrc-4.0.1rc-4.0.2rc-4.0.3rc-4.0.4ringdecrementfixringperformanceringtimestampfixes
Last change on this file since 035f8a7 was 035f8a7, checked in by Dan Collins <dan@…>, 6 years ago

Massive refactor that involves moving ring out into its own file.

format_linux is pretty unmaintainable the way it is, so this branch covers
trying to fix that. Ring is basically a subclass of native, so we use OOP
techniques to reduce code duplication. Putting ring in its own file makes
maintaining the code a lot easier as there is less code to read.

The ring format has been spun off, we just need to finish tidying the
native format (stripping out ring, FORMAT(x) turns to FORMAT_DATA etc).
There's bound to be errors in getting it going, but it should be fairly
smooth sailing.

Finally, work was started in moving from the old format design to the
new format design where threaded or not there is a list holding the
per_stream format data.

  • Property mode set to 100644
File size: 2.8 KB
RevLine 
[d8960164]1lib_LTLIBRARIES = libtrace.la
[528eb6e]2include_HEADERS = libtrace.h dagformat.h lt_inttypes.h daglegacy.h rt_protocol.h erftypes.h 
[df6ae1f]3
[e3a639a]4AM_CFLAGS=@LIBCFLAGS@ @CFLAG_VISIBILITY@ -pthread
5AM_CXXFLAGS=@LIBCXXFLAGS@ @CFLAG_VISIBILITY@ -pthread
[f1ab057]6
[3b8a5ef]7extra_DIST = format_template.c
[035f8a7]8NATIVEFORMATS=format_linux_ring.c format_linux.c
[755e794]9BPFFORMATS=format_bpf.c
10
[5e85c23]11if HAVE_DAG
12if DAG2_4
13DAGSOURCE=format_dag24.c
14else
15DAGSOURCE=format_dag25.c
16endif
17else
18DAGSOURCE=
19endif
[e5dedd5]20EXTRA_DIST=format_dag24.c format_dag25.c dpdk_libtrace.mk
[5e85c23]21
[d48008d]22if HAVE_LLVM
[cb39d35]23BPFJITSOURCE=bpf-jit/bpf-jit.cc
[d48008d]24else
25BPFJITSOURCE=
26endif
27
[c04929c]28if HAVE_DPDK
29NATIVEFORMATS+= format_dpdk.c
30# So we also make libtrace.mk in dpdk otherwise automake tries to expand
31# it to early which I cannot seem to stop unless we use a path that
32# doesn't exist currently
33export RTE_SDK=@RTE_SDK@
34export RTE_TARGET=@RTE_TARGET@
[dafe86a]35export SAVED_CFLAGS:=$(CFLAGS)
36export SAVED_CXXFLAGS:=$(CXXFLAGS)
[c04929c]37include $(RTE_SDK)/mk/rte.vars.mk
38# We need to add -Wl before the linker otherwise this breaks our build
[2138553]39# And include any libraries that DPDK might depend upon
40export DPDK_LIBTRACE_MK=dpdk_libtrace.mk
41include $(DPDK_LIBTRACE_MK)
[dafe86a]42export CFLAGS += $(SAVED_CFLAGS)
43export CXXFLAGS += $(SAVED_CXXFLAGS)
[c04929c]44endif
[d48008d]45
[29bbef0]46libtrace_la_SOURCES = trace.c trace_parallel.c common.h \
[a5908d2]47                format_erf.c format_pcap.c format_legacy.c \
[8bf0517]48                format_rt.c format_helper.c format_helper.h format_pcapfile.c \
[e01a738]49                format_duck.c format_tsh.c $(NATIVEFORMATS) $(BPFFORMATS) \
[e1fdc05]50                format_atmhdr.c \
[8b49230]51                libtrace_int.h lt_inttypes.h lt_bswap.h \
52                linktypes.c link_wireless.c byteswap.c \
[c909fad]53                checksum.c checksum.h \
[a81d2fc]54                protocols_pktmeta.c protocols_l2.c protocols_l3.c \
[8753bb8]55                protocols_transport.c protocols.h protocols_ospf.c \
[c66068d]56                $(DAGSOURCE) format_erf.h \
[d48008d]57                $(BPFJITSOURCE) \
[29bbef0]58                libtrace_arphrd.h \
[cb39d35]59                data-struct/ring_buffer.c data-struct/vector.c \
60                data-struct/message_queue.c data-struct/deque.c \
61                data-struct/sliding_window.c data-struct/object_cache.c \
62                data-struct/linked_list.c hash_toeplitz.c combiner_ordered.c \
63                combiner_sorted.c combiner_unordered.c
[8bf0517]64
[df6ae1f]65if DAG2_4
[f6879f3]66nodist_libtrace_la_SOURCES = dagopts.c dagapi.c
[df6ae1f]67endif
68
[bd119b3]69AM_CPPFLAGS= @ADD_INCLS@ -I../libwandio
[2138553]70libtrace_la_LIBADD = @LIBTRACE_LIBS@ @LTLIBOBJS@ $(DPDKLIBS)
[e5f1431]71libtrace_la_LDFLAGS=-version-info @LIBTRACE_MAJOR@:@LIBTRACE_MINOR@:@LIBTRACE_MID@ @ADD_LDFLAGS@
[9daf398]72dagapi.c:
73        cp @DAG_TOOLS_DIR@/dagapi.c .
[df6ae1f]74
[9daf398]75dagopts.c:
76        cp @DAG_TOOLS_DIR@/dagopts.c .
[d48008d]77
78if HAVE_LLVM
79# Rules to build the llvm .cc file from a C description of each opcode.
80bpf-jit/bpf-opcodes.llvm.bc: bpf-jit/bpf-opcodes.c
[7b29593]81        $(LLVM_GCC) -std=c99 -c -O0 -emit-llvm $< -o $@
[d48008d]82
83bpf-jit/bpf-opcodes.llvm.cc: bpf-jit/bpf-opcodes.llvm.bc
[270fb67]84        `$(LLVM_CONFIG) --bindir`/llc -march=cpp -cppgen=module $< -o $@
[d48008d]85
86bpf-jit/bpf-jit.cc: bpf-jit/bpf-opcodes.llvm.cc
87
88EXTRA_DIST+=bpf-jit/bpf-opcodes.c
89BUILT_SOURCES=bpf-jit/bpf-opcodes.llvm.cc
90endif
91CLEANFILES=bpf-jit/bpf-opcodes.llvm.cc bpf-jit/bpf-opcodes.llvm.bc
Note: See TracBrowser for help on using the repository browser.