mirror of
https://github.com/OISF/suricata.git
synced 2026-10-11 22:09:53 +00:00
libsuricata-config: fix static library dependency order
When static linking we have a circular dependency between libsuricata_rust, and libsuricata_c, so we have to list each twice. An alternative is to use "-Wl,--start-group", but that isn't portable outside the GNU toolchain.
This commit is contained in:
@@ -6,8 +6,12 @@ includedir="@includedir@"
|
||||
libdir="@libdir@"
|
||||
LIBS="@LIBS@ @RUST_LDADD@"
|
||||
|
||||
# Shared library to link to (the default).
|
||||
shared_lib="-lsuricata"
|
||||
static_lib="-lsuricata_c -lsuricata_rust"
|
||||
|
||||
# Static libraries to link to. We duplicate these as there are
|
||||
# circular references and --start-group is not portable.
|
||||
static_lib="-lsuricata_c -lsuricata_rust -lsuricata_c -lsuricata_rust"
|
||||
|
||||
lib="$shared_lib"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user