..

Install Diva Media board on Linux: Build error

..

Developer Group

Developer Group
Connect with thousands of other developers to brainstorm ideas, share best practices and tips - or just chat about the latest emerging technologies making noise in the field. And of course, get the most up-to-date service and support news from Dialogic.
Dialogic Diva SDK programming questions

Install Diva Media board on Linux: Build error

  • I need to install the Diva media board driver on Linux platform on a vmware

    while running the ./Build command
    I got

    ERROR    :    Failed to call 'std2kern'
    MISSING:    make modules

    My log File


    # --------------------------------------------------------------
    #
    # Diva build (c) Copyright by Dialogic 1993 - 2013
    # Please read legal notice at begin of reference manual
    # /usr/lib/opendiva/divas/httpd/guide/reference_manual.html
    #
    # BUILD:             115-157
    # STARTED AT:        Mon Oct 10 15:19:43 EET 2016
    # HOST:              ubuntu
    # WORKING DIRECTORY: /usr/lib/opendiva/divas/src
    # LOG FILE:          /usr/lib/opendiva/divas/src/divas.log
    # OPTIONS:          
    # TARGET:            /usr/lib/opendiva/divas
    #
    # Usage: Build [ parameters ]
    #  Parameters:
    #    -mrproper  : to start build with 'make mrproper'
    #    -detect-kernel-features
    #               : to detect kernel features, useful for debugging
    #    -rpm       : to build binary RPM package
    #    -deb       : to build binary Debian package
    #    -nowait    : do not wait for responses
    #    -noshm     : do not use ramdisk (tmpfs)
    #    -noinstall : do not install drivers to target directory
    #               : use make oldconfig insted of make menuconfig
    #                 because this requires installed drivers
    #    -target    : to specify alternative target directory
    #    -no-optimized-capi
    #               : do not build Diva optimized CAPI
    #    -force-headers
    #               : build using kernel headers only
    #    -force-no-headers
    #               : build using kernel source tree
    #    -use-oldconfig
    #
    # Selected options:
    #
    #   - COMPILE AND INSTALL DIVA DRIVERS -
    #
    #  INFO: Procedure includes update of kernel source
    #        tree and of kernel configuration
    #
    # --------------------------------------------------------------

    OK
    # LOG ---- START SECTION 'cleanup_tmp_files' ------------------
    umount: tmp: not mounted
    # LOG ---- END SECTION 'cleanup_tmp_files' ------------------
    OK
    # LOG ---- START SECTION check_files ------------------
    #+ LOG START PROCESS STEP 1/sed: sed
    #+ LOG END PROCESS STEP: 1
    #+ LOG START PROCESS STEP 2/grep: grep
    #+ LOG END PROCESS STEP: 2
    #+ LOG START PROCESS STEP 3/make: make
    OK
    #+ LOG END PROCESS STEP: 3
    #+ LOG START PROCESS STEP 4//usr/src/linux: /usr/src/linux
    #+ LOG END PROCESS STEP: 4
    #+ LOG START PROCESS STEP 5//usr/src/linux/include/linux: /usr/src/linux/include/linux
    #+ LOG END PROCESS STEP: 5
    #+ LOG START PROCESS STEP 6//usr/lib/opendiva/divas: /usr/lib/opendiva/divas
    #+ LOG END PROCESS STEP: 6
    #+ LOG START PROCESS STEP 7//usr/src/linux/Makefile: /usr/src/linux/Makefile
    #+ LOG END PROCESS STEP: 7
    #+ LOG START PROCESS STEP 8/Kernel version: Kernel version
    #++ LOG INFO kernel version/major 4/4
    #+ LOG END PROCESS STEP: 8
    #+ LOG START PROCESS STEP 9/src/kernel.tgz: src/kernel.tgz
    #+ LOG END PROCESS STEP: 9
    #+ LOG START PROCESS STEP 10/src/kernel_2.tgz: src/kernel_2.tgz
    #+ LOG END PROCESS STEP: 10
    #+ LOG START PROCESS STEP 11/gcc: gcc
    #+ LOG END PROCESS STEP: 11
    #+ LOG START PROCESS STEP 12/gcc: gcc
    #+ LOG END PROCESS STEP: 12
    #+ LOG START PROCESS STEP 13/tar: tar
    #+ LOG END PROCESS STEP: 13
    #+ LOG START PROCESS STEP 14//usr/src/linux/.config: /usr/src/linux/.config
    #++ LOG found '.config', preserved
    #+ LOG END PROCESS STEP: 14
    #+ LOG START PROCESS STEP 15//usr/src/linux/include/linux/version.h: /usr/src/linux/include/linux/version.h
    #+ LOG END PROCESS STEP: 15
    #+ LOG START PROCESS STEP 16//usr/src/linux/include/linux/version.h: /usr/src/linux/include/linux/version.h
    #+ LOG END PROCESS STEP: 16
    #+ LOG START PROCESS STEP 17//bin/bash: /bin/bash
    #+ LOG END PROCESS STEP: 17
    #+ LOG START PROCESS STEP 18/Kernel features: Kernel features
    #+ LOG END PROCESS STEP: 18
    #+ LOG START PROCESS STEP 19//usr/src/linux/Module.symvers: /usr/src/linux/Module.symvers
    #+ LOG END PROCESS STEP: 19
    # LOG ---- END SECTION check_files ------------------
    OK
    # LOG ---- START SECTION read kernel version ------------------
    #+ LOG INFO: /proc/version:  Linux version 4.4.0-38-generic (buildd@lgw01-58) (gcc version 5.4.0 20160609 (Ubuntu 5.4.0-6ubuntu1~16.04.2) ) #57-Ubuntu SMP Tue Sep 6 15:42:33 UTC 2016
    #+ LOG INFO: /etc/*-release: DISTRIB_ID=Ubuntu
    DISTRIB_RELEASE=16.04
    DISTRIB_CODENAME=xenial
    DISTRIB_DESCRIPTION="Ubuntu 16.04.1 LTS"
    NAME="Ubuntu"
    VERSION="16.04.1 LTS (Xenial Xerus)"
    ID=ubuntu
    ID_LIKE=debian
    PRETTY_NAME="Ubuntu 16.04.1 LTS"
    VERSION_ID="16.04"
    HOME_URL="http://www.ubuntu.com/"
    SUPPORT_URL="http://help.ubuntu.com/"
    BUG_REPORT_URL="http://bugs.launchpad.net/ubuntu/"
    UBUNTU_CODENAME=xenial
    #+ LOG INFO: Makefile/VERSION = 4
    #+ LOG INFO: Makefile/PATCHLEVEL = 4
    #+ LOG INFO: Makefile/SUBLEVEL = 19
    #+ LOG INFO: Makefile/EXTRAVERSION =
    # LOG ---- END SECTION read kernel version ------------------
    OK
    # LOG ---- START SECTION fix_kernel_headers2 ------------------
    #+ LOG START PROCESS STEP: include/linux/kernel.h, byte
    #+++ LOG INFO: start fix byte variable
    #+++ LOG INFO: end fix byte variable
    #+++ LOG INFO: fixed version.h for 3.x kernel
      CHK     include/config/kernel.release
      CHK     include/generated/uapi/linux/version.h
      CHK     include/generated/utsrelease.h
      CC      kernel/bounds.s
      CHK     include/generated/bounds.h
      CHK     include/generated/timeconst.h
      CC      arch/x86/kernel/asm-offsets.s
      CHK     include/generated/asm-offsets.h
      CALL    scripts/checksyscalls.sh
    #+ LOG END PROCESS STEP: include/linux/kernel.h, byte
    # LOG ---- END SECTION fix_kernel_headers2 ------------------
    OK
    # LOG ---- START SECTION 'build_module_tree' ------------------
    #+ LOG INFO: tmp pwd:/usr/lib/opendiva/divas/src/tmp
    #+ LOG INFO: pwd:/usr/lib/opendiva/divas/src/tmp
    #++ LOG INFO: remove include linux/config.h from sources
    #++ LOG INFO: log info, build optimized CAPI ------------------
    # LOG ---- START SECTION set DIVA_EICON_CAPI ON ------------------
    # LOG ---- END SECTION set DIVA_EICON_CAPI ON ------------------
      CC [M]  /usr/lib/opendiva/divas/src/tmp/drivers/isdn/hardware/eicon/diva_didd.o
    /usr/lib/opendiva/divas/src/tmp/drivers/isdn/hardware/eicon/diva_didd.c:177:11: warning: initialization from incompatible pointer type [-Wincompatible-pointer-types]
      .read  = proc_read,
               ^
    /usr/lib/opendiva/divas/src/tmp/drivers/isdn/hardware/eicon/diva_didd.c:177:11: note: (near initialization for ‘proc_file_fops.read’)
      CC [M]  /usr/lib/opendiva/divas/src/tmp/drivers/isdn/hardware/eicon/diddfunc.o
    /usr/lib/opendiva/divas/src/tmp/drivers/isdn/hardware/eicon/diddfunc.c: In function ‘connect_didd’:
    /usr/lib/opendiva/divas/src/tmp/drivers/isdn/hardware/eicon/diddfunc.c:107:1: warning: the frame size of 2368 bytes is larger than 1024 bytes [-Wframe-larger-than=]
     }
     ^
      CC [M]  /usr/lib/opendiva/divas/src/tmp/drivers/isdn/hardware/eicon/dadapter.o
      CC [M]  /usr/lib/opendiva/divas/src/tmp/drivers/isdn/hardware/eicon/parser.o
      CC [M]  /usr/lib/opendiva/divas/src/tmp/drivers/isdn/hardware/eicon/cfglib.o
      CC [M]  /usr/lib/opendiva/divas/src/tmp/drivers/isdn/hardware/eicon/runtime.o
      CC [M]  /usr/lib/opendiva/divas/src/tmp/drivers/isdn/hardware/eicon/dlist.o
      CC [M]  /usr/lib/opendiva/divas/src/tmp/drivers/isdn/hardware/eicon/diva_cfg_lib.o
    /usr/lib/opendiva/divas/src/tmp/drivers/isdn/hardware/eicon/diva_cfg_lib.c: In function ‘diva_cfg_translate_xdi_data’:
    /usr/lib/opendiva/divas/src/tmp/drivers/isdn/hardware/eicon/diva_cfg_lib.c:1800:8: warning: ‘pc_init_data’ may be used uninitialized in this function [-Wmaybe-uninitialized]
            memcpy (dst+offset, pc_init_data, pc_init_data_length);
            ^
    /usr/lib/opendiva/divas/src/tmp/drivers/isdn/hardware/eicon/diva_cfg_lib.c:1747:16: note: ‘pc_init_data’ was declared here
        const byte* pc_init_data;
                    ^
      LD [M]  /usr/lib/opendiva/divas/src/tmp/drivers/isdn/hardware/eicon/divadidd.o
      CC [M]  /usr/lib/opendiva/divas/src/tmp/drivers/isdn/hardware/eicon/divasmain.o
      CC [M]  /usr/lib/opendiva/divas/src/tmp/drivers/isdn/hardware/eicon/divasfunc.o
    /usr/lib/opendiva/divas/src/tmp/drivers/isdn/hardware/eicon/divasfunc.c: In function ‘start_dbg’:
    /usr/lib/opendiva/divas/src/tmp/drivers/isdn/hardware/eicon/divasfunc.c:144:13: error: macro "__DATE__" might prevent reproducible builds [-Werror=date-time]
        __TIME__))
                 ^
    /usr/lib/opendiva/divas/src/tmp/drivers/isdn/hardware/eicon/divasfunc.c:144:13: error: macro "__TIME__" might prevent reproducible builds [-Werror=date-time]
    /usr/lib/opendiva/divas/src/tmp/drivers/isdn/hardware/eicon/divasfunc.c: In function ‘connect_didd’:
    /usr/lib/opendiva/divas/src/tmp/drivers/isdn/hardware/eicon/divasfunc.c:218:1: warning: the frame size of 2368 bytes is larger than 1024 bytes [-Wframe-larger-than=]
     }
     ^
    cc1: some warnings being treated as errors
    scripts/Makefile.build:258: recipe for target '/usr/lib/opendiva/divas/src/tmp/drivers/isdn/hardware/eicon/divasfunc.o' failed
    make[1]: *** [/usr/lib/opendiva/divas/src/tmp/drivers/isdn/hardware/eicon/divasfunc.o] Error 1
    Makefile:1403: recipe for target '_module_/usr/lib/opendiva/divas/src/tmp/drivers/isdn/hardware/eicon' failed
    make: *** [_module_/usr/lib/opendiva/divas/src/tmp/drivers/isdn/hardware/eicon] Error 2
    # ERROR ---- 'failed to build modules using headers' ------------------
    umount: tmp: mountpoint not found
    #! LOG ABORT EXECUTION DUE TO ERROR  : Failed to call 'std2kern'
    #! LOG ERROR INFO: make modules

    can you help me solve this issue

    I've downloaded Diva4Linux_installer_9.6-115-157

    I also need to know

    does that binary file support installing on virtualized environments?

    if it is not is there an alternative?

    my Card is Dialogic JCT Media Board Diva Analog (306-389 rev50)

    Thanks in advance

  • You should make sure the /usr/src/linux symlink points to the correct kernel source directory. Refer to the installation guide for details if needed.

    The release notes state that:

    The source package in 9.6LIN SU3 can now be built and operate on Linux OSD with kernel version 3.10. It has been also validated by early adopter on one OSD (CentOS Version 7) with Linux kernel 3.18; however the Diva tty may cause kernel panic when attempting to access tty-Devices /dev/ttyds??. The tty driver has been verified up Linux kernel 3.13 on Ubuntu 12.04. Other issues might be experienced when using distributions with Linux kernel higher than 3.10.

    In other words, the Diva Linux driver officially only supports kernels up to 3.10.

    If you are trying to compile on a kernel above 3.10 you can try the suggested fix in this post: www.dialogic.com/.../10621.aspx

  • does 9.6LIN SU3 binary file support installing on virtualized environments?

  • The Diva boards do not work in virtualized environments, regardless of the underlying OS.

  • what are the underlying OS?

    Also while invoking ./Build

    I got this

    PROCESSING: Build chan_capi ... FAILED

  • It means you cannot run a Diva board on either Windows or Linux in a virtual machine. You can only use them on Windows or Linux in a physical machine.

    Chan_capi is a special feature to us CAPI over LAN, very few customers use it.

  • thank you so much for your responses

    If I need to test the card with asterisk what do I need to do?

    I already installed asterisk-11.23 and configured my dialplan, so what else do I need to test?

    thanks in advance

  • Refer to this page: www.dialogic.com/.../Diva_M_LIN

    Registration is free and quick if you're not already registered.

  • when I chose yes

    I got this

    PROCESSING: Build chan_capi ... FAILED

  • The latest available Diva SR 9.6 SU3 LIN only supports Asterisk versions up to 1.8. Are you using anything later than that maybe?

  • I am using asterisk 11.23

  • That is not supported and there is no ongoing development to get version 1.8+ supported.

  • I tried to install asterisk 1.6 and 1.8 but I got errors while run the Make command

    1.6

    /asterisk-1.6.2.24/Makefile.rules:136: recipe for target 'hashtest2' failed

    make[1]: *** [hashtest2] Error 1

    Makefile:422: recipe for target 'utils' failed

    make: *** [utils] Error 2

    1.8

    /asterisk-1.8.8.0/Makefile.rules:130: recipe for target 'chan_iax2.so' failed

    make[1]: *** [chan_iax2.so] Error 1

    Makefile:395: recipe for target 'channels' failed

    do you what causing this errors?

  • also while install the driver on the physical Linux machine

    and running ./Config

    I got

    'DIDD' driver load failed. Please check system installation (kernel version, missing files)

    what is the cause of this issue?

  • It usually means that the /usr/src/linux symlink is pointing to a kernel source directory that does not match the running kernel version. However in your case this could be due to an unsupported kernel version (3.10+).