This is the mail archive of the
ecos-discuss@sourceware.org
mailing list for the eCos project.
error in compiling hello ecos world program
- From: abhishek srivastava <just_abhi22 at yahoo dot co dot in>
- To: ecos discuss <ecos-discuss at sourceware dot org>
- Date: Sat, 30 Jun 2012 05:05:15 +0800 (SGT)
- Subject: [ECOS] error in compiling hello ecos world program
- Reply-to: abhishek srivastava <just_abhi22 at yahoo dot co dot in>
hi
while compiling basic.c (hello ecos world) program, i am getting following error.why?
abhi@abhi-HP:~/Desktop/working_ecos/basic_app$ export PATH=/home/abhi/ecos/gnutools/i386-elf/bin:$PATH
abhi@abhi-HP:~/Desktop/working_ecos/basic_app$ make
i386-elf-gcc -c -o basic1.o -g -Wall -I/home/abhi/Desktop/work_ecos/ecos_install/include -ffunction-sections -fdata-sections basic1.c
basic1.c:21:44: error: cyg/kernel/kapi.h: No such file or directory
basic1.c:22:57: error: cyg/infra/diag.h: No such file or directory
basic1.c:35: error: expected â=â, â,â, â;â, âasmâ or â__attribute__â before âthread_a_objâ
basic1.c:36: error: expected â=â, â,â, â;â, âasmâ or â__attribute__â before âthread_b_objâ
basic1.c:37: error: expected â=â, â,â, â;â, âasmâ or â__attribute__â before âthread_a_hdlâ
basic1.c:38: error: expected â=â, â,â, â;â, âasmâ or â__attribute__â before âthread_b_hdlâ
basic1.c:40: error: expected â=â, â,â, â;â, âasmâ or â__attribute__â before âsem_signal_threadâ
basic1.c:48: error: expected â)â before âdataâ
basic1.c:72: error: expected â)â before âdataâ
basic1.c: In function âcyg_user_startâ:
basic1.c:98: warning: implicit declaration of function âdiag_printfâ
basic1.c:102: warning: implicit declaration of function âcyg_semaphore_initâ
basic1.c:102: error: âsem_signal_threadâ undeclared (first use in this function)
basic1.c:102: error: (Each undeclared identifier is reported only once
basic1.c:102: error: for each function it appears in.)
basic1.c:107: warning: implicit declaration of function âcyg_thread_createâ
basic1.c:109: error: âthread_aâ undeclared (first use in this function)
basic1.c:110: error: âcyg_addrword_tâ undeclared (first use in this function)
basic1.c:110: error: expected â)â before numeric constant
basic1.c:119: error: âthread_bâ undeclared (first use in this function)
basic1.c:120: error: expected â)â before numeric constant
basic1.c:129: warning: implicit declaration of function âcyg_thread_resumeâ
basic1.c:129: error: âthread_a_hdlâ undeclared (first use in this function)
basic1.c:130: error: âthread_b_hdlâ undeclared (first use in this function)
make: *** [basic1.o] Error 1
in Make file, i have added path as
PKG_INSTALL_DIR = /home/abhi/Desktop/work_ecos/ecos_install
XCC =i386-elf-gcc
## Build flags.
CFLAGSÂÂÂ = -g -Wall -I$(PKG_INSTALL_DIR)/include -ffunction-sections -fdata-sections
LDFLAGSÂÂÂ = -nostartfiles -L$(PKG_INSTALL_DIR)/lib -Wl,--gc-sections -Wl,--Map -Wl,basic1.map
LIBSÂÂÂ = -Ttarget.ld -nostdlib
LDÂÂÂ ÂÂÂ = $(XCC)
.....etc
please help.
Abhishek
--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss