From: Shanks <mshanks79@yahoo.co.in>
To: Hossein Mobahi <hmobahi@yahoo.com>, linux-kernel@vger.kernel.org
Cc: linux-c-programming@vger.kernel.org
Subject: Re: problem with <asm/semaphore.h>
Date: Tue, 4 Jun 2002 04:44:21 -0700 (PDT) [thread overview]
Message-ID: <adi9k5$c4o$2@main.gmane.org> (raw)
In-Reply-To: <20020604111944.34250.qmail@web12708.mail.yahoo.com>
Hi Hossein,
If you look inside <asm/semaphore.h> you will see that
the definition of struct semaphore is within a
conditional #ifdef __KERNEL__
Hence __KERNEL__ needs to be defined for this code to
compile.
Try compiling like this
$> gcc -D__KERNEL__ file.c
Regards,
Shanks
--- Hossein Mobahi <hmobahi@yahoo.com> wrote:
> Hi
> I compiled the following code with gcc under Redhat
> 7.2 :
> #include <asm/semaphore.h>
> main()
> {
> struct semaphore sum;
> }
>
> It doesn't compile, saying "storage size of `sem'
> isn't known".
>
> Sincerely
> --Hossein Mobahi
__________________________________________________
Do You Yahoo!?
Yahoo! - Official partner of 2002 FIFA World Cup
http://fifaworldcup.yahoo.com
next prev parent reply other threads:[~2002-06-04 11:44 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-06-04 11:19 problem with <asm/semaphore.h> Hossein Mobahi
2002-06-04 11:44 ` Shanks [this message]
-- strict thread matches above, loose matches on Subject: below --
2002-06-04 11:41 bonganilinux
2002-06-04 11:44 ` Thomas 'Dent' Mirlacher
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='adi9k5$c4o$2@main.gmane.org' \
--to=mshanks79@yahoo.co.in \
--cc=hmobahi@yahoo.com \
--cc=linux-c-programming@vger.kernel.org \
--cc=linux-kernel@vger.kernel.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;
as well as URLs for NNTP newsgroup(s).