Community
cancel
Showing results for 
Search instead for 
Did you mean: 
WHuan32
Beginner
1,132 Views

undefined reference to `__stdin' & undefined reference to `__fgetc_unlocked'

Hi,

I follow the quark-x1000-bsp-build-sw-rel-user-guide.pdf to build one toolchain installer, iot-devkit-eglibc-x86_64-image-full-i586-toolchain-1.6.1.sh; then I use following program to test it, and got two errors, what happened?

================================================================

# include

int main() {

printf("press a key...");

getchar();

}

================================================================

$ . /opt/iot-devkit/1.6.1/environment-setup-i586-poky-linux

$ $CC -o test test.c

/tmp/ccvHx0P4.o: In function `main':

test.c:(.text+0x16): undefined reference to `__stdin'

test.c:(.text+0x56): undefined reference to `__fgetc_unlocked'

collect2: error: ld returned 1 exit status

Best Regards

0 Replies
Reply