Topics

Building zeek 3.1.1 in Sumo


Gary Huband
 

I'm trying to create a recipe in Sumo for zeek (zeek.org) which uses cmake.  I'm getting a sed not found error:

Initialising tasks: 100% |#######################################################################################################################################################| Time: 0:00:01
NOTE: Executing SetScene Tasks
NOTE: Executing RunQueue Tasks
ERROR: zeek-3.1.1-r0 do_configure: Function failed: do_configure (log file is located at /opt/PHYTEC_BSPs19/yocto_imx7/build-msi1/tmp/work/cortexa7hf-neon-poky-linux-gnueabi/zeek/3.1.1-r0/temp/log.do_configure.18009)
ERROR: Logfile of failure stored in: /opt/PHYTEC_BSPs19/yocto_imx7/build-msi1/tmp/work/cortexa7hf-neon-poky-linux-gnueabi/zeek/3.1.1-r0/temp/log.do_configure.18009
Log data follows:
| DEBUG: Executing shell function do_configure
| -- The C compiler identification is GNU 7.3.0
| -- The CXX compiler identification is GNU 7.3.0
| -- Check for working C compiler: /opt/PHYTEC_BSPs19/yocto_imx7/build-msi1/tmp/work/cortexa7hf-neon-poky-linux-gnueabi/zeek/3.1.1-r0/recipe-sysroot-native/usr/bin/arm-poky-linux-gnueabi/arm-poky-linux-gnueabi-gcc
| -- Check for working C compiler: /opt/PHYTEC_BSPs19/yocto_imx7/build-msi1/tmp/work/cortexa7hf-neon-poky-linux-gnueabi/zeek/3.1.1-r0/recipe-sysroot-native/usr/bin/arm-poky-linux-gnueabi/arm-poky-linux-gnueabi-gcc -- works
| -- Detecting C compiler ABI info
| -- Detecting C compiler ABI info - done
| -- Detecting C compile features
| -- Detecting C compile features - done
| -- Check for working CXX compiler: /opt/PHYTEC_BSPs19/yocto_imx7/build-msi1/tmp/work/cortexa7hf-neon-poky-linux-gnueabi/zeek/3.1.1-r0/recipe-sysroot-native/usr/bin/arm-poky-linux-gnueabi/arm-poky-linux-gnueabi-g++
| -- Check for working CXX compiler: /opt/PHYTEC_BSPs19/yocto_imx7/build-msi1/tmp/work/cortexa7hf-neon-poky-linux-gnueabi/zeek/3.1.1-r0/recipe-sysroot-native/usr/bin/arm-poky-linux-gnueabi/arm-poky-linux-gnueabi-g++ -- works
| -- Detecting CXX compiler ABI info
| -- Detecting CXX compiler ABI info - done
| -- Detecting CXX compile features
| -- Detecting CXX compile features - done
| CMake Error at CMakeLists.txt:170 (message):
|   Could not find required dependency: sed

I tracked this down to the cmake find_program(), here's the lines in CMakeLists.txt:

########################################################################
## Dependency Configuration
 
include(FindRequiredPackage)
 
# Check cache value first to avoid displaying "Found sed" messages everytime
if (NOT SED_EXE)
    find_program(SED_EXE sed)
    if (NOT SED_EXE)
        message(FATAL_ERROR "Could not find required dependency: sed")
    else ()
        message(STATUS "Found sed: ${SED_EXE}")
    endif ()
endif ()

Any ideas how to fix this?


Konrad Weihmann
 

I would say a `DEPENDS += "sed"` in the recipe should fix things - btw sumo is kind of ancient already, ever considered updating to a newer version of poky?

On 18.04.20 18:57, gary@missionsecure.com wrote:
I'm trying to create a recipe in Sumo for zeek (zeek.org) which uses cmake.  I'm getting a sed not found error:
Initialising tasks: 100% |#######################################################################################################################################################| Time: 0:00:01
NOTE: Executing SetScene Tasks
NOTE: Executing RunQueue Tasks
ERROR: zeek-3.1.1-r0 do_configure: Function failed: do_configure (log file is located at /opt/PHYTEC_BSPs19/yocto_imx7/build-msi1/tmp/work/cortexa7hf-neon-poky-linux-gnueabi/zeek/3.1.1-r0/temp/log.do_configure.18009)
ERROR: Logfile of failure stored in: /opt/PHYTEC_BSPs19/yocto_imx7/build-msi1/tmp/work/cortexa7hf-neon-poky-linux-gnueabi/zeek/3.1.1-r0/temp/log.do_configure.18009
Log data follows:
| DEBUG: Executing shell function do_configure
| -- The C compiler identification is GNU 7.3.0
| -- The CXX compiler identification is GNU 7.3.0
| -- Check for working C compiler: /opt/PHYTEC_BSPs19/yocto_imx7/build-msi1/tmp/work/cortexa7hf-neon-poky-linux-gnueabi/zeek/3.1.1-r0/recipe-sysroot-native/usr/bin/arm-poky-linux-gnueabi/arm-poky-linux-gnueabi-gcc
| -- Check for working C compiler: /opt/PHYTEC_BSPs19/yocto_imx7/build-msi1/tmp/work/cortexa7hf-neon-poky-linux-gnueabi/zeek/3.1.1-r0/recipe-sysroot-native/usr/bin/arm-poky-linux-gnueabi/arm-poky-linux-gnueabi-gcc -- works
| -- Detecting C compiler ABI info
| -- Detecting C compiler ABI info - done
| -- Detecting C compile features
| -- Detecting C compile features - done
| -- Check for working CXX compiler: /opt/PHYTEC_BSPs19/yocto_imx7/build-msi1/tmp/work/cortexa7hf-neon-poky-linux-gnueabi/zeek/3.1.1-r0/recipe-sysroot-native/usr/bin/arm-poky-linux-gnueabi/arm-poky-linux-gnueabi-g++
| -- Check for working CXX compiler: /opt/PHYTEC_BSPs19/yocto_imx7/build-msi1/tmp/work/cortexa7hf-neon-poky-linux-gnueabi/zeek/3.1.1-r0/recipe-sysroot-native/usr/bin/arm-poky-linux-gnueabi/arm-poky-linux-gnueabi-g++ -- works
| -- Detecting CXX compiler ABI info
| -- Detecting CXX compiler ABI info - done
| -- Detecting CXX compile features
| -- Detecting CXX compile features - done
| CMake Error at CMakeLists.txt:170 (message):
|   Could not find required dependency: sed
I tracked this down to the cmake find_program(), here's the lines in CMakeLists.txt:
########################################################################
## Dependency Configuration
include(FindRequiredPackage)
# Check cache value first to avoid displaying "Found sed" messages everytime
if (NOT SED_EXE)
    find_program(SED_EXE sed)
    if (NOT SED_EXE)
        message(FATAL_ERROR "Could not find required dependency: sed")
    else ()
        message(STATUS "Found sed: ${SED_EXE}")
    endif ()
endif ()
Any ideas how to fix this?


Gary Huband
 

Placing the following line in the recipe seems to have fixed the problem:

OECMAKE_FIND_ROOT_PATH_MODE_PROGRAM="BOTH"

That value was set to only by the cmake class, so it only searched in the recipe build directories.


Philip Balister
 

I'd add sed-native to DEPENDS rather than depend on one on the build
machine.

On 4/18/20 5:14 PM, gary@missionsecure.com wrote:
Placing the following line in the recipe seems to have fixed the problem:

OECMAKE_FIND_ROOT_PATH_MODE_PROGRAM="BOTH"

That value was set to only by the cmake class, so it only searched in the recipe build directories.