Author Topic: Unable to configure DNX RTOS on UBUNTU 14.04  (Read 326 times)

suyog44

  • Looking Around
  • Posts: 4
  • Karma: +0/-0
    • View Profile
Unable to configure DNX RTOS on UBUNTU 14.04
« on: January 30, 2018, 06:51:41 AM »
I have followed the instruction given on page
http://www.dnx-rtos.org/dnx-rtos-configuration/

But I am facing following issues after executing "make" command.

brisker@brisker-ThinkPad-X60:~/dnx-rtos$ sudo make
Adding user's programs and libraries to the project...
./src/application/addapps.sh: 22: ./src/application/addapps.sh: Syntax error: "(" unexpected
make: *** [generate] Error 2

Awaiting for reply. Thank You.
« Last Edit: January 30, 2018, 07:26:09 AM by suyog44 »

Daniel

  • Administrator
  • Interested
  • *****
  • Posts: 37
  • Karma: +0/-0
    • View Profile
Re: Unable to configure DNX RTOS on UBUNTU 14.04
« Reply #1 on: January 30, 2018, 07:20:27 PM »
Hi!

You ran 'make' command as root user (by using sudo). Please type only 'make' command instead of 'sudo make'.

Let me know that is working or not.

Daniel

  • Administrator
  • Interested
  • *****
  • Posts: 37
  • Karma: +0/-0
    • View Profile
Re: Unable to configure DNX RTOS on UBUNTU 14.04
« Reply #2 on: January 30, 2018, 10:21:53 PM »
I made some test on Ubuntu 14.04 and I found the same issue as you have. I will investigate what is working wrong...

Daniel

  • Administrator
  • Interested
  • *****
  • Posts: 37
  • Karma: +0/-0
    • View Profile
Re: Unable to configure DNX RTOS on UBUNTU 14.04
« Reply #3 on: January 30, 2018, 10:38:17 PM »
There is an issue in Makefile ( ??? ). To fix the problem please edit the Makefile in project root directory and change code:

SHELL      = /bin/sh

to

SHELL      = /bin/bash

This modification fixes problems with handling bash scripts. I will make fix for this in development version and next in incoming release.
Thanks for test!   :)

suyog44

  • Looking Around
  • Posts: 4
  • Karma: +0/-0
    • View Profile
Re: Unable to configure DNX RTOS on UBUNTU 14.04
« Reply #4 on: January 31, 2018, 09:00:19 AM »
Dear Sir, Thank you so much for your response. Makefile file has been working fine now.
But there is some problem in the source code. That I am mentioning below.

Quote
Adding user's programs and libraries to the project...
Adding file systems to the project...
Adding drivers to the project...
Creating dependencies for 'stm32f1' target...
Starting building objects up to 4 threads...
Compiling: src/application/programs/../program_registration.c
Compiling: src/system/drivers/driver_registration.c
Compiling: src/system/fs/fs_registration.c
Compiling: src/system/fs/ext4fs/lwext4/ext4_balloc.c
Compiling: src/system/fs/ext4fs/lwext4/ext4_bcache.c
Compiling: src/system/fs/ext4fs/lwext4/ext4_blockdev.c
src/system/fs/ext4fs/lwext4/ext4_balloc.c: In function 'ext4_balloc_free_blocks':
src/system/fs/ext4fs/lwext4/ext4_balloc.c:346:2: error: too few arguments to function '_assert_hook'
  ext4_assert(count == 0);
  ^
In file included from ./src/system/kernel/FreeRTOS/Source/include/FreeRTOS.h:98:0,
                     
./src/system/kernel/FreeRTOS/FreeRTOSConfig.h:160:13: note: declared here
 extern void _assert_hook(bool assert, const char *msg);
             ^
make[2]: *** [build/stm32f1/obj/./src/system/fs/ext4fs/lwext4/ext4_balloc.o] Error 1
make[2]: *** Waiting for unfinished jobs....
src/system/fs/ext4fs/lwext4/ext4_blockdev.c: In function 'ext4_bdif_lock':
src/system/fs/ext4fs/lwext4/ext4_blockdev.c:56:2: error: too few arguments to function '_assert_hook'
  ext4_assert(r == EOK);
  ^
In file included from ./src/system/kernel/FreeRTOS/Source/include/FreeRTOS.h:98:0,
               
./src/system/kernel/FreeRTOS/FreeRTOSConfig.h:160:13: note: declared here
 extern void _assert_hook(bool assert, const char *msg);
             ^
