0

Hello stackoverflow community

I'm attempting to create a recipe for GoAccess from the source. My current recipe looks like this at the moment. I add already the dependency for the project using the provides Distribution Packages list. I think "coreutils popt" and really needed, and they make no sense.

If somebody had a better solution for the cd, then I'll be happy to take it.

SUMMARY = "GoAccess is an open source real-time web log analyzer and interactive viewer that runs in a terminal on *nix systems or through your browser."
HOMEPAGE = "https://goaccess.io"
SECTION = "console/utils"
LICENSE = "MIT"
LIC_FILES_CHKSUM = "file://COPYING;md5=01c937f4a0ce3daba5ca22e80b53d24b"

DEPENDS = "coreutils popt ncurses geoip tokyocabinet gettext-native"

SRC_URI = "https://tar.goaccess.io/goaccess-${PV}.tar.gz"

SRC_URI[md5sum] = "6f4b60f87755a7d1b350badfedda0aa3"
SRC_URI[sha256sum] = "e8fbb9ff852556d72dfd9f1d0134ba075ce5b4c41289902a6f4e0d97c69377be"

S = "${WORKDIR}/goaccess-${PV}"

inherit autotools pkgconfig

do_configure() {
    cd ${S}
    ./configure --enable-utf8 --enable-geoip=legacy --host=${HOST_SYS}
}

do_compile_prepend() {
    cd ${S}
}

I get an error that the so file ld-linux-armhf.so.3 is missing. To which dependency this so file belongs? How can I add it to the build process?

ERROR: goaccess-1.4-r0 do_compile: oe_runmake failed
ERROR: goaccess-1.4-r0 do_compile: Execution of '/home/path/build/tmp-glibc/work/arm1176jzfshf-vfp-oe-linux-gnueabi/goaccess/1.4-r0/temp/run.do_compile.15001' failed with exit code 1:
cat ./resources/tpls.html | sed "s/^[[:space:]]*//" | sed "/^$/d" | tr -d "\r\n" > resources/tpls.html.tmp
cat ./resources/css/bootstrap.min.css | sed "s/^[[:space:]]*//" | sed "/^$/d" | tr -d "\r\n" > ./resources/css/bootstrap.min.css.tmp
cat ./resources/css/fa.min.css | sed "s/^[[:space:]]*//" | sed "/^$/d" | tr -d "\r\n" > ./resources/css/fa.min.css.tmp
cat ./resources/css/app.css | sed "s/^[[:space:]]*//" | sed "/^$/d" | tr -d "\r\n" > ./resources/css/app.css.tmp
cat ./resources/js/d3.v3.min.js | sed "s/^[[:space:]]*//" | sed "/^$/d" | tr -d "\r\n" > ./resources/js/d3.v3.min.js.tmp
./bin2c ./resources/css/app.css.tmp src/appcss.h app_css
./bin2c resources/tpls.html.tmp src/tpls.h tpls
./bin2c ./resources/css/fa.min.css.tmp src/facss.h fa_css
./bin2c ./resources/js/d3.v3.min.js.tmp src/d3js.h d3_js
/lib/ld-linux-armhf.so.3: No such file or directory
./bin2c ./resources/css/bootstrap.min.css.tmp src/bootstrapcss.h bootstrap_css
Makefile:1326: recipe for target 'src/appcss.h' failed
make: *** [src/appcss.h] Error 255
make: *** Waiting for unfinished jobs....
/lib/ld-linux-armhf.so.3: No such file or directory
Makefile:1321: recipe for target 'src/facss.h' failed
make: *** [src/facss.h] Error 255
/lib/ld-linux-armhf.so.3: No such file or directory
Makefile:1331: recipe for target 'src/d3js.h' failed
make: *** [src/d3js.h] Error 255
/lib/ld-linux-armhf.so.3: No such file or directory
Makefile:1311: recipe for target 'src/tpls.h' failed
make: *** [src/tpls.h] Error 255
/lib/ld-linux-armhf.so.3: No such file or directory
Makefile:1316: recipe for target 'src/bootstrapcss.h' failed
make: *** [src/bootstrapcss.h] Error 255
WARNING: exit code 1 from a shell command.

