discuss-gnuradio
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Discuss-gnuradio] Include guard bug


From: Marcus Müller
Subject: Re: [Discuss-gnuradio] Include guard bug
Date: Fri, 21 Feb 2014 17:58:55 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.2.0

Well don't worry, it wasn't actually causing problems ;)

After fixing, I got out my zsh-foo and tried
echo $(( $(git ls-files |grep .h$|xargs git grep --heading "#ifndef INCLUDED"|wc -l) - $(git ls-files |grep .h$|xargs git grep --heading "#ifndef INCLUDED"| uniq | wc -l) ))
luckily, there are no duplicate lines containing #ifndef INCLUDED, so I'm hopeful enough everything else is fine in current master.

I agree on the #pragma once suggestion, and choose to believe http://en.wikipedia.org/wiki/Pragma_once#Portability which says that we should maybe suggest that people move away from gcc 3.4.
Although I don't think this would break a relevant numbers of GNU Radio environments, it could be something maintainers might want to save up for 3.8 or 4 ;)

Greetings,
Marcus

On 02/21/2014 05:32 PM, Tim wrote:
good find, this was probably my fault - sorry
We should consider changing headers to use "#pragma once" which is simpler and less error prone
do people still use gcc older than 3.4 ?  I think this is pretty widely supported now
not sure if that would cause swig issues as well -
-Tim

On 02/21/2014 10:51 AM, Marcus Müller wrote:
Ruecan:
I got carried away. This is indeed a bugfix for the header file not being processed in some cases, but since the error appeared although actually processing the fixed header file, I've run out of ideas, still.

On 02/21/2014 04:37 PM, Marcus Müller wrote:
Should be :)
Just as side info:
http://www.boost.org/doc/libs/1_54_0/doc/html/boost/random/mt19937.html

Sorry, totally running low on clues here...
This is twice as strange since boost::random is missing mt19937; if it was std:: I'd guess on a non-C++11 standard library, but like it is...
If cleaning and rebuilding doesn't help, make sure that libstdc++-devel is correctly installed

Basically, it should be right here:
http://www.boost.org/doc/libs/1_54_0/boost/random/mersenne_twister.hpp
and is included.


AAAAAAAAAAAND bam.
Found the bug. header include protection by #ifdef at the very beginning of the file.
you might pull my bugfix from https://github.com/marcusmueller/gnuradio.git;

git pull https://github.com/marcusmueller/gnuradio.git master_fix_message_strobe_random_ifndef

Greetings,
Marcus

On 02/21/2014 04:00 PM, Ruecan wrote:
Thanks Marcus,

Actually the boost version I have is 1.54.0.

Is this ok ?



--
View this message in context: http://gnuradio.4.n7.nabble.com/Issue-while-installing-GR-3-7-tp46435p46451.html
Sent from the GnuRadio mailing list archive at Nabble.com.

_______________________________________________
Discuss-gnuradio mailing list
address@hidden
https://lists.gnu.org/mailman/listinfo/discuss-gnuradio



_______________________________________________
Discuss-gnuradio mailing list
address@hidden
https://lists.gnu.org/mailman/listinfo/discuss-gnuradio



_______________________________________________
Discuss-gnuradio mailing list
address@hidden
https://lists.gnu.org/mailman/listinfo/discuss-gnuradio



reply via email to

[Prev in Thread] Current Thread [Next in Thread]