When trying to build snapshot (target Rockchip/NanoPi R6S) with luci-app-vnstat2
, sqlite3
is failing to build:
make[3] -C feeds/packages/libs/sqlite3 compile
ERROR: package/feeds/packages/sqlite3 failed to build.
When building with make -j1 V=s
, the error is:
(...)
Build C compiler...cc
Checking for stdlib.h...not found
Error: Compiler does not work. See config.log
Try: 'configure --help' for options
make[3]: *** [Makefile:148: /home/openwrt/openwrt/r6s-router-snapshot-20250611/build_dir/target-aarch64_generic_musl/sqlite-autoconf-3490100/.configured_74ac956b2dc293c2d19aaada12bfc607] Error 1
make[3]: Leaving directory '/home/openwrt/openwrt/r6s-router-snapshot-20250611/feeds/packages/libs/sqlite3'
time: package/feeds/packages/sqlite3/compile#0.24#0.15#0.43
ERROR: package/feeds/packages/sqlite3 failed to build.
Detailed build log
# Some package (base-files) manually append stuff to conffiles
# Append stuff from it and delete the CONTROL directory since everything else should be migrated
if [ -f /home/openwrt/openwrt/r6s-router-snapshot-20250611/build_dir/target-aarch64_generic_musl/luci-lib-jsonc/ipkg-aarch64_generic/luci-lib-jsonc/CONTROL/conffiles ]; then echo $(IDIR_luci-lib-jsonc)/CONTROL/conffiles >> /home/openwrt/openwrt/r6s-router-snapshot-20250611/build_dir/target-aarch64_generic_musl/luci-lib-jsonc/ipkg-aarch64_generic/luci-lib-jsonc/lib/apk/packages/luci-lib-jsonc.conffiles; for file in $(cat /home/openwrt/openwrt/r6s-router-snapshot-20250611/build_dir/target-aarch64_generic_musl/luci-lib-jsonc/ipkg-aarch64_generic/luci-lib-jsonc/CONTROL/conffiles); do [ -f /home/openwrt/openwrt/r6s-router-snapshot-20250611/build_dir/target-aarch64_generic_musl/luci-lib-jsonc/ipkg-aarch64_generic/luci-lib-jsonc/$file ] || continue; csum=$(/home/openwrt/openwrt/r6s-router-snapshot-20250611/staging_dir/host/bin/mkhash sha256 /home/openwrt/openwrt/r6s-router-snapshot-20250611/build_dir/target-aarch64_generic_musl/luci-lib-jsonc/ipkg-aarch64_generic/luci-lib-jsonc/$file); echo $file $csum >> /home/openwrt/openwrt/r6s-router-snapshot-20250611/build_dir/target-aarch64_generic_musl/luci-lib-jsonc/ipkg-aarch64_generic/luci-lib-jsonc/lib/apk/packages/luci-lib-jsonc.conffiles_static; done; rm -rf /home/openwrt/openwrt/r6s-router-snapshot-20250611/build_dir/target-aarch64_generic_musl/luci-lib-jsonc/ipkg-aarch64_generic/luci-lib-jsonc/CONTROL/conffiles; fi
if [ -z "$(ls -A /home/openwrt/openwrt/r6s-router-snapshot-20250611/build_dir/target-aarch64_generic_musl/luci-lib-jsonc/ipkg-aarch64_generic/luci-lib-jsonc/CONTROL 2>/dev/null)" ]; then rm -rf /home/openwrt/openwrt/r6s-router-snapshot-20250611/build_dir/target-aarch64_generic_musl/luci-lib-jsonc/ipkg-aarch64_generic/luci-lib-jsonc/CONTROL; else echo "CONTROL directory /home/openwrt/openwrt/r6s-router-snapshot-20250611/build_dir/target-aarch64_generic_musl/luci-lib-jsonc/ipkg-aarch64_generic/luci-lib-jsonc/CONTROL is not empty! This is not right and should be checked!" >&2; exit 1; fi
/home/openwrt/openwrt/r6s-router-snapshot-20250611/staging_dir/host/bin/fakeroot /home/openwrt/openwrt/r6s-router-snapshot-20250611/staging_dir/host/bin/apk mkpkg --info "name:luci-lib-jsonc" --info "version:25.162.54480~7e4d41e" --info "description:Lua binding for JSON-C" --info "arch:aarch64_generic" --info "license:Apache-2.0" --info "origin:feeds/luci/libs/luci-lib-jsonc" --info "url:https://github.com/openwrt/luci" --info "maintainer:OpenWrt LuCI community" --info "provides:" --script "post-install:/home/openwrt/openwrt/r6s-router-snapshot-20250611/build_dir/target-aarch64_generic_musl/luci-lib-jsonc/apk-aarch64_generic/luci-lib-jsonc/post-install" --script "pre-deinstall:/home/openwrt/openwrt/r6s-router-snapshot-20250611/build_dir/target-aarch64_generic_musl/luci-lib-jsonc/apk-aarch64_generic/luci-lib-jsonc/pre-deinstall" --info "depends:libc liblua5.1.5 libjson-c5" --files "/home/openwrt/openwrt/r6s-router-snapshot-20250611/build_dir/target-aarch64_generic_musl/luci-lib-jsonc/ipkg-aarch64_generic/luci-lib-jsonc" --output "/home/openwrt/openwrt/r6s-router-snapshot-20250611/bin/packages/aarch64_generic/luci/luci-lib-jsonc-25.162.54480~7e4d41e.apk" --sign "/home/openwrt/openwrt/r6s-router-snapshot-20250611/private-key.pem"
echo "luci-lib-jsonc" >> /home/openwrt/openwrt/r6s-router-snapshot-20250611/staging_dir/target-aarch64_generic_musl/pkginfo/luci-lib-jsonc.default.install
make[3]: Leaving directory '/home/openwrt/openwrt/r6s-router-snapshot-20250611/feeds/luci/libs/luci-lib-jsonc'
time: package/feeds/luci/luci-lib-jsonc/compile#0.50#0.12#0.79
make[3]: Entering directory '/home/openwrt/openwrt/r6s-router-snapshot-20250611/feeds/packages/libs/sqlite3'
touch /home/openwrt/openwrt/r6s-router-snapshot-20250611/build_dir/target-aarch64_generic_musl/sqlite-autoconf-3490100/.prepared_084606e0570147292fbbb0ad5ff0fe2f_6664517399ebbbc92a37c5bb081b5c53_check
. /home/openwrt/openwrt/r6s-router-snapshot-20250611/include/shell.sh; /home/openwrt/openwrt/r6s-router-snapshot-20250611/staging_dir/host/bin/libdeflate-gzip -dc /home/openwrt/openwrt/r6s-router-snapshot-20250611/dl/sqlite-autoconf-3490100.tar.gz | tar -C /home/openwrt/openwrt/r6s-router-snapshot-20250611/build_dir/target-aarch64_generic_musl/sqlite-autoconf-3490100/.. -xf -
[ ! -d ./src/ ] || cp -fpR ./src/. /home/openwrt/openwrt/r6s-router-snapshot-20250611/build_dir/target-aarch64_generic_musl/sqlite-autoconf-3490100
touch /home/openwrt/openwrt/r6s-router-snapshot-20250611/build_dir/target-aarch64_generic_musl/sqlite-autoconf-3490100/.prepared_084606e0570147292fbbb0ad5ff0fe2f_6664517399ebbbc92a37c5bb081b5c53
rm -f /home/openwrt/openwrt/r6s-router-snapshot-20250611/build_dir/target-aarch64_generic_musl/sqlite-autoconf-3490100/.configured_*
rm -f /home/openwrt/openwrt/r6s-router-snapshot-20250611/staging_dir/target-aarch64_generic_musl/stamp/.sqlite3_installed
(cd /home/openwrt/openwrt/r6s-router-snapshot-20250611/build_dir/target-aarch64_generic_musl/sqlite-autoconf-3490100; rm -f aclocal.m4; if [ -f ./configure.ac ] || [ -f ./configure.in ]; then [ -d ./autom4te.cache ] && rm -rf ./autom4te.cache; [ -e ./config.rpath ] || ln -s /home/openwrt/openwrt/r6s-router-snapshot-20250611/scripts/config.rpath ./config.rpath; touch NEWS AUTHORS COPYING ABOUT-NLS ChangeLog; AUTOM4TE=/home/openwrt/openwrt/r6s-router-snapshot-20250611/staging_dir/host/bin/autom4te AUTOCONF=/home/openwrt/openwrt/r6s-router-snapshot-20250611/staging_dir/host/bin/autoconf AUTOMAKE=/home/openwrt/openwrt/r6s-router-snapshot-20250611/staging_dir/host/bin/automake ACLOCAL=/home/openwrt/openwrt/r6s-router-snapshot-20250611/staging_dir/host/bin/aclocal AUTOHEADER=/home/openwrt/openwrt/r6s-router-snapshot-20250611/staging_dir/host/bin/autoheader LIBTOOLIZE=/home/openwrt/openwrt/r6s-router-snapshot-20250611/staging_dir/host/bin/libtoolize LIBTOOL=/home/openwrt/openwrt/r6s-router-snapshot-20250611/staging_dir/host/bin/libtool M4=/home/openwrt/openwrt/r6s-router-snapshot-20250611/staging_dir/host/bin/m4 AUTOPOINT=true GTKDOCIZE=true LIBTOOLIZE='/home/openwrt/openwrt/r6s-router-snapshot-20250611/staging_dir/host/bin/libtoolize --install' /home/openwrt/openwrt/r6s-router-snapshot-20250611/staging_dir/host/bin/autoreconf -v -f -i -B /home/openwrt/openwrt/r6s-router-snapshot-20250611/staging_dir/host/share/aclocal -I /home/openwrt/openwrt/r6s-router-snapshot-20250611/staging_dir/target-aarch64_generic_musl/host/share/aclocal -I /home/openwrt/openwrt/r6s-router-snapshot-20250611/staging_dir/hostpkg/share/aclocal -I /home/openwrt/openwrt/r6s-router-snapshot-20250611/staging_dir/target-aarch64_generic_musl/usr/share/aclocal -I m4 -I . . || true; fi; );
(cd /home/openwrt/openwrt/r6s-router-snapshot-20250611/build_dir/target-aarch64_generic_musl/sqlite-autoconf-3490100/./; if [ -x ./configure ]; then find /home/openwrt/openwrt/r6s-router-snapshot-20250611/build_dir/target-aarch64_generic_musl/sqlite-autoconf-3490100/ -name config.guess | xargs -r chmod u+w; find /home/openwrt/openwrt/r6s-router-snapshot-20250611/build_dir/target-aarch64_generic_musl/sqlite-autoconf-3490100/ -name config.guess | xargs -r -n1 cp --remove-destination /home/openwrt/openwrt/r6s-router-snapshot-20250611/scripts/config.guess; find /home/openwrt/openwrt/r6s-router-snapshot-20250611/build_dir/target-aarch64_generic_musl/sqlite-autoconf-3490100/ -name config.sub | xargs -r chmod u+w; find /home/openwrt/openwrt/r6s-router-snapshot-20250611/build_dir/target-aarch64_generic_musl/sqlite-autoconf-3490100/ -name config.sub | xargs -r -n1 cp --remove-destination /home/openwrt/openwrt/r6s-router-snapshot-20250611/scripts/config.sub; AR="aarch64-openwrt-linux-musl-gcc-ar" AS="aarch64-openwrt-linux-musl-gcc -c -Os -pipe -mcpu=generic -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=/home/openwrt/openwrt/r6s-router-snapshot-20250611/build_dir/target-aarch64_generic_musl/sqlite-autoconf-3490100=sqlite-autoconf-3490100 -Wformat -Werror=format-security -fstack-protector -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -DHAVE_ISNAN -DHAVE_MALLOC_USABLE_SIZE -DSQLITE_ENABLE_UNLOCK_NOTIFY -DSQLITE_ENABLE_COLUMN_METADATA" LD="aarch64-openwrt-linux-musl-ld.bfd" NM="aarch64-openwrt-linux-musl-gcc-nm" CC="aarch64-openwrt-linux-musl-gcc" GCC="aarch64-openwrt-linux-musl-gcc" CXX="aarch64-openwrt-linux-musl-g++" RANLIB="aarch64-openwrt-linux-musl-gcc-ranlib" STRIP=aarch64-openwrt-linux-musl-strip OBJCOPY=aarch64-openwrt-linux-musl-objcopy OBJDUMP=aarch64-openwrt-linux-musl-objdump SIZE=aarch64-openwrt-linux-musl-size CFLAGS="-Os -pipe -mcpu=generic -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=/home/openwrt/openwrt/r6s-router-snapshot-20250611/build_dir/target-aarch64_generic_musl/sqlite-autoconf-3490100=sqlite-autoconf-3490100 -Wformat -Werror=format-security -fstack-protector -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -DHAVE_ISNAN -DHAVE_MALLOC_USABLE_SIZE -DSQLITE_ENABLE_UNLOCK_NOTIFY -DSQLITE_ENABLE_COLUMN_METADATA " CXXFLAGS="-Os -pipe -mcpu=generic -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=/home/openwrt/openwrt/r6s-router-snapshot-20250611/build_dir/target-aarch64_generic_musl/sqlite-autoconf-3490100=sqlite-autoconf-3490100 -Wformat -Werror=format-security -fstack-protector -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -DHAVE_ISNAN -DHAVE_MALLOC_USABLE_SIZE -DSQLITE_ENABLE_UNLOCK_NOTIFY -DSQLITE_ENABLE_COLUMN_METADATA " CPPFLAGS="-I/home/openwrt/openwrt/r6s-router-snapshot-20250611/staging_dir/toolchain-aarch64_generic_gcc-14.3.0_musl/usr/include -I/home/openwrt/openwrt/r6s-router-snapshot-20250611/staging_dir/toolchain-aarch64_generic_gcc-14.3.0_musl/include -I/home/openwrt/openwrt/r6s-router-snapshot-20250611/staging_dir/toolchain-aarch64_generic_gcc-14.3.0_musl/include/fortify " LDFLAGS="-L/home/openwrt/openwrt/r6s-router-snapshot-20250611/staging_dir/toolchain-aarch64_generic_gcc-14.3.0_musl/usr/lib -L/home/openwrt/openwrt/r6s-router-snapshot-20250611/staging_dir/toolchain-aarch64_generic_gcc-14.3.0_musl/lib -fuse-ld=bfd -znow -zrelro " ./configure --host=aarch64-openwrt-linux --build=x86_64-pc-linux-gnu --disable-dependency-tracking --program-prefix="" --program-suffix="" --prefix=/usr --exec-prefix=/usr --bindir=/usr/bin --sbindir=/usr/sbin --libexecdir=/usr/lib --sysconfdir=/etc --datadir=/usr/share --localstatedir=/var --mandir=/usr/man --infodir=/usr/info --disable-debug --disable-static-shell --enable-shared --enable-static --enable-threadsafe --soname=legacy --enable-load-extension --enable-fts3 --enable-fts4 --enable-fts5 --enable-rtree --disable-session --disable-editline --disable-readline ; fi; )
Host System...aarch64-openwrt-linux-gnu
Build System...x86_64-pc-linux-gnu
C compiler...ccache aarch64-openwrt-linux-musl-gcc -Os -pipe -mcpu=generic -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=/home/openwrt/openwrt/r6s-router-snapshot-20250611/build_dir/target-aarch64_generic_musl/sqlite-autoconf-3490100=sqlite-autoconf-3490100 -Wformat -Werror=format-security -fstack-protector -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -DHAVE_ISNAN -DHAVE_MALLOC_USABLE_SIZE -DSQLITE_ENABLE_UNLOCK_NOTIFY -DSQLITE_ENABLE_COLUMN_METADATA -I/home/openwrt/openwrt/r6s-router-snapshot-20250611/staging_dir/toolchain-aarch64_generic_gcc-14.3.0_musl/usr/include -I/home/openwrt/openwrt/r6s-router-snapshot-20250611/staging_dir/toolchain-aarch64_generic_gcc-14.3.0_musl/include -I/home/openwrt/openwrt/r6s-router-snapshot-20250611/staging_dir/toolchain-aarch64_generic_gcc-14.3.0_musl/include/fortify
C++ compiler...ccache aarch64-openwrt-linux-musl-g++ -Os -pipe -mcpu=generic -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=/home/openwrt/openwrt/r6s-router-snapshot-20250611/build_dir/target-aarch64_generic_musl/sqlite-autoconf-3490100=sqlite-autoconf-3490100 -Wformat -Werror=format-security -fstack-protector -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro -DHAVE_ISNAN -DHAVE_MALLOC_USABLE_SIZE -DSQLITE_ENABLE_UNLOCK_NOTIFY -DSQLITE_ENABLE_COLUMN_METADATA -I/home/openwrt/openwrt/r6s-router-snapshot-20250611/staging_dir/toolchain-aarch64_generic_gcc-14.3.0_musl/usr/include -I/home/openwrt/openwrt/r6s-router-snapshot-20250611/staging_dir/toolchain-aarch64_generic_gcc-14.3.0_musl/include -I/home/openwrt/openwrt/r6s-router-snapshot-20250611/staging_dir/toolchain-aarch64_generic_gcc-14.3.0_musl/include/fortify
Build C compiler...cc
Checking for stdlib.h...not found
Error: Compiler does not work. See config.log
Try: 'configure --help' for options
make[3]: *** [Makefile:148: /home/openwrt/openwrt/r6s-router-snapshot-20250611/build_dir/target-aarch64_generic_musl/sqlite-autoconf-3490100/.configured_74ac956b2dc293c2d19aaada12bfc607] Error 1
make[3]: Leaving directory '/home/openwrt/openwrt/r6s-router-snapshot-20250611/feeds/packages/libs/sqlite3'
time: package/feeds/packages/sqlite3/compile#0.24#0.15#0.43
ERROR: package/feeds/packages/sqlite3 failed to build.
make[2]: *** [package/Makefile:183: package/feeds/packages/sqlite3/compile] Error 1
make[2]: Leaving directory '/home/openwrt/openwrt/r6s-router-snapshot-20250611'
make[1]: *** [package/Makefile:177: /home/openwrt/openwrt/r6s-router-snapshot-20250611/staging_dir/target-aarch64_generic_musl/stamp/.package_compile] Error 2
make[1]: Leaving directory '/home/openwrt/openwrt/r6s-router-snapshot-20250611'
make: *** [/home/openwrt/openwrt/r6s-router-snapshot-20250611/include/toplevel.mk:233: world] Error 2
The error Checking for stdlib.h...not found
seems strange, since the build is sucessfull when luci-app-vnstat2
is not selected.
Has anyone seen this issue? Does sqlite3
need to be updated?