Snort mailing list archives

Re: Snort3 fails to build for armv7 hardware


From: "Michael Altizer \(mialtize\) via Snort-devel" <snort-devel () lists snort org>
Date: Wed, 24 Jul 2019 01:25:29 +0000

Cool.  That should make its way into a GitHub push in the near future.

On 7/23/19 11:44 AM, Bill - Google Account wrote:
The supplied patch along with a small change in the port Makefile solved the issue on ARM hardware.  Thanks for the 
quick response.

Bill Meeks
Vidalia, GA USA

From: Bill - Google Account <billmeeks8 () gmail com><mailto:billmeeks8 () gmail com>
Sent: Tuesday, July 23, 2019 8:53 AM
To: 'Michael Altizer (mialtize)' <mialtize () cisco com><mailto:mialtize () cisco com>; Snort-devel () lists snort 
org<mailto:Snort-devel () lists snort org>
Subject: RE: [Snort-devel] Snort3 fails to build for armv7 hardware

Thanks Michael.  I’ve forwarded the patch and instructions to the pfSense team for them to try on native ARM hardware.  
I will let you know if it works.

Bill Meeks
Vidalia, GA USA

From: Michael Altizer (mialtize) <mialtize () cisco com<mailto:mialtize () cisco com>>
Sent: Tuesday, July 23, 2019 12:30 AM
To: Bill - Google Account <billmeeks8 () gmail com<mailto:billmeeks8 () gmail com>>; Snort-devel () lists snort 
org<mailto:Snort-devel () lists snort org>
Subject: Re: [Snort-devel] Snort3 fails to build for armv7 hardware

On 7/22/19 6:17 PM, Bill - Google Account via Snort-devel wrote:
Hi:

I maintain the Snort package for the pfSense firewall distribution.  I am currently working on a Snort3 package for 
pfSense.  To that end the pfSense developers have recently enabled the build of the Snort3 binary on their image 
builders.  pfSense is based on FreeBSD and is available for both AMD64 and ARMv7 architectures.  Snort3-3.0.0-255 is 
currently failing to build for ARMv7 images on FreeBSD 12.  The relevant parts of the build failure log are as follows:


/nxb-bin/usr/bin/c++  -DHAVE_CONFIG_H -Dinline=inline -Drestrict=__restrict 
-I/wrkdirs/usr/ports/security/snort3/work/snort3-3.0.0-255/src/network_inspectors

-I/wrkdirs/usr/ports/security/snort3/work/snort3-3.0.0-255/src

-I/usr/local/include/luajit-2.1 -I.

-I/wrkdirs/usr/ports/security/snort3/work/snort3-3.0.0-255

-I/usr/local/include -O2 -pipe -DLIBICONV_PLUG -fno-strict-aliasing

-DLIBICONV_PLUG  -fvisibility=hidden   -DNDEBUG    -O2 -pipe

-DLIBICONV_PLUG -fno-strict-aliasing  -DLIBICONV_PLUG   -std=c++11 -MD

-MT src/time/CMakeFiles/time.dir/tsc_clock.cc.o -MF src/time/CMakeFiles/time.dir/tsc_clock.cc.o.d -o 
src/time/CMakeFiles/time.dir/tsc_clock.cc.o -c 
/wrkdirs/usr/ports/security/snort3/work/snort3-3.0.0-255/src/time/tsc_clock.cc

In file included from

/wrkdirs/usr/ports/security/snort3/work/snort3-3.0.0-255/src/time/tsc_clock.cc:24:

/wrkdirs/usr/ports/security/snort3/work/snort3-3.0.0-255/src/time/tsc_clock.h:55:32:

error: invalid output constraint '=a' in asm

        asm volatile("rdtsc" : "=a" (lo), "=d" (hi));

                               ^

1 error generated.

This error occurs on a stock FreeBSD 12.0 installation and is not specific to pfSense.  Could someone from the Snort3 
team please take a look?

Thanks,

Bill Meeks
Vidalia, GA USA



Try the attached patch.  Make sure you're building without --enable-tsc-clock.

_______________________________________________
Snort-devel mailing list
Snort-devel () lists snort org
https://lists.snort.org/mailman/listinfo/snort-devel

Please visit http://blog.snort.org for the latest news about Snort!

Current thread: