From: Marco Atzeri <marco.atzeri@gmail.com>
To: cygwin@cygwin.com
Subject: Re: ushort definition
Date: Mon, 09 Jan 2017 23:05:00 -0000 [thread overview]
Message-ID: <ab3cccde-9008-5176-2ca9-a7ac10e56b9c@gmail.com> (raw)
In-Reply-To: <5920d91e-43c4-f57b-3711-e423879c6896@t-online.de>
On 09/01/2017 23:30, Hans-Bernhard Bröker wrote:
> Am 09.01.2017 um 20:46 schrieb Marco Atzeri:
>> On 09/01/2017 19:01, Hans-Bernhard Bröker wrote:
>
>
>> the "#define ushort unsigned short" is in the
>> /usr/include/jasper/jas_config.h
>>
>> It seems jasper configuration had not defined __MISC_VISIBLE,
>> while gdal does.
>
> Neither is supposed to #define __MISC_VISIBLE itself. cscope finds:
>
> $ cscope -dL1 __MISC_VISIBLE
> /usr/include/sys/features.h __MISC_VISIBLE 276 #define __MISC_VISIBLE 1
> /usr/include/sys/features.h __MISC_VISIBLE 278 #define __MISC_VISIBLE 0
>
> So let's look at a bit of context:
>
> $ sed -n -e '270,280p' /usr/include/sys/features.h
> #define __LARGEFILE_VISIBLE 1
> #else
> #define __LARGEFILE_VISIBLE 0
> #endif
>
> #ifdef _DEFAULT_SOURCE
> #define __MISC_VISIBLE 1
> #else
> #define __MISC_VISIBLE 0
> #endif
>
> I.e. if jasper didn't have __MISC_VISIBLE on, it must have overridden
> the default feature test state of _DEFAULT_SOURCE.
I will bet on a "-std=C99" somewhere
> The lesson to be had from all this: #defining types is just wrong. Don't
> do it. typedef exists to be used.
Thanks again
Marco
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
prev parent reply other threads:[~2017-01-09 23:05 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-01-09 16:48 Marco Atzeri
2017-01-09 16:59 ` Corinna Vinschen
2017-01-09 17:48 ` Marco Atzeri
2017-01-09 18:02 ` Hans-Bernhard Bröker
2017-01-09 19:47 ` Marco Atzeri
2017-01-09 22:31 ` Hans-Bernhard Bröker
2017-01-09 23:05 ` Marco Atzeri [this message]
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=ab3cccde-9008-5176-2ca9-a7ac10e56b9c@gmail.com \
--to=marco.atzeri@gmail.com \
--cc=cygwin@cygwin.com \
/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 read-only IMAP folder(s) and NNTP newsgroup(s).