ERROR: Logfile of failure stored in: /home/path/build/tmp-glibc/work/arm1176jzfshf-vfp-oe-linux-gnueabi/goaccess/1.4-r0/temp/log.do_compile.15001
Log data follows:
| DEBUG: Executing python function autotools_aclocals
| DEBUG: SITE files ['endian-little', 'bit-32', 'arm-common', 'arm-32', 'common-linux', 'common-glibc', 'arm-linux', 'arm-linux-gnueabi', 'common']
| DEBUG: Python function autotools_aclocals finished
| DEBUG: Executing shell function do_compile
| NOTE: make -j 5
| cat ./resources/tpls.html | sed "s/^[[:space:]]*//" | sed "/^$/d" | tr -d "\r\n" > resources/tpls.html.tmp
| cat ./resources/css/bootstrap.min.css | sed "s/^[[:space:]]*//" | sed "/^$/d" | tr -d "\r\n" > ./resources/css/bootstrap.min.css.tmp
| cat ./resources/css/fa.min.css | sed "s/^[[:space:]]*//" | sed "/^$/d" | tr -d "\r\n" > ./resources/css/fa.min.css.tmp
| cat ./resources/css/app.css | sed "s/^[[:space:]]*//" | sed "/^$/d" | tr -d "\r\n" > ./resources/css/app.css.tmp
| cat ./resources/js/d3.v3.min.js | sed "s/^[[:space:]]*//" | sed "/^$/d" | tr -d "\r\n" > ./resources/js/d3.v3.min.js.tmp
| ./bin2c ./resources/css/app.css.tmp src/appcss.h app_css
| ./bin2c resources/tpls.html.tmp src/tpls.h tpls
| ./bin2c ./resources/css/fa.min.css.tmp src/facss.h fa_css
| ./bin2c ./resources/js/d3.v3.min.js.tmp src/d3js.h d3_js
| /lib/ld-linux-armhf.so.3: No such file or directory
| ./bin2c ./resources/css/bootstrap.min.css.tmp src/bootstrapcss.h bootstrap_css
| Makefile:1326: recipe for target 'src/appcss.h' failed
| make: *** [src/appcss.h] Error 255
| make: *** Waiting for unfinished jobs....
| /lib/ld-linux-armhf.so.3: No such file or directory
| Makefile:1321: recipe for target 'src/facss.h' failed
| make: *** [src/facss.h] Error 255
| /lib/ld-linux-armhf.so.3: No such file or directory
| Makefile:1331: recipe for target 'src/d3js.h' failed
| make: *** [src/d3js.h] Error 255
| /lib/ld-linux-armhf.so.3: No such file or directory
| Makefile:1311: recipe for target 'src/tpls.h' failed
| make: *** [src/tpls.h] Error 255
| /lib/ld-linux-armhf.so.3: No such file or directory
| Makefile:1316: recipe for target 'src/bootstrapcss.h' failed
| make: *** [src/bootstrapcss.h] Error 255
| ERROR: oe_runmake failed
| WARNING: exit code 1 from a shell command.
| ERROR: Execution of '/home/path/build/tmp-glibc/work/arm1176jzfshf-vfp-oe-linux-gnueabi/goaccess/1.4-r0/temp/run.do_compile.15001' failed with exit code 1:
| cat ./resources/tpls.html | sed "s/^[[:space:]]*//" | sed "/^$/d" | tr -d "\r\n" > resources/tpls.html.tmp
| cat ./resources/css/bootstrap.min.css | sed "s/^[[:space:]]*//" | sed "/^$/d" | tr -d "\r\n" > ./resources/css/bootstrap.min.css.tmp
| cat ./resources/css/fa.min.css | sed "s/^[[:space:]]*//" | sed "/^$/d" | tr -d "\r\n" > ./resources/css/fa.min.css.tmp
| cat ./resources/css/app.css | sed "s/^[[:space:]]*//" | sed "/^$/d" | tr -d "\r\n" > ./resources/css/app.css.tmp
| cat ./resources/js/d3.v3.min.js | sed "s/^[[:space:]]*//" | sed "/^$/d" | tr -d "\r\n" > ./resources/js/d3.v3.min.js.tmp
| ./bin2c ./resources/css/app.css.tmp src/appcss.h app_css
| ./bin2c resources/tpls.html.tmp src/tpls.h tpls
| ./bin2c ./resources/css/fa.min.css.tmp src/facss.h fa_css
| ./bin2c ./resources/js/d3.v3.min.js.tmp src/d3js.h d3_js
| /lib/ld-linux-armhf.so.3: No such file or directory
| ./bin2c ./resources/css/bootstrap.min.css.tmp src/bootstrapcss.h bootstrap_css
| Makefile:1326: recipe for target 'src/appcss.h' failed
| make: *** [src/appcss.h] Error 255
| make: *** Waiting for unfinished jobs....
| /lib/ld-linux-armhf.so.3: No such file or directory
| Makefile:1321: recipe for target 'src/facss.h' failed
| make: *** [src/facss.h] Error 255
| /lib/ld-linux-armhf.so.3: No such file or directory
| Makefile:1331: recipe for target 'src/d3js.h' failed
| make: *** [src/d3js.h] Error 255
| /lib/ld-linux-armhf.so.3: No such file or directory
| Makefile:1311: recipe for target 'src/tpls.h' failed
| make: *** [src/tpls.h] Error 255
| /lib/ld-linux-armhf.so.3: No such file or directory
| Makefile:1316: recipe for target 'src/bootstrapcss.h' failed
| make: *** [src/bootstrapcss.h] Error 255
| WARNING: exit code 1 from a shell command.

