kastnermario / yaml-cpp

Automatically exported from code.google.com/p/yaml-cpp
MIT License
0 stars 0 forks source link

Doesn't build with gcc4.6 #103

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
Since Archlinux has upgraded to the new gcc4.6 I cannot build this anymore 
(from user repo or from svn sources).

Replacing every "NULL" with "nullptr" and enabling c++0x (in CMakeLists.txt, 
add "-std=c++0x" to "set(CMAKE_???_FLAGS...)") helps for me, but you will 
probably not want to use c++0x now.

What steps will reproduce the problem?
1. Compile it with gcc 4.6, svn head (r481)

What is the expected output? What do you see instead?
Expected: library. Result: error message:
src/ptr_vector.h:31:21: error: ‘NULL’ was not declared in this scope

Original issue reported on code.google.com by opatut...@googlemail.com on 30 Apr 2011 at 4:12

GoogleCodeExporter commented 8 years ago
Found this link for (probably better) fixes:
https://wiki.ubuntu.com/GCC4.6

Its Ubuntu not Arch, but who cares, it's about gcc4.6 :D

Original comment by opatut...@googlemail.com on 30 Apr 2011 at 4:15

GoogleCodeExporter commented 8 years ago
[deleted comment]
GoogleCodeExporter commented 8 years ago
Fixed (r482), I think, but I don't have gcc 4.6 on my machine, so I just 
followed your link's explanation, and added <cstdlib> whereever we use NULL. 
Can you verify that it compiles with no errors?

Original comment by jbe...@gmail.com on 3 May 2011 at 9:57

GoogleCodeExporter commented 8 years ago
Yes, it builds. Sadly the release has not been updated 
(http://yaml-cpp.googlecode.com/files/yaml-cpp-0.2.6.tar.gz) so I cannot use 
the package from the arch user repo (AUR) for a while but I built the package 
manually.

Original comment by opatut...@googlemail.com on 14 May 2011 at 8:03

GoogleCodeExporter commented 8 years ago
Thanks for confirming this. Since I updated to 0.2.6 very recently, and there 
are a couple outstanding issues I'd like to get to soon, I'm holding off on 
0.2.7 for a short while, but it'll be out relatively soon.

Thanks again!

Original comment by jbe...@gmail.com on 29 May 2011 at 5:18