This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Linux/WL1837MOD: WiLink8 build fails during libcrypto build

Part Number: WL1837MOD
Other Parts Discussed in Thread: WL1835MOD

Tool/software: Linux

Hi,

I am following the page at processors.wiki.ti.com/index.php/WL18xx_First_Time_Getting_Started_Guide_%28IMX6%29, and the build_wl18xx.sh script completes most steps successfully but fails during the build of the libcrypto library with the following error:

make[2]: Entering directory '/media/tpeterson/Part2/ti_wlan/build-utilites/src/openssl/apps'
( :; LIBDEPS="${LIBDEPS:--L.. -lssl  -L.. -lcrypto -ldl}"; LDCMD="${LDCMD:-gcc}"; LDFLAGS="${LDFLAGS:--DOPENSSL_THREADS -D_REENTRANT -DDSO_DLFCN -DHAVE_DLFCN_H -O3 -fomit-frame-pointer -Wall}"; LIBPATH=`for x in $LIBDEPS; do echo $x; done | sed -e 's/^ *-L//;t' -e d | uniq`; LIBPATH=`echo $LIBPATH | sed -e 's/ /:/g'`; LD_LIBRARY_PATH=$LIBPATH:$LD_LIBRARY_PATH ${LDCMD} ${LDFLAGS} -o ${APPNAME:=openssl} openssl.o verify.o asn1pars.o req.o dgst.o dh.o dhparam.o enc.o passwd.o gendh.o errstr.o ca.o pkcs7.o crl2p7.o crl.o rsa.o rsautl.o dsa.o dsaparam.o ec.o ecparam.o x509.o genrsa.o gendsa.o genpkey.o s_server.o s_client.o speed.o s_time.o apps.o s_cb.o s_socket.o app_rand.o version.o sess_id.o ciphers.o nseq.o pkcs12.o pkcs8.o pkey.o pkeyparam.o pkeyutl.o spkac.o smime.o cms.o rand.o engine.o ocsp.o prime.o ts.o srp.o ${LIBDEPS} )
../libcrypto.a(e_rc4_hmac_md5.o): In function `rc4_hmac_md5_cipher':
e_rc4_hmac_md5.c:(.text+0x407): undefined reference to `rc4_md5_enc'
e_rc4_hmac_md5.c:(.text+0x4ed): undefined reference to `rc4_md5_enc'
collect2: error: ld returned 1 exit status
../Makefile.shared:164: recipe for target 'link_app.' failed

Any ideas on what could cause this?

  • Hi,
    - are you building it on linux or android ?
    - pls list all build steps
    - what tag are you using for wilink8 build utilities ?
    - pls provide more details on h/w s/w setup

    Saurabh
  • -I am building it on Linux

    -For the full build steps for the wlan, I have edited the setup-env, ran "./build_wl18xx.sh init" , then "./build_wl18xx.sh update R8.7_SP3"

    -R8.7_SP3

    -Right now the hardware is a WL1835MOD connected to WL18xx WLAN SDIO/BT UART adapter Board connected to a toradex colibri imx6 eval board. The linux stack is a toradex branch of the yocto project.

    The following is the setup-env file:

    #                            \\\// 
    #                           -(o o)- 
    #========================oOO==(_)==OOo=======================
    # This file contains the exports needed for automating the
    # build process of WLAN components.
    # Place this file in the same directory with wl18xx_build.sh
    # build scripts. No need to run 'source setup-env', the build
    # scripts will perfom it internaly. 
    #===========================================================
    # User specific environment settings - use full PATH
    
    # if DEFAULT toolchain path is set toolchain will be downloaded to ./toolchain.
    export TOOLCHAIN_PATH=/usr/local/oecore-x86_64/sysroots/x86_64-angstromsdk-linux/usr/bin/arm-angstrom-linux-gnueabi
    
    # if DEFAULT path to root filesystem is set ./fs folder will be used.
    export ROOTFS=/usr/local/oecore-x86_64/sysroots/armv7at2hf-neon-angstrom-linux-gnueabi
    
    #if DEFAULT kernel path is set - kernel will be downloaded (set branch to match kernel version)
    export KERNEL_PATH=/media/tpeterson/Part2/oe-core-toradex/build/tmp-glibc/work-shared/colibri-imx6/kernel-source
    
    # if KERNEL_VARIANT below is set the build script will look for kernel specific
    # patches under the patches directory:
    # - patches under the pathces/driver_patches/$KERNEL_VARIANT directory would be
    #   applied during "modules" build.
    # - patches under the patches/kernel_patches/$/$KERNEL_VARIANT directory would
    #   be applied to the kernel pointed by KERNEL_PATH in case the "patch_kernel"
    #   command is used.
    #   Note: the kernel is not built automatically after the patches are applied
    export KERNEL_VARIANT=4.9.84-2.8.2+gb2a7f2f
    
    export CROSS_COMPILE=arm-angstrom-linux-gnueabi-
    export ARCH=arm
    [ "$TOOLCHAIN_PATH" != "DEFAULT" ] && export PATH=$TOOLCHAIN_PATH:$PATH

    The current error if I run the two steps (init then update) is :

    cryptlib.h:62:11: fatal error: stdlib.h: No such file or directory
     # include <stdlib.h>
               ^~~~~~~~~~

  • Hi,
    Are you running kernel 4.9.x ?

    Saurabh
  • Yes the arm kernel is 4.9.84 . (The build machine kernel is 4.15.0 ).

  • Hi,
    we haven't tested this on imx on kernel 4.9. You won't be able to backport wl8 kernel modules to kernel 4.9 since build utilities only support kernel upto 4.4 . Anyhow kernel 4.9 should have more recent version of wl8 driver modules. I suggest you apply kernel patches to this kernel manually first and see if that works.

    Saurabh