Thanks for helping.

1 Answers1

2

Well your recipe inherits the autotools.bbclass which calls ${S}/configure with all these variables and other things as well.

CONFIGUREOPTS = " --build=${BUILD_SYS} \
      --host=${HOST_SYS} \
      --target=${TARGET_SYS} \
      --prefix=${prefix} \
      --exec_prefix=${exec_prefix} \
      --bindir=${bindir} \
      --sbindir=${sbindir} \
      --libexecdir=${libexecdir} \
      --datadir=${datadir} \
      --sysconfdir=${sysconfdir} \
      --sharedstatedir=${sharedstatedir} \
      --localstatedir=${localstatedir} \
      --libdir=${libdir} \
      --includedir=${includedir} \
      --oldincludedir=${oldincludedir} \
      --infodir=${infodir} \
      --mandir=${mandir} \
      --disable-silent-rules \
      ${CONFIGUREOPT_DEPTRACK} \
      ${@append_libtool_sysroot(d)}"

You override this default behaviour by providing your own incomplete do_configure() task. Don't do this! If you need to provide extra options use the EXTRA_OECONF variable.

EXTRA_OECONF += "--enable-utf8 --enable-geoip=legacy"

This should be the complete recipe needed.

SUMMARY = "GoAccess is an open source real-time web log analyzer and interactive viewer that runs in a terminal on *nix systems or through your browser."
HOMEPAGE = "https://goaccess.io"
SECTION = "console/utils"
LICENSE = "MIT"
LIC_FILES_CHKSUM = "file://COPYING;md5=01c937f4a0ce3daba5ca22e80b53d24b"

DEPENDS = "coreutils popt ncurses geoip tokyocabinet gettext-native"

SRC_URI = "https://tar.goaccess.io/goaccess-${PV}.tar.gz"

SRC_URI[md5sum] = "6f4b60f87755a7d1b350badfedda0aa3"
SRC_URI[sha256sum] = "e8fbb9ff852556d72dfd9f1d0134ba075ce5b4c41289902a6f4e0d97c69377be"

S = "${WORKDIR}/goaccess-${PV}"

inherit autotools

EXTRA_OECONF += "--enable-utf8 --enable-geoip=legacy"
Markus Fuchs
  • 172
  • 9
  • Thanks for your feedback, but unfortunately the issue is the same. Do you have an idea what 'ld-linux-armhf.so.3' is? – martinklaus Aug 10 '20 at 09:58
  • I checked the goaccess source. The compilation process has multiple stages: 1. the bin2c program is built 2. the bin2c program is used to build header files. 3. the goaccess program is built using these header files. The problem is that the bin2c program is also built for arm but you want to run it under amd64 (I guess your build system is amd64) to generate the header files. So i guess you need to build a goaccess-native version first and use it's bin2c program to build the headers in stage two or use pre-generated header files and skip building them. Both involves patching the Makefile. – Markus Fuchs Aug 11 '20 at 19:09