OpenWrt/LEDE Project

  • Status Closed
  • Percent Complete
    100%
  • Task Type Build Failure
  • Category Base system
  • Assigned To No-one
  • Operating System All
  • Severity Low
  • Priority Very Low
  • Reported Version openwrt-19.07
  • Due in Version Undecided
  • Due Date Undecided
  • Private
Attached to Project: OpenWrt/LEDE Project
Opened by hanabana - 15.04.2020
Last edited by Petr Štetiar - 25.04.2020

FS#3010 - Error building libpcap with very high number of simultaneous jobs

Building libpcap with high number of simultaneous jobs fails on compiling

make V=sc -j64 package/libs/libpcap/compile
aarch64-openwrt-linux-musl-gcc -fPIC -Os -pipe -mcpu=cortex-a53 -fno-caller-saves -fno-plt -fhonour-copts -Wno-error=unused-but-set-variable -Wno-error=unused-result -iremap/work/openwrt/build_dir/target-aarch64_cortex-a53_musl/libpcap-1.9.1:libpcap-1.9.1 -Wformat -Werror=format-security -fstack-protector -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -ffunction-sections -fdata-sections -I/work/openwrt/build_dir/target-aarch64_cortex-a53_musl/linux/include  -fpic -I.  -DBUILDING_PCAP -D_BSD_SOURCE -Dpcap_EXPORTS -DHAVE_CONFIG_H  -Os -pipe -mcpu=cortex-a53 -fno-caller-saves -fno-plt -fhonour-copts -Wno-error=unused-but-set-variable -Wno-error=unused-result -iremap/work/openwrt/build_dir/target-aarch64_cortex-a53_musl/libpcap-1.9.1:libpcap-1.9.1 -Wformat -Werror=format-security -fstack-protector -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -ffunction-sections -fdata-sections      -c -o pcap_pic.o ./pcap.c
aarch64-openwrt-linux-musl-gcc -fPIC -Os -pipe -mcpu=cortex-a53 -fno-caller-saves -fno-plt -fhonour-copts -Wno-error=unused-but-set-variable -Wno-error=unused-result -iremap/work/openwrt/build_dir/target-aarch64_cortex-a53_musl/libpcap-1.9.1:libpcap-1.9.1 -Wformat -Werror=format-security -fstack-protector -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -ffunction-sections -fdata-sections -I/work/openwrt/build_dir/target-aarch64_cortex-a53_musl/linux/include  -fpic -I.  -DBUILDING_PCAP -D_BSD_SOURCE -Dpcap_EXPORTS -DHAVE_CONFIG_H  -Os -pipe -mcpu=cortex-a53 -fno-caller-saves -fno-plt -fhonour-copts -Wno-error=unused-but-set-variable -Wno-error=unused-result -iremap/work/openwrt/build_dir/target-aarch64_cortex-a53_musl/libpcap-1.9.1:libpcap-1.9.1 -Wformat -Werror=format-security -fstack-protector -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -ffunction-sections -fdata-sections      -c -o gencode_pic.o ./gencode.c
aarch64-openwrt-linux-musl-gcc -fPIC -Os -pipe -mcpu=cortex-a53 -fno-caller-saves -fno-plt -fhonour-copts -Wno-error=unused-but-set-variable -Wno-error=unused-result -iremap/work/openwrt/build_dir/target-aarch64_cortex-a53_musl/libpcap-1.9.1:libpcap-1.9.1 -Wformat -Werror=format-security -fstack-protector -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -ffunction-sections -fdata-sections -I/work/openwrt/build_dir/target-aarch64_cortex-a53_musl/linux/include  -fpic -I.  -DBUILDING_PCAP -D_BSD_SOURCE -Dpcap_EXPORTS -DHAVE_CONFIG_H  -Os -pipe -mcpu=cortex-a53 -fno-caller-saves -fno-plt -fhonour-copts -Wno-error=unused-but-set-variable -Wno-error=unused-result -iremap/work/openwrt/build_dir/target-aarch64_cortex-a53_musl/libpcap-1.9.1:libpcap-1.9.1 -Wformat -Werror=format-security -fstack-protector -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -ffunction-sections -fdata-sections      -c -o optimize_pic.o ./optimize.c
..........
..........
ck-protector -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -ffunction-sections -fdata-sections      -c -o pcap-common_pic.o ./pcap-common.c
In file included from ./fmtutils.c:42:0:
./ftmacros.h:106:0: warning: "_BSD_SOURCE" redefined
   #define _BSD_SOURCE
 
<command-line>:0:0: note: this is the location of the previous definition
./gencode.c:67:10: fatal error: grammar.h: No such file or directory
 #include "grammar.h"
          ^~~~~~~~~~~
compilation terminated.
Makefile:99: recipe for target 'gencode_pic.o' failed
make[3]: *** [gencode_pic.o] Error 1
make[3]: *** Waiting for unfinished jobs....
config.status: creating libpcap.pc.tmp
mv libpcap.pc.tmp libpcap.pc
config.status: creating pcap-config.tmp
chmod a+x libpcap.pc
mv pcap-config.tmp pcap-config
chmod a+x pcap-config
grammar.y: warning: fix-its can be applied.  Rerun with option '--update'. [-Wother]
make[3]: Leaving directory '/work/openwrt/build_dir/target-aarch64_cortex-a53_musl/libpcap-1.9.1'
Makefile:102: recipe for target '/work/openwrt/build_dir/target-aarch64_cortex-a53_musl/libpcap-1.9.1/.built' failed
make[2]: *** [/work/openwrt/build_dir/target-aarch64_cortex-a53_musl/libpcap-1.9.1/.built] Error 2
make[2]: Leaving directory '/work/openwrt/package/libs/libpcap'
time: package/libs/libpcap/compile#14.94#3.83#9.07
package/Makefile:111: recipe for target 'package/libs/libpcap/compile' failed
make[1]: *** [package/libs/libpcap/compile] Error 2
make[1]: Leaving directory '/work/openwrt'
Build failed - please re-run with -j1 to see the real error message
/work/openwrt/include/toplevel.mk:225: recipe for target 'package/libs/libpcap/compile' failed
make: *** [package/libs/libpcap/compile] Error 1
work@6980965b0173:~/openwrt$ 

Attached patch solves problem.
Disabling parallel build (by deleting PKG_BUILD_PARALLEL:=1 line) also solves problem.

Closed by  Petr ┼átetiar
25.04.2020 12:05
Reason for closing:  Fixed
Additional comments about closing:  

Fixed in https:/ /git.openwrt.org/6c020577aedd55fea92c90b e5226e0331be9d676

Loading...

Available keyboard shortcuts

Tasklist

Task Details

Task Editing