skedar |
08-10-2010 02:16 PM |
cmem.c:38:19: error: stdio.h: No such file or directory
I am trying to compile a memory map module cmem.ko from TI codec tools. This is for the DSPlink software development for the OMAP3530. I am compiling this on the host(Ubuntu). First error could not find cc1 and i re-installed gcc and added it to the path. That fixed that error but then I get to this:
cmem.c:38:19: error: stdio.h: No such file or directory
cmem.c:39:20: error: unistd.h: No such file or directory
cmem.c:40:22: error: sys/mman.h: No such file or directory
cmem.c:41:23: error: sys/types.h: No such file or directory
cmem.c:42:22: error: sys/stat.h: No such file or directory
cmem.c:43:23: error: sys/ioctl.h: No such file or directory
cmem.c:44:19: error: fcntl.h: No such file or directory
cmem.c:45:19: error: errno.h: No such file or directory
cmem.c:46:20: error: string.h: No such file or directory
Things I have tried:
1. build-essential is up to date (suppose to work but not)
2.
Quote:
locate stdio.h
/home/amir/.local/share/Trash/files/OMAP35x-PSP-SDK-02.01.01.08/src/kernel/linux-02.01.01.08/arch/powerpc/boot/stdio.h
/home/amir/.local/share/Trash/files/OMAP35x-PSP-SDK-02.01.01.08/src/kernel/linux-02.01.01.08/arch/powerpc/xmon/nonstdio.h
/home/amir/Desktop/AM35x-OMAP35x-PSP-SDK-03.00.01.06/src/kernel/linux-03.00.01.06/arch/powerpc/boot/stdio.h
/home/amir/Desktop/AM35x-OMAP35x-PSP-SDK-03.00.01.06/src/kernel/linux-03.00.01.06/arch/powerpc/xmon/nonstdio.h
/home/amir/Desktop/CodeSourcery/Sourcery_G++_Lite/arm-none-linux-gnueabi/include/c++/4.4.1/tr1/stdio.h
/home/amir/Desktop/CodeSourcery/Sourcery_G++_Lite/arm-none-linux-gnueabi/libc/usr/include/stdio.h
/home/amir/Desktop/CodeSourcery/Sourcery_G++_Lite/arm-none-linux-gnueabi/libc/usr/include/bits/stdio.h
/home/amir/Desktop/OLD CGTOOLS/include/stdio.h
/home/amir/TI/CGTOOLS/include/stdio.h
/home/amir/TI/PSP/OMAP35x-PSP-SDK-02.01.01.08/src/kernel/linux-02.01.01.08/arch/powerpc/boot/stdio.h
/home/amir/TI/PSP/OMAP35x-PSP-SDK-02.01.01.08/src/kernel/linux-02.01.01.08/arch/powerpc/xmon/nonstdio.h
/home/amir/TI/TOOLCHAIN/arm-none-linux-gnueabi/include/c++/4.3.2/tr1/stdio.h
/home/amir/TI/TOOLCHAIN/arm-none-linux-gnueabi/libc/usr/include/stdio.h
/home/amir/TI/TOOLCHAIN/arm-none-linux-gnueabi/libc/usr/include/bits/stdio.h
/home/amir/linux-2.6.34/arch/powerpc/boot/stdio.h
/home/amir/linux-2.6.34/arch/powerpc/xmon/nonstdio.h
/usr/include/stdio.h
/usr/include/bits/stdio.h
/usr/include/c++/4.4/tr1/stdio.h
/usr/lib/perl/5.10.1/CORE/nostdio.h
|
3. echo $PATH
Quote:
/home/amir/TI/TOOLCHAIN/libexec/gcc/arm-none-linux-gnueabi/4.3.2:/home/amir/overo-oe/bitbake/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games
|
Here is my Rules.mk that I edited for my kernel and toolchain
Quote:
# Where to copy the resulting executables and data to (when executing 'make
# install') in a proper file structure. This EXEC_DIR should either be visible
# from the target, or you will have to copy this (whole) directory onto the
# target filesystem.
EXEC_DIR=/opt/mv_pro_4.0/montavista/pro/devkit/arm/v5t_le/target/opt/dvevm
# The prefix to be added before the GNU compiler tools (optionally including
# path), i.e. "arm_v5t_le-" or "/opt/bin/arm_v5t_le-".
MVTOOL_PREFIX=/home/amir/TI/TOOLCHAIN/arm-none-linux-gnueabi/bin/
# Equivalent path for uClibc compiler tools
#UCTOOL_PREFIX=/db/toolsrc/library/vendors2005/opensource/buildroot/10122007/build_arm/staging_dir/usr/bin/arm-linux-
# The directory that points to your kernel source directory. This is used
# for building the kernel module, as the kernel's build system
# gets invoked. Note that this also means that the below C_FLAGS etc. will
# be ignored when building this particular module.
LINUXKERNEL_INSTALL_DIR=/home/amir/PSP/OMAP35x-PSP-SDK-02.01.01.08/src/kernel/linux-02.01.01.08
# If we're a subcomponent, allow larger product settings to over-ride our
# defaults.
-include ../../../../../../../../Rules.make
# Whether or not to use the udev pseudo filesystem to generate the /dev
# filesystem for kernel modules. This depends on your kernel configuration.
# If udev is not used, the /dev files have to be created manually using mknod.
USE_UDEV=1
# The maximum number of memory pools for cmem.
MAX_POOLS=128
|
4. locate libc6-dev (another solution that doesnt work for me)
Quote:
/usr/share/doc/libc6-dev
/usr/share/doc/libc6-dev/CONFORMANCE.gz
/usr/share/doc/libc6-dev/FAQ.gz
/usr/share/doc/libc6-dev/NAMESPACE
/usr/share/doc/libc6-dev/NOTES.gz
/usr/share/doc/libc6-dev/README.libm.gz
/usr/share/doc/libc6-dev/changelog.Debian.gz
/usr/share/doc/libc6-dev/changelog.gz
/usr/share/doc/libc6-dev/copyright
/usr/share/lintian/overrides/libc6-dev
/var/lib/dpkg/info/libc6-dev.list
/var/lib/dpkg/info/libc6-dev.md5sums
|
Thanks.
Thanks in advance.
|