src/system/fs/ext4fs/lwext4/ext4_blockdev.c: In function 'ext4_bdif_unlock':
src/system/fs/ext4fs/lwext4/ext4_blockdev.c:65:2: error: too few arguments to function '_assert_hook'
  ext4_assert(r == EOK);
  ^
In file included from ./src/system/kernel/FreeRTOS/Source/include/FreeRTOS.h:98:0,
                 
./src/system/kernel/FreeRTOS/FreeRTOSConfig.h:160:13: note: declared here
 extern void _assert_hook(bool assert, const char *msg);
             ^
src/system/fs/ext4fs/lwext4/ext4_blockdev.c: In function 'ext4_block_init':
src/system/fs/ext4fs/lwext4/ext4_blockdev.c:91:2: error: too few arguments to function '_assert_hook'
  ext4_assert(bdev);
  ^
In file included from ./src/system/kernel/FreeRTOS/Source/include/FreeRTOS.h:98:0,
                 
./src/system/kernel/FreeRTOS/FreeRTOSConfig.h:160:13: note: declared here
 extern void _assert_hook(bool assert, const char *msg);
             ^
src/system/fs/ext4fs/lwext4/ext4_blockdev.c:92:2: error: too few arguments to function '_assert_hook'
  ext4_assert(bdev->bdif);
  ^
In file included from ./src/system/kernel/FreeRTOS/Source/include/FreeRTOS.h:98:0,
               
./src/system/kernel/FreeRTOS/FreeRTOSConfig.h:160:13: note: declared here
 extern void _assert_hook(bool assert, const char *msg);
             ^
src/system/fs/ext4fs/lwext4/ext4_blockdev.c:93:2: error: too few arguments to function '_assert_hook'
  ext4_assert(bdev->bdif->open &&
  ^
In file included from ./src/system/kernel/FreeRTOS/Source/include/FreeRTOS.h:98:0,
               
./src/system/kernel/FreeRTOS/FreeRTOSConfig.h:160:13: note: declared here
 extern void _assert_hook(bool assert, const char *msg);
             ^
src/system/fs/ext4fs/lwext4/ext4_blockdev.c: In function 'ext4_block_bind_bcache':
src/system/fs/ext4fs/lwext4/ext4_blockdev.c:114:2: error: too few arguments to function '_assert_hook'
  ext4_assert(bdev && bc);
  ^
In file included from ./src/system/kernel/FreeRTOS/Source/include/FreeRTOS.h:98:0,
               
./src/system/kernel/FreeRTOS/FreeRTOSConfig.h:160:13: note: declared here
 extern void _assert_hook(bool assert, const char *msg);
             ^
src/system/fs/ext4fs/lwext4/ext4_blockdev.c: In function 'ext4_block_set_lb_size':
src/system/fs/ext4fs/lwext4/ext4_blockdev.c:123:2: error: too few arguments to function '_assert_hook'
  ext4_assert(!(lb_bsize % bdev->bdif->ph_bsize));
  ^
In file included from ./src/system/kernel/FreeRTOS/Source/include/FreeRTOS.h:98:0,
               
./src/system/kernel/FreeRTOS/FreeRTOSConfig.h:160:13: note: declared here
 extern void _assert_hook(bool assert, const char *msg);
             ^
src/system/fs/ext4fs/lwext4/ext4_blockdev.c: In function 'ext4_block_fini':
src/system/fs/ext4fs/lwext4/ext4_blockdev.c:131:2: error: too few arguments to function '_assert_hook'
  ext4_assert(bdev);
  ^
In file included from ./src/system/kernel/FreeRTOS/Source/include/FreeRTOS.h:98:0,
               
./src/system/kernel/FreeRTOS/FreeRTOSConfig.h:160:13: note: declared here
 extern void _assert_hook(bool assert, const char *msg);
             ^
src/system/fs/ext4fs/lwext4/ext4_blockdev.c: In function 'ext4_block_cache_shake':
src/system/fs/ext4fs/lwext4/ext4_blockdev.c:199:3: error: too few arguments to function '_assert_hook'
   ext4_assert(buf);
   ^
In file included from ./src/system/kernel/FreeRTOS/Source/include/FreeRTOS.h:98:0,
               
./src/system/kernel/FreeRTOS/FreeRTOSConfig.h:160:13: note: declared here
 extern void _assert_hook(bool assert, const char *msg);
             ^
src/system/fs/ext4fs/lwext4/ext4_blockdev.c: In function 'ext4_block_get_noread':
src/system/fs/ext4fs/lwext4/ext4_blockdev.c:219:2: error: too few arguments to function '_assert_hook'
  ext4_assert(bdev && b);
  ^
In file included from ./src/system/kernel/FreeRTOS/Source/include/FreeRTOS.h:98:0,
         
./src/system/kernel/FreeRTOS/FreeRTOSConfig.h:160:13: note: declared here
 extern void _assert_hook(bool assert, const char *msg);
             ^
src/system/fs/ext4fs/lwext4/ext4_blockdev.c: In function 'ext4_block_set':
src/system/fs/ext4fs/lwext4/ext4_blockdev.c:272:2: error: too few arguments to function '_assert_hook'
  ext4_assert(bdev && b);
  ^
In file included from ./src/system/kernel/FreeRTOS/Source/include/FreeRTOS.h:98:0,
           
./src/system/kernel/FreeRTOS/FreeRTOSConfig.h:160:13: note: declared here
 extern void _assert_hook(bool assert, const char *msg);
             ^
src/system/fs/ext4fs/lwext4/ext4_blockdev.c:273:2: error: too few arguments to function '_assert_hook'
  ext4_assert(b->buf);
  ^
In file included from ./src/system/kernel/FreeRTOS/Source/include/FreeRTOS.h:98:0,
               
./src/system/kernel/FreeRTOS/FreeRTOSConfig.h:160:13: note: declared here
 extern void _assert_hook(bool assert, const char *msg);
             ^
src/system/fs/ext4fs/lwext4/ext4_blockdev.c: In function 'ext4_blocks_get_direct':
src/system/fs/ext4fs/lwext4/ext4_blockdev.c:287:2: error: too few arguments to function '_assert_hook'
  ext4_assert(bdev && buf);
  ^
In file included from ./src/system/kernel/FreeRTOS/Source/include/FreeRTOS.h:98:0,
               
./src/system/kernel/FreeRTOS/FreeRTOSConfig.h:160:13: note: declared here
 extern void _assert_hook(bool assert, const char *msg);
             ^
src/system/fs/ext4fs/lwext4/ext4_blockdev.c: In function 'ext4_blocks_set_direct':
src/system/fs/ext4fs/lwext4/ext4_blockdev.c:301:2: error: too few arguments to function '_assert_hook'
  ext4_assert(bdev && buf);
  ^
In file included from ./src/system/kernel/FreeRTOS/Source/include/FreeRTOS.h:98:0,
               
./src/system/kernel/FreeRTOS/FreeRTOSConfig.h:160:13: note: declared here
 extern void _assert_hook(bool assert, const char *msg);
             ^
src/system/fs/ext4fs/lwext4/ext4_blockdev.c: In function 'ext4_block_writebytes':
src/system/fs/ext4fs/lwext4/ext4_blockdev.c:319:2: error: too few arguments to function '_assert_hook'
  ext4_assert(bdev && buf);
  ^
In file included from ./src/system/kernel/FreeRTOS/Source/include/FreeRTOS.h:98:0,
                 
./src/system/kernel/FreeRTOS/FreeRTOSConfig.h:160:13: note: declared here
 extern void _assert_hook(bool assert, const char *msg);
             ^
src/system/fs/ext4fs/lwext4/ext4_blockdev.c: In function 'ext4_block_readbytes':
src/system/fs/ext4fs/lwext4/ext4_blockdev.c:389:2: error: too few arguments to function '_assert_hook'
  ext4_assert(bdev && buf);
  ^
In file included from ./src/system/kernel/FreeRTOS/Source/include/FreeRTOS.h:98:0,
               
./src/system/kernel/FreeRTOS/FreeRTOSConfig.h:160:13: note: declared here
 extern void _assert_hook(bool assert, const char *msg);
             ^
src/system/fs/ext4fs/lwext4/ext4_blockdev.c: In function 'ext4_block_cache_flush':
src/system/fs/ext4fs/lwext4/ext4_blockdev.c:449:3: error: too few arguments to function '_assert_hook'
   ext4_assert(buf);
   ^
In file included from ./src/system/kernel/FreeRTOS/Source/include/FreeRTOS.h:98:0,
               
./src/system/kernel/FreeRTOS/FreeRTOSConfig.h:160:13: note: declared here
 extern void _assert_hook(bool assert, const char *msg);
             ^
src/system/fs/ext4fs/lwext4/ext4_bcache.c: In function 'ext4_bcache_init_dynamic':
src/system/fs/ext4fs/lwext4/ext4_bcache.c:73:2: error: too few arguments to function '_assert_hook'
  ext4_assert(bc && cnt && itemsize);
  ^
In file included from ./src/system/kernel/FreeRTOS/Source/include/FreeRTOS.h:98:0,
               
./src/system/kernel/FreeRTOS/FreeRTOSConfig.h:160:13: note: declared here
 extern void _assert_hook(bool assert, const char *msg);
             ^
src/system/fs/ext4fs/lwext4/ext4_bcache.c: In function 'ext4_bcache_free':
src/system/fs/ext4fs/lwext4/ext4_bcache.c:274:2: error: too few arguments to function '_assert_hook'
  ext4_assert(bc && b);
  ^
In file included from ./src/system/kernel/FreeRTOS/Source/include/FreeRTOS.h:98:0,
               
./src/system/kernel/FreeRTOS/FreeRTOSConfig.h:160:13: note: declared here
 extern void _assert_hook(bool assert, const char *msg);
             ^
src/system/fs/ext4fs/lwext4/ext4_bcache.c:277:2: error: too few arguments to function '_assert_hook'
  ext4_assert(b->lb_id);
  ^
In file included from ./src/system/kernel/FreeRTOS/Source/include/FreeRTOS.h:98:0,
               
./src/system/kernel/FreeRTOS/FreeRTOSConfig.h:160:13: note: declared here
 extern void _assert_hook(bool assert, const char *msg);
             ^
src/system/fs/ext4fs/lwext4/ext4_bcache.c:280:2: error: too few arguments to function '_assert_hook'
  ext4_assert(buf);
  ^
In file included from ./src/system/kernel/FreeRTOS/Source/include/FreeRTOS.h:98:0,
               
./src/system/kernel/FreeRTOS/FreeRTOSConfig.h:160:13: note: declared here
 extern void _assert_hook(bool assert, const char *msg);
             ^
src/system/fs/ext4fs/lwext4/ext4_bcache.c:283:2: error: too few arguments to function '_assert_hook'
  ext4_assert(buf->refctr);
  ^
In file included from ./src/system/kernel/FreeRTOS/Source/include/FreeRTOS.h:98:0,
                 
./src/system/kernel/FreeRTOS/FreeRTOSConfig.h:160:13: note: declared here
 extern void _assert_hook(bool assert, const char *msg);
             ^
make[2]: *** [build/stm32f1/obj/./src/system/fs/ext4fs/lwext4/ext4_blockdev.o] Error 1
make[2]: *** [build/stm32f1/obj/./src/system/fs/ext4fs/lwext4/ext4_bcache.o] Error 1
make[1]: *** [buildobjects] Error 2
make: *** [all] Error 2

Daniel

  • Administrator
  • Interested
  • *****
  • Posts: 37
  • Karma: +0/-0
    • View Profile
Re: Unable to configure DNX RTOS on UBUNTU 14.04
« Reply #5 on: February 15, 2018, 09:43:52 AM »
Hi, I found this issue too. I'll fix it soon.

Daniel

  • Administrator
  • Interested
  • *****
  • Posts: 37
  • Karma: +0/-0
    • View Profile
Re: Unable to configure DNX RTOS on UBUNTU 14.04
« Reply #6 on: February 15, 2018, 09:53:21 AM »
Please pull the latest develop version, there is a fix for that :)

suyog44

  • Looking Around
  • Posts: 4
  • Karma: +0/-0
    • View Profile
Re: Unable to configure DNX RTOS on UBUNTU 14.04
« Reply #7 on: February 27, 2018, 10:34:56 AM »
Dear sir, I compiled the source code successfully. Hex has been created but size is little bigger for stm32f103c8t6 having only 64k for flash memory. I have used minimal configuration for that still its not fitting on it. Give any solution for it.  :)




Daniel

  • Administrator
  • Interested
  • *****
  • Posts: 37
  • Karma: +0/-0
    • View Profile
Re: Unable to configure DNX RTOS on UBUNTU 14.04
« Reply #8 on: March 06, 2018, 07:41:39 PM »
Remove unused programs (from src/application/programs directory) and disable unused functionality e.g. network, file systems, drivers, etc by using Configtool (./configure).

Run Configtool (./configure) and configure options:
- Operating System: set Length of errno messages to: Only number
- File systems: enable only ramfs
- Network: disable subsystem
- Microcontroller: enable only required drivers

Programs to remove:
- tcl
- usbdevmouse
- telnetd
- sntpd
- mount
- umount
- mkfifo
- storinit
- ifconfig
- time
- sync
- mknod
- chmod
- date
- timechg
- date
- more
- hexdump

You can also remove more programs, you can even left only one program e.g. initd (with own code). But for tests nice to have dsh to enjoy with terminal.
« Last Edit: March 06, 2018, 08:00:06 PM by Daniel »