Suricata 6.0.0.4: Build failure with --enable-debug

Hi,
I am currently using Suricata 6.0.4 version. i need to build with --enable-debug option to get “SCLogDebug(”“)” messages. when i enable --enable-debug option build failure occurs.

suricata makefile searching for rust/target/debug/libsuricata.a where as it got generated in rust/target/release/libsuricata.a

Error:
make[2]: *** No rule to make target ‘…/rust/target/aarch64-cnos-linux/debug/libsuricata.a’, needed by ‘suricata’. Stop.
Makefile:1965: recipe for target ‘all’ failed
make[1]: *** [all] Error 2

where as libsuricata.a gnerated in directory rust/target/release/
enable-debug option not honored by rust makefile.

First of all, 6.0.10 is out and we highly recommend to use that version.

How do you run the ./configure and make command?

i use yocto bitbake recipe to trigger suricata configure and make

http://layers.openembedded.org/layerindex/recipe/177129/
recipe file: suricata_6.0.6.bb « suricata « recipes-ids - meta-security - Security tools for Internet connected devices

Well I see this custom patch removing rust parts fixup.patch « files « suricata « recipes-ids - meta-security - Security tools for Internet connected devices so in that case I would contact the maintainer of this recipe.

I would recommend trying your own build based on our official release if you want to have debug. Otherwise it’s a bit hard to support customized build like this recipe without more background on yocto.

@Suresh , was this issue resolved for you?
if yes, kindly let me know the solution, I am also facing the same issue in 6.0.4.
I tried to enable --enable-debug option to compile suricata with debug logs.

Please first try to see if the issue still happens in 6.0.16.

@vjulien , Thank you for replying.
Actually we are using 6.0.4 at organization(HPE) level and don’t have any plans to upgrade it.
So I need to try in 6.0.4.
I’m using yocto bitbake recipe to trigger suricata configure and make.
I have made below changes in .bb file to compile suricata with debug logs.
+EXTRA_OECONF += " --enable-debug

Kindly let me know any thing to be taken care additionally to avoid below error.
make[2]: *** No rule to make target ‘…/rust/target/aarch64-cnos-linux/debug/libsuricata.a’, needed by ‘suricata’. Stop.

I’m sorry, but we can’t support such outdated versions.

I would strongly recommend updating to at least 6.0.16 (or 6.0.17 that will be released tomorrow). There are many security issues fixed since 6.0.4

@vjulien , thank you for replying.
Is there any other option alternative to --enable-debug, where I can successfully build suricata ?

The error you post doesn’t look related to --enable-debug, I’d re-look at your build scripts. Sorry, we can’t help with Yocto or other build wrappers. And as mentioned, this is a rather old release and it may be something fixed in a newer release, which might be worth trying as well, if only to see if it works for you.