nDPI/utils/Makefile.in
Ivan Nardi b2357c29c3
Build system: Standardize and improve clean/distclean targets (#3039)
This commit improves the nDPI build system by standardizing cleanup
targets, improving portability, and ensuring complete removal of
generated files during `make distclean`.

Changes:

1. Standardize clean targets (replace /bin/rm with portable $(RM))

2. Add distclean-local targets for complete cleanup

3. Add missing clean/distclean targets

4. Remove obsolete commented-out curl detection code

5. fuzz/Makefile.am: Fix out-of-tree build compatibility by replacing hardcoded
   relative paths (../example/fuzz_*.o) with proper $(top_builddir) variables.
   Add distclean-local target.
2025-11-24 18:42:03 +01:00

23 lines
637 B
Makefile

# Support for out-of-tree builds (VPATH)
srcdir = @srcdir@
top_srcdir = @top_srcdir@
top_builddir = @top_builddir@
VPATH = @srcdir@
INC=-I$(top_srcdir)/src/include -I$(top_builddir)/src/include
LIBNDPI=$(top_builddir)/src/lib/libndpi.a
LIBS=$(LIBNDPI) @PCAP_LIB@ @ADDITIONAL_LIBS@ @LIBS@ @GPROF_LIBS@
all: hosts2domains print_rank
hosts2domains: $(srcdir)/hosts2domains.c Makefile
$(CC) $(INC) -g $(srcdir)/hosts2domains.c -o hosts2domains $(LIBS)
print_rank: $(srcdir)/print_rank.c Makefile
$(CC) $(INC) -g $(srcdir)/print_rank.c -o print_rank $(LIBS)
clean:
$(RM) hosts2domains print_rank *.o
distclean: clean
$(RM) Makefile