Re: gcc 4.7 changes binary behaviors ?

2012-01-27 Thread Kevin Kofler
Sérgio Basto wrote:
 kmk_sed is based based on sed 4.1.5 but is very modified, for support
 others OS like ms windows , darwin etc .

We don't care about those other OSes! Our binaries will only run on Fedora 
anyway.

Please make your package use the system version of sed.

Kevin Kofler

-- 
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel

Re: gcc 4.7 changes binary behaviors ?

2012-01-26 Thread Jan Kratochvil
On Thu, 26 Jan 2012 08:12:43 +0100, Sérgio Basto wrote:
 /usr/bin/kmk_sed: file 
 /builddir/build/BUILD/VirtualBox-4.1.8_OSE/src/VBox/Runtime/common/err/errmsg.sed
  line 31: Unmatched [ or [^
 kmk: *** 
 [/builddir/build/BUILD/VirtualBox-4.1.8_OSE/obj/obj/Runtime/errmsgdata.h] 
 Error 1
 kmk: *** Deleting file 
 `/builddir/build/BUILD/VirtualBox-4.1.8_OSE/obj/obj/Runtime/errmsgdata.h'
 kmk: *** Waiting for unfinished jobs
 
 build virtualbox with same kBuild but that was build with gcc 4.6 I
 don't have this problem using kBuild-0.1.98-1.r1.fc17 works, using
 kBuild-0.1.98-2.r1.fc17 I got this error, with kmk_sed. 
 Any clue is appreciated 

kmk_sed is most probably using some undefined C behavior which only
fortunately worked with gcc-4.6.  You should try compiling kmk_sed first with
-O0 and then checking whether the specific function having this problem there
is really valid ISO C.

As an illustration gcore also broke with gcc-4.7 but it was a bug of gcore:
http://sourceware.org/ml/binutils/2011-12/msg00298.html


Regards,
Jan
-- 
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel

Re: gcc 4.7 changes binary behaviors ?

2012-01-26 Thread Jakub Jelinek
On Thu, Jan 26, 2012 at 07:12:43AM +, Sérgio Basto wrote:
 Hi, hope that also could help 
 
 Has package builder we also build kBuid 
 http://koji.fedoraproject.org/koji/packageinfo?packageID=7356
 , after use kBuid compile with gcc 4.7 I got this error on building
 virtuaBox
 
 /usr/bin/kmk_sed: file 
 /builddir/build/BUILD/VirtualBox-4.1.8_OSE/src/VBox/Runtime/common/err/errmsg.sed
  line 31: Unmatched [ or [^
 kmk: *** 
 [/builddir/build/BUILD/VirtualBox-4.1.8_OSE/obj/obj/Runtime/errmsgdata.h] 
 Error 1
 kmk: *** Deleting file 
 `/builddir/build/BUILD/VirtualBox-4.1.8_OSE/obj/obj/Runtime/errmsgdata.h'
 kmk: *** Waiting for unfinished jobs
 
 build virtualbox with same kBuild but that was build with gcc 4.6 I
 don't have this problem using kBuild-0.1.98-1.r1.fc17 works, using
 kBuild-0.1.98-2.r1.fc17 I got this error, with kmk_sed. 
 Any clue is appreciated 

That just clearly shows how bundling libraries (violation of Fedora
packaging guidelines) is harmful.
Apparently, kBuild/src/sed/lib contains a copy of sed? regex code
which is a copy of the glibc code (but I hope sed is configured to
use the system regex), so it hits the same problem as has been already fixed
in glibc:
http://sources.redhat.com/ml/libc-alpha/2011-12/msg00091.html
Please file bugs against kBuild and possibly against sed too.

Jakub
-- 
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel

Re: gcc 4.7 changes binary behaviors ?

2012-01-26 Thread Sérgio Basto
On Thu, 2012-01-26 at 21:15 +0100, Jakub Jelinek wrote: 
 On Thu, Jan 26, 2012 at 07:12:43AM +, Sérgio Basto wrote:
  Hi, hope that also could help 
  
  Has package builder we also build kBuid 
  http://koji.fedoraproject.org/koji/packageinfo?packageID=7356
  , after use kBuid compile with gcc 4.7 I got this error on building
  virtuaBox
  
  /usr/bin/kmk_sed: file 
  /builddir/build/BUILD/VirtualBox-4.1.8_OSE/src/VBox/Runtime/common/err/errmsg.sed
   line 31: Unmatched [ or [^
  kmk: *** 
  [/builddir/build/BUILD/VirtualBox-4.1.8_OSE/obj/obj/Runtime/errmsgdata.h] 
  Error 1
  kmk: *** Deleting file 
  `/builddir/build/BUILD/VirtualBox-4.1.8_OSE/obj/obj/Runtime/errmsgdata.h'
  kmk: *** Waiting for unfinished jobs
  
  build virtualbox with same kBuild but that was build with gcc 4.6 I
  don't have this problem using kBuild-0.1.98-1.r1.fc17 works, using
  kBuild-0.1.98-2.r1.fc17 I got this error, with kmk_sed. 
  Any clue is appreciated 
 
 That just clearly shows how bundling libraries (violation of Fedora
 packaging guidelines) is harmful.

I'd rather build virtualbox with binaries of kmk_sed provide by
virtualbox, than put this kBuild package on fedora and build it from
sources. Is just a waste of time.

but yeah, not my fault, but diff 
/var/lib/mock/fedora-rawhide-x86_64/root/builddir/build/BUILD/kBuild-0.1.9998/src/sed
 
and
~/rpmbuild/SOURCES/sed-4.2.1 
have 147 identical files 

NEWS says that is Sed 4.1.5 

Thanks for the tip , I will see what I can do about not bundle sed . 

 Apparently, kBuild/src/sed/lib contains a copy of sed? regex code
 which is a copy of the glibc code (but I hope sed is configured to
 use the system regex),
  so it hits the same problem as has been already fixed
 in glibc:
 http://sources.redhat.com/ml/libc-alpha/2011-12/msg00091.html
 Please file bugs against kBuild and possibly against sed too.
   Jakub

-- 
Sérgio M. B.

-- 
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel

Re: gcc 4.7 changes binary behaviors ?

2012-01-26 Thread Sérgio Basto
On Thu, 2012-01-26 at 22:01 +, Sérgio Basto wrote:
 On Thu, 2012-01-26 at 21:15 +0100, Jakub Jelinek wrote: 
  On Thu, Jan 26, 2012 at 07:12:43AM +, Sérgio Basto wrote:
   Hi, hope that also could help 
   
   Has package builder we also build kBuid 
   http://koji.fedoraproject.org/koji/packageinfo?packageID=7356
   , after use kBuid compile with gcc 4.7 I got this error on building
   virtuaBox
   
   /usr/bin/kmk_sed: file 
   /builddir/build/BUILD/VirtualBox-4.1.8_OSE/src/VBox/Runtime/common/err/errmsg.sed
line 31: Unmatched [ or [^
   kmk: *** 
   [/builddir/build/BUILD/VirtualBox-4.1.8_OSE/obj/obj/Runtime/errmsgdata.h] 
   Error 1
   kmk: *** Deleting file 
   `/builddir/build/BUILD/VirtualBox-4.1.8_OSE/obj/obj/Runtime/errmsgdata.h'
   kmk: *** Waiting for unfinished jobs
   
   build virtualbox with same kBuild but that was build with gcc 4.6 I
   don't have this problem using kBuild-0.1.98-1.r1.fc17 works, using
   kBuild-0.1.98-2.r1.fc17 I got this error, with kmk_sed. 
   Any clue is appreciated 
  
  That just clearly shows how bundling libraries (violation of Fedora
  packaging guidelines) is harmful.
 
 I'd rather build virtualbox with binaries of kmk_sed provide by
 virtualbox, than put this kBuild package on fedora and build it from
 sources. Is just a waste of time.
 
 but yeah, not my fault, but diff 
 /var/lib/mock/fedora-rawhide-x86_64/root/builddir/build/BUILD/kBuild-0.1.9998/src/sed
  
 and
 ~/rpmbuild/SOURCES/sed-4.2.1 
 have 147 identical files 
 
 NEWS says that is Sed 4.1.5 
 
 Thanks for the tip , I will see what I can do about not bundle sed .

 
kmk_sed is based based on sed 4.1.5 but is very modified, for support
others OS like ms windows , darwin etc . 


  Apparently, kBuild/src/sed/lib contains a copy of sed? regex code
  which is a copy of the glibc code (but I hope sed is configured to
  use the system regex),
   so it hits the same problem as has been already fixed
  in glibc:
  http://sources.redhat.com/ml/libc-alpha/2011-12/msg00091.html
  Please file bugs against kBuild and possibly against sed too.
  Jakub
 



-- 
Sérgio M. B.


-- 
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel

Re: gcc 4.7 changes binary behaviors ?

2012-01-26 Thread Rahul Sundaram
On 01/27/2012 08:55 AM, Sérgio Basto wrote:

 kmk_sed is based based on sed 4.1.5 but is very modified, for support
 others OS like ms windows , darwin etc . 

Have they tried to get the patches merged upstream?

Rahul
-- 
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel

Re: gcc 4.7 changes binary behaviors ?

2012-01-26 Thread Sérgio Basto
On Thu, 2012-01-26 at 12:08 +0100, Jan Kratochvil wrote: 
 On Thu, 26 Jan 2012 08:12:43 +0100, Sérgio Basto wrote:
  /usr/bin/kmk_sed: file 
  /builddir/build/BUILD/VirtualBox-4.1.8_OSE/src/VBox/Runtime/common/err/errmsg.sed
   line 31: Unmatched [ or [^
  kmk: *** 
  [/builddir/build/BUILD/VirtualBox-4.1.8_OSE/obj/obj/Runtime/errmsgdata.h] 
  Error 1
  kmk: *** Deleting file 
  `/builddir/build/BUILD/VirtualBox-4.1.8_OSE/obj/obj/Runtime/errmsgdata.h'
  kmk: *** Waiting for unfinished jobs
  
  build virtualbox with same kBuild but that was build with gcc 4.6 I
  don't have this problem using kBuild-0.1.98-1.r1.fc17 works, using
  kBuild-0.1.98-2.r1.fc17 I got this error, with kmk_sed. 
  Any clue is appreciated 
 
 kmk_sed is most probably using some undefined C behavior which only
 fortunately worked with gcc-4.6.  

and others gcc  4.6 

 You should try compiling kmk_sed first with
 -O0 and then checking whether the specific function having this problem there
 is really valid ISO C.

don't understand whats help compile without optimization , which btw my
tests said that also doesn't work kbuild with -O0.

I checked the other email tip about kmk_sed, and conclusion kbuild
bundle a sed based on 4.1.5 but very modified. 

 As an illustration gcore also broke with gcc-4.7 but it was a bug of gcore:
   http://sourceware.org/ml/binutils/2011-12/msg00298.html

as the code violates ISO C99 6.2.4 item 5 by using local variable
outside of 
its block, GCC optimizes out the second memcpy, keeping there only that
memset.

well kmk_sed code not have necessary to be ISO C99, which could be a tip
try compile kbuild without change behavior of gcc  4.7 

or try to find what is not compatible , with some cflgs ... 

The solution was patch sed file to not use or remove  GNU/POSIX
extensions to regular expressions ...

UPDATE :
sed seems that stop work at all , nothing is replaced ! 

 Regards,
 Jan

-- 
Sérgio M. B.


-- 
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel

Re: gcc 4.7 changes binary behaviors ?

2012-01-26 Thread Sérgio Basto
On Fri, 2012-01-27 at 05:22 +, Sérgio Basto wrote:
 UPDATE :
 sed seems that stop work at all , nothing is replaced ! 

sorry this is not true.

-- 
Sérgio M. B.

-- 
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel

Re: gcc 4.7 changes binary behaviors ?

2012-01-26 Thread Ralf Corsepius

On 01/27/2012 06:22 AM, Sérgio Basto wrote:

On Thu, 2012-01-26 at 12:08 +0100, Jan Kratochvil wrote:

On Thu, 26 Jan 2012 08:12:43 +0100, Sérgio Basto wrote:

/usr/bin/kmk_sed: file 
/builddir/build/BUILD/VirtualBox-4.1.8_OSE/src/VBox/Runtime/common/err/errmsg.sed
 line 31: Unmatched [ or [^
kmk: *** 
[/builddir/build/BUILD/VirtualBox-4.1.8_OSE/obj/obj/Runtime/errmsgdata.h] Error 
1
kmk: *** Deleting file 
`/builddir/build/BUILD/VirtualBox-4.1.8_OSE/obj/obj/Runtime/errmsgdata.h'



You should try compiling kmk_sed first with
-O0 and then checking whether the specific function having this problem there
is really valid ISO C.


don't understand whats help compile without optimization ,


-O0 turns off optimizations. i.e. it causes GCC to behave less 
agressively and often causes sloppily written code to behave as 
expected and not to expose a run-time bug.


It's a common initial step when trying to isolate the cause of a bug.


Another, similar initial step is to check build logs for warnings and to 
go after them. These days, e.g. warnings related to punned pointers or 
casts to different sizes often are pointing to the causes of run-time 
mal-functions and should not be taken light-heartedly.


Ralf
--
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel

Re: gcc 4.7 changes binary behaviors ?

2012-01-26 Thread Matej Cepl

On 27.1.2012 06:22, Sérgio Basto wrote:

I checked the other email tip about kmk_sed, and conclusion kbuild
bundle a sed based on 4.1.5 but very modified.


You surely didn't mean to include bundled version of the system sed in 
your package, did you? I can immediately guess that FPC ticket 
requesting an exception for non-bundling policy (required by the Fedora 
packaging guidelines) will not get much favor with FPC.


Matěj

--
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel

Re: gcc 4.7 changes binary behaviors ?

2012-01-26 Thread Jakub Jelinek
On Fri, Jan 27, 2012 at 05:22:20AM +, Sérgio Basto wrote:
  As an illustration gcore also broke with gcc-4.7 but it was a bug of gcore:
  http://sourceware.org/ml/binutils/2011-12/msg00298.html
 
 as the code violates ISO C99 6.2.4 item 5 by using local variable
 outside of 
 its block, GCC optimizes out the second memcpy, keeping there only that
 memset.
 
 well kmk_sed code not have necessary to be ISO C99, which could be a tip
 try compile kbuild without change behavior of gcc  4.7 

My complain about bundling of libraries etc. was just a generic one, if
for some particular reasons you can't stop doing that, you need to apply the
patch I've referenced in my earlier mail to kBuild sources as well.
It is triggering undefined behavior too, by lying to the compiler
that a function is pure (a function that only uses its arguments and can
read memory in order to return result, but can't modify global state)
when it modifies memory.

Jakub
-- 
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel