make with ubuntu

Hello all,

 

I’m trying to ‘make’ my 8bit app hex (skeleton), on a fresh ubuntu 14.04 installation, but i have some newbie troubles.

 

 

Here’s my console output

e6440@e6440-Latitude-E6440:~/MIOS/sdcc_skeleton_v1_1$ make
rm -rf _output/*
rm -rf _output
rm -rf *.cod *.map *.lst
rm -rf *.hex
mkdir -p _output
sh ./bin/mios-gpasm -c -p p18f452 -I./src -I ./include/asm -I ./include/share -I ./modules/debug_msg -I ./modules/app_lcd/dummy -DDEBUG_MODE=0  -DSTACK_HEAD=0x37f -DSTACK_IRQ_HEAD=0x33f -I ./modules/mios_wrapper modules/mios_wrapper/mios_wrapper.asm  -o _output/mios_wrapper.o
./bin/mios-gpasm: 24: ./bin/mios-gpasm: declare: not found
./bin/mios-gpasm: 27: ./bin/mios-gpasm: declare: not found
./bin/mios-gpasm: 37: ./bin/mios-gpasm: Syntax error: "(" unexpected (expecting "fi")
make: *** [_output/mios_wrapper.o] Error 2

 

I have installed sdcc/gputils, (http://www.midibox.org/dokuwiki/doku.php?id=installing_gputils_and_sdcc_on_ubuntu_8.04)

http://discourse.midibox.org/t/topic/12081

 

Can anyone help ?

 

Cheers

If I’m not mistaken, you need to use bash instead of sh:

 

http://unix.stackexchange.com/questions/17727/why-does-my-shell-script-give-the-error-declare-not-found

http://ubuntuforums.org/showthread.php?t=1658965

 

I find Googling compiler error output often very helpful.

Thanks sneakthief !

 

You were right, and i must confess that i did not search very hard…

 

In common.mk i found this comment/solution :

 

# if MIOS_SHELL environment variable hasn't been set by the user, set it here
# Ubuntu users should set it to /bin/bash from external (-> "export MIOS_SHELL /bin/bash")

 

http://discourse.midibox.org/t/topic/16560

 

:slight_smile: