From: Robert Staven <robert@stopthespam_remove.staven.no>
To: linuxppc-embedded@ozlabs.org
Subject: Problem inkluding *.h files when compiling module
Date: Wed, 02 May 2007 19:46:03 +0200 [thread overview]
Message-ID: <4638CE5B.2090803@stopthespam_remove.staven.no> (raw)
I suspect this is slightly 'off topic' but have seen similar threads in
the lists archive so I go for it.
Testing some code (UDP by sockets example), and it compiles and works
great on both host(i386) and target (mpc8250)
I move the code to a module I'm working on and when I compile (for the
embedded platform) some of the needed header files is not found.
I suspect this is cause I'm missing some basic understanding of how
gcc/makefile/compiling modules works. But can't find any useful info.
Snip from my makefile:
KDIR := /home/mykernel/linuxppc-2.6
SDIR := /home/prog/sdlc
default:
$(MAKE) -C $(KDIR) SUBDIRS=$(SDIR) modules
The KDIR is the problem, header files not found is under this dir (or
sub dirs).
But KDIR is supposed to point to my kernel source, isn't it?
Checking with gcc I find the places to look for my header files:
# powerpc-linux-gcc -print-search-dirs
<snip>
libraries: =
/opt/amltd/powerpc-linux/gcc-3.4.3-glibc-2.3.5/lib/gcc/powerpc-linux/3.4.3/:
/usr/lib/gcc/powerpc-linux/3.4.3/:
/opt/amltd/powerpc-linux/gcc-3.4.3-glibc-2.3.5/lib/gcc/powerpc-linux/3.4.3/../../../../powerpc-linux/lib/powerpc-linux/3.4.3/:
/opt/amltd/powerpc-linux/gcc-3.4.3-glibc-2.3.5/lib/gcc/powerpc-linux/3.4.3/../../../../powerpc-linux/lib/
But these dirs dosn't have my kernel source (as needed by KDIR)?
Any way to give the makefile several paths to search for files needed?
Grateful for any tips, places to find info or more relevant mail-lists!
br
Robert Staven
reply other threads:[~2007-05-02 17:46 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4638CE5B.2090803@stopthespam_remove.staven.no \
--to=robert@stopthespam_remove.staven.no \
--cc=linuxppc-embedded@ozlabs.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox