OpenSceneGraph Forum Forum Index OpenSceneGraph Forum
Official forum which mirrors the existent OSG mailing lists. Messages posted here are forwarded to the mailing list and vice versa.
 
   FAQFAQ    SearchSearch    MemberlistMemberlist    RulesRules    UsergroupsUsergroups    RegisterRegister 
 Mail2Forum SettingsMail2Forum Settings  ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
   AlbumAlbum  OpenSceneGraph IRC ChatOpenSceneGraph IRC Chat   SmartFeedSmartFeed 

#include <string> on MSVC results in errors


 
Post new topic   Reply to topic    OpenSceneGraph Forum Forum Index -> General
View previous topic :: View next topic  
Author Message
Voerman, L.
Guest





PostPosted: Tue Jul 11, 2017 11:28 am    Post subject:
#include <string> on MSVC results in errors
Reply with quote

Hi Bruno,it's very uncommon to have subfolder of osginclude in your include path, like includeosgText.
The normal configuration has something like E:devOpenSceneGraphinclude in the project include path, and requests the use of the osgTextString with:
#include <osgText/String>



this way there will be no confusion with the system string haeder files.
Regards, Laurens.


On Tue, Jul 11, 2017 at 12:57 PM, Bruno Oliveira < (
Only registered users can see emails on this board!
Get registred or enter the forums!
)> wrote:
Quote:
Hello,


Windows is not case sentitive, hence, on MSVC 2015,


#include <string>


is the same as


#include <String>


For this reason, I am including <string> to get std::string definitions, but MSVC is include <String> from OSG.


Is there a way to fix this? I'm sure this has happened to more people.



_______________________________________________
osg-users mailing list
(
Only registered users can see emails on this board!
Get registred or enter the forums!
)
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org



------------------
Post generated by Mail2Forum
Back to top
Bruno Oliveira
Guest





PostPosted: Tue Jul 11, 2017 3:28 pm    Post subject:
#include <string> on MSVC results in errors
Reply with quote

I agree. However, somehow, using CMake, the include/osgDB folder got appended to the include path.... This did not happen previously


2017-07-11 12:13 GMT+01:00 Voerman, L. < (
Only registered users can see emails on this board!
Get registred or enter the forums!
)>:
Quote:
Hi Bruno,it's very uncommon to have subfolder of osginclude in your include path, like includeosgText.
The normal configuration has something like E:devOpenSceneGraphinclude in the project include path, and requests the use of the osgTextString with:
#include <osgText/String>



this way there will be no confusion with the system string haeder files.
Regards, Laurens.


On Tue, Jul 11, 2017 at 12:57 PM, Bruno Oliveira < (
Only registered users can see emails on this board!
Get registred or enter the forums!
)> wrote:


Quote:
Hello,


Windows is not case sentitive, hence, on MSVC 2015,


#include <string>


is the same as


#include <String>


For this reason, I am including <string> to get std::string definitions, but MSVC is include <String> from OSG.


Is there a way to fix this? I'm sure this has happened to more people.





_______________________________________________
osg-users mailing list
(
Only registered users can see emails on this board!
Get registred or enter the forums!
)
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org





_______________________________________________
osg-users mailing list
(
Only registered users can see emails on this board!
Get registred or enter the forums!
)
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org



------------------
Post generated by Mail2Forum
Back to top
Bruno Oliveira
Guest





PostPosted: Tue Jul 11, 2017 7:28 pm    Post subject:
#include <string> on MSVC results in errors
Reply with quote

This is how I add the include folders of OSG on CMake

include_directories ( ${OPENSCENEGRAPH_INCLUDE_DIRS} )


is this correct?




2017-07-11 12:51 GMT+01:00 Bruno Oliveira < (
Only registered users can see emails on this board!
Get registred or enter the forums!
)>:
Quote:
I agree. However, somehow, using CMake, the include/osgDB folder got appended to the include path.... This did not happen previously


2017-07-11 12:13 GMT+01:00 Voerman, L. < (
Only registered users can see emails on this board!
Get registred or enter the forums!
)>:
Quote:
Hi Bruno,it's very uncommon to have subfolder of osginclude in your include path, like includeosgText.
The normal configuration has something like E:devOpenSceneGraphinclude in the project include path, and requests the use of the osgTextString with:
#include <osgText/String>



this way there will be no confusion with the system string haeder files.
Regards, Laurens.


On Tue, Jul 11, 2017 at 12:57 PM, Bruno Oliveira < (
Only registered users can see emails on this board!
Get registred or enter the forums!
)> wrote:


Quote:
Hello,


Windows is not case sentitive, hence, on MSVC 2015,


#include <string>


is the same as


#include <String>


For this reason, I am including <string> to get std::string definitions, but MSVC is include <String> from OSG.


Is there a way to fix this? I'm sure this has happened to more people.





_______________________________________________
osg-users mailing list
(
Only registered users can see emails on this board!
Get registred or enter the forums!
)
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org





_______________________________________________
osg-users mailing list
(
Only registered users can see emails on this board!
Get registred or enter the forums!
)
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org








------------------
Post generated by Mail2Forum
Back to top
Steal
User


Joined: 26 Jan 2017
Posts: 57

PostPosted: Wed Jul 12, 2017 9:13 am    Post subject:
Reply with quote

Hi,

Make sure you got the 3.4.0 branch and maybe even downgrade to a different cmake.

Thank you!

Cheers,
Johny
Back to top
View user's profile Send private message
Bruno Oliveira
Guest





PostPosted: Wed Jul 12, 2017 1:28 pm    Post subject:
#include <string> on MSVC results in errors
Reply with quote

Hello,


Windows is not case sentitive, hence, on MSVC 2015,


#include <string>


is the same as


#include <String>


For this reason, I am including <string> to get std::string definitions, but MSVC is include <String> from OSG.


Is there a way to fix this? I'm sure this has happened to more people.

------------------
Post generated by Mail2Forum
Back to top
Display posts from previous:   
Post new topic   Reply to topic    OpenSceneGraph Forum Forum Index -> General All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum

Similar Topics
Topic Author Forum Replies Posted
No new posts Plugins errors for unsupported files Riccardo Corsi General 4 Tue Oct 18, 2016 5:21 pm View latest post
No new posts Potential fix for osgDB MSVC linkage ... James Turner General 12 Sun Aug 07, 2016 1:01 pm View latest post
No new posts Compilation error with MSVC 2015 Jan Ciger General 5 Mon Jul 04, 2016 12:32 pm View latest post
No new posts Install msvc debug files along with t... Ralf Habacker Submission 2 Mon May 30, 2016 10:13 am View latest post
No new posts GraphicsWindowWin32 compiling errors ... Davide Raccagni Submission 4 Thu May 19, 2016 11:32 am View latest post


Board Security Anti Bot Question MOD - phpBB MOD against Spam Bots
Powered by phpBB © 2001, 2005 phpBB Group
Protected by Anti-Spam ACP