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 

Up to date tutorials for linux


 
Post new topic   Reply to topic    OpenSceneGraph Forum Forum Index -> General
View previous topic :: View next topic  
Author Message
Rodrigo
Newbie


Joined: 01 Mar 2017
Posts: 3

PostPosted: Wed Mar 01, 2017 9:57 pm    Post subject:
Up to date tutorials for linux
Reply with quote

Hi everybody,

I'm tyring to compile your tutorials on the wiki (can't send the links yet, this is my second post). I'm having some strange "Segmentation faults" that appear some times, disappear other times. I think it may be because these examples are rather old (8~9 years).

I'm using the latest Code::Blocks (16.01) for Debian Jessie, with GNU GCC Compiler.

Without clear instructions for Linux starters, I first downloaded the OpenSceneGraph-3.4.0.zip. Then I unzipped it and tried to compile using make/cmake. No success. Then I tried sudo apt-get install libopenscenegraph-dev openscenegraph. Not sure if the first is in conflict with the second, or where to find the proper libraries, includes, etc.

If you do a FREE, OPEN SOURCE project, I think you should have more Tutorials other than Windows and Mac OS. I will post some broken links as long as I'm allowed.

Thank you!

Cheers,
Rodrigo
Back to top
View user's profile Send private message
robertosfield
OSG Project Lead


Joined: 18 Mar 2009
Posts: 10791

PostPosted: Thu Mar 02, 2017 8:33 am    Post subject:
Up to date tutorials for linux
Reply with quote

Hi Rodrigo,

On 1 March 2017 at 21:57, Rodrigo Dias <> wrote:
Quote:
Without clear instructions for Linux starters, I first downloaded the OpenSceneGraph-3.4.0.zip. Then I unzipped it and tried to compile using make/cmake. No success. Then I tried sudo apt-get install libopenscenegraph-dev openscenegraph. Not sure if the first is in conflict with the second, or where to find the proper libraries, includes, etc.

Building under linux/unix is explained in the OpenSceneGraph/READEME

It's as simple as:

cd OpenSceneGraph
cmake .
make -j 8
sudo make install

You may wish to pull in some 3rd party dependencies if there are
specific. There are a list is packages that you can pull in via
apt-get on the openscenegraph documentation section.

If there is an error you are seeing please tell us.

Quote:
If you do a FREE, OPEN SOURCE project, I think you should have more Tutorials other than Windows and Mac OS. I will post some broken links as long as I'm allowed.

The OSG is fundamentally cross platform, it's only the Windowing setup
and build that may vary across platforms. Linux is most straight
forward of all platforms to build upon, most of what you need to know
is written above, yes, it's really that simple, the rest of the OSG
stuff will be cross platform so examples and tutorials will also be
applicable for all platforms..

Robert


------------------
Post generated by Mail2Forum
Back to top
View user's profile Send private message
Jan Ciger
Guest





PostPosted: Thu Mar 02, 2017 9:36 am    Post subject:
Up to date tutorials for linux
Reply with quote

Hello Rodrigo,

On Wed, Mar 1, 2017 at 10:57 PM, Rodrigo Dias < (
Only registered users can see emails on this board!
Get registred or enter the forums!
)> wrote:
Quote:
Without clear instructions for Linux starters, I first downloaded the OpenSceneGraph-3.4.0.zip. Then I unzipped it and tried to compile using make/cmake. No success. Then I tried sudo apt-get install libopenscenegraph-dev openscenegraph. Not sure if the first is in conflict with the second, or where to find the proper libraries, includes, etc.

If you do a FREE, OPEN SOURCE project, I think you should have more Tutorials other than Windows and Mac OS. I will post some broken links as long as I'm allowed.




To send the ball back to your court - without a clear report of what exactly went wrong it is a bit difficult to help you. "No success" is not very informative. Neither is demanding more tutorials without saying what didn't work with the existing documentation. 


You didn't say what went wrong (any error messages?), neither whether you have installed all the dependencies (and disabled the ones you don't have/want using CMake). You need to give people a bit more information if you actually want help. 


OSG is very easy to build on Linux, especially because most of the dependencies are available compiled in the distribution repositories. However, it expects that you know how to compile software using the CMake build tool. 


BTW, don't install libopenscenegraph-dev from the distribution repositories if you want to compile your own OSG - that package is part of a prepackaged/precompiled (and likely fairly old) OSG version comping with your Debian. That will interfere with building your own, because the header files and libraries will get mixed with the ones you are trying to build. 


Regards,


J. 

------------------
Post generated by Mail2Forum
Back to top
Rodrigo
Newbie


Joined: 01 Mar 2017
Posts: 3

PostPosted: Thu Mar 02, 2017 1:47 pm    Post subject:
Reply with quote

Hi Robert,

> Building under linux/unix is explained in the OpenSceneGraph/README

Right. But you also has a link at Documentation | Platform Specific | Linux. I thought everything platform specific would be there, but it wasn't, so I went to other sources (before remembering the README), and did the apt-get install, which scrambled my installation. Maybe you could add that part to that menu?

> Linux is most straight forward of all platforms to build upon

It is, but not necessarily for us who have always used Windows, and only now are learning Linux.

So what I did was to install OSG in a fresh Debian install in VirtualBox (at least to learn how it's done -- should have done that before). I've had a few problems:

1. As I told above, the Linux Platform Specifics menu could include the cmake commands from the README.
2. I needed to do make install_ld_conf after cmake . and before make. This could be in the manual as well, because I wasn't sure if it was the moment to do it. Luckily, it was.
3. After I built everything, I came to "Running the examples", and only then I've been told to use -DBUILD_OSG_EXAMPLES=1 with cmake. I tried running cmake again, and got the following results:

Code:
rods@debianVB:~/Downloads/OSG-3.4.0$ cmake . -DBUILD_OSG_EXAMPLES=1
-- checking for module 'gta'
--   package 'gta' not found
-- Could NOT find GStreamer (missing:  GSTREAMER_INCLUDE_DIRS GSTREAMER_LIBRARIES GSTREAMER_VERSION GSTREAMER_BASE_INCLUDE_DIRS GSTREAMER_BASE_LIBRARIES GSTREAMER_APP_INCLUDE_DIRS GSTREAMER_APP_LIBRARIES GSTREAMER_PBUTILS_INCLUDE_DIRS GSTREAMER_PBUTILS_LIBRARIES)
-- Could NOT find SDL2 (missing:  SDL2_LIBRARY SDL2_INCLUDE_DIR)
-- Could NOT find SDL (missing:  SDL_LIBRARY SDL_INCLUDE_DIR)
-- checking for module 'gtk+-2.0'
--   package 'gtk+-2.0' not found
-- checking for module 'gtkglext-x11-1.0'
--   package 'gtkglext-x11-1.0' not found
-- Could NOT find FLTK (missing:  FLTK_LIBRARIES FLTK_FLUID_EXECUTABLE)
-- Found GLUT: /usr/lib/i386-linux-gnu/libglut.so 
-- Could NOT find wxWidgets (missing:  wxWidgets_FOUND)
-- checking for module 'xrandr'
--   package 'xrandr' not found
CMake Error at /usr/share/cmake-3.0/Modules/Qt4Macros.cmake:138 (file):
  file Internal CMake error when trying to open file:
  /home/rods/Downloads/OSG-3.4.0/src/osgQt/__/__/include/osgQt/moc_QGraphicsViewAdapter.cxx_parameters
  for writing.
Call Stack (most recent call first):
  /usr/share/cmake-3.0/Modules/Qt4Macros.cmake:177 (QT4_CREATE_MOC_COMMAND)
  src/osgQt/CMakeLists.txt:20 (QT4_WRAP_CPP)

-- Configuring incomplete, errors occurred!
See also "/home/rods/Downloads/OSG-3.4.0/CMakeFiles/CMakeOutput.log".
See also "/home/rods/Downloads/OSG-3.4.0/CMakeFiles/CMakeError.log".
CMake Error: Unable to open check cache file for write. /home/rods/Downloads/OSG-3.4.0/CMakeFiles/cmake.check_cache


I don't know if it's only here, or only in Debian, but probably some other advices could be included in the installation guide to avoid all this.

Other thing, the lines below are wrong. You cannot have a space between the variable name, the equal sign and the variable value.

export PATH = ${PATH}:/home/myaccount/OpenSceneGraph/bin
export LD_LIBRARY_PATH = ${LD_LIBRARY_PATH}:/home/myaccount/OpenSceneGraph/lib
export OSG_FILE_PATH = /home/myaccount/OpenSceneGraph-Data:/home/myaccount/OpenSceneGraph-Data/Images

They should be

export PATH=${PATH}:/home/myaccount/OpenSceneGraph/bin
export LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:/home/myaccount/OpenSceneGraph/lib
export OSG_FILE_PATH=/home/myaccount/OpenSceneGraph-Data:/home/myaccount/OpenSceneGraph-Data/Images

Still another thing, the menu Documentation | Tutorials show only one tutorial "Analysing a Scenegraph". I think that 20 tutorials 8-years-old are not so bad to be thrown away like that, are they?


Thank you!

Cheers,
Rodrigo
Back to top
View user's profile Send private message
robertosfield
OSG Project Lead


Joined: 18 Mar 2009
Posts: 10791

PostPosted: Thu Mar 02, 2017 2:40 pm    Post subject:
Up to date tutorials for linux
Reply with quote

Hi Rodrigo,

On 2 March 2017 at 13:47, Rodrigo Dias <> wrote:
Quote:
Quote:
Building under linux/unix is explained in the OpenSceneGraph/README

Right. But you also has a link at Documentation | Platform Specific | Linux. I thought everything platform specific would be there,

There isn't really anything platform specific about building under
Linux, it's just standard cross platform cmake and make usage :-)

This page could do will filling out, and the main Getting Started
section could do with filling out a bit.

Quote:
So what I did was to install OSG in a fresh Debian install in VirtualBox (at least to learn how it's done -- should have done that before). I've had a few problems:

1. As I told above, the Linux Platform Specifics menu could include the cmake commands from the README.
2. I needed to do make install_ld_conf after cmake . and before make. This could be in the manual as well, because I wasn't sure if it was the moment to do it. Luckily, it was.
3. After I built everything, I came to "Running the examples", and only then I've been told to use -DBUILD_OSG_EXAMPLES=1 with cmake. I tried running cmake again, and got the following results:


Code:
rods@debianVB:~/Downloads/OSG-3.4.0$ cmake . -DBUILD_OSG_EXAMPLES=1
-- checking for module 'gta'
-- package 'gta' not found
-- Could NOT find GStreamer (missing: GSTREAMER_INCLUDE_DIRS GSTREAMER_LIBRARIES GSTREAMER_VERSION GSTREAMER_BASE_INCLUDE_DIRS GSTREAMER_BASE_LIBRARIES GSTREAMER_APP_INCLUDE_DIRS GSTREAMER_APP_LIBRARIES GSTREAMER_PBUTILS_INCLUDE_DIRS GSTREAMER_PBUTILS_LIBRARIES)
-- Could NOT find SDL2 (missing: SDL2_LIBRARY SDL2_INCLUDE_DIR)
-- Could NOT find SDL (missing: SDL_LIBRARY SDL_INCLUDE_DIR)
-- checking for module 'gtk+-2.0'
-- package 'gtk+-2.0' not found
-- checking for module 'gtkglext-x11-1.0'
-- package 'gtkglext-x11-1.0' not found
-- Could NOT find FLTK (missing: FLTK_LIBRARIES FLTK_FLUID_EXECUTABLE)
-- Found GLUT: /usr/lib/i386-linux-gnu/libglut.so
-- Could NOT find wxWidgets (missing: wxWidgets_FOUND)
-- checking for module 'xrandr'
-- package 'xrandr' not found
CMake Error at /usr/share/cmake-3.0/Modules/Qt4Macros.cmake:138 (file):
file Internal CMake error when trying to open file:
/home/rods/Downloads/OSG-3.4.0/src/osgQt/__/__/include/osgQt/moc_QGraphicsViewAdapter.cxx_parameters
for writing.
Call Stack (most recent call first):
/usr/share/cmake-3.0/Modules/Qt4Macros.cmake:177 (QT4_CREATE_MOC_COMMAND)
src/osgQt/CMakeLists.txt:20 (QT4_WRAP_CPP)

-- Configuring incomplete, errors occurred!
See also "/home/rods/Downloads/OSG-3.4.0/CMakeFiles/CMakeOutput.log".
See also "/home/rods/Downloads/OSG-3.4.0/CMakeFiles/CMakeError.log".
CMake Error: Unable to open check cache file for write. /home/rods/Downloads/OSG-3.4.0/CMakeFiles/cmake.check_cache

It looks like there is an error relating to the osgQt module/cmake's
Qt4Macros. Either Cmake or Qt might have changed since we made the
3.4.0 (a year and half ago.), or perhaps debian's combination of these
wasn't tested during the OSG-3.4.0 testing cycle.

Could you try the master from github?

Or just disable the build of osgQt by setting QT4_FOUND and
Qt5Widgets_FOUND to FALSE via cmake.

Quote:
I don't know if it's only here, or only in Debian, but probably some other advices could be included in the installation guide to avoid all this.

We can't provide guidance on issues we haven't seen before, the above
issues aren't standard ones. I've just pulled down 3.4.0 onto my
Kubuntu 16.04 system and it's building cleanly.


Quote:
Other thing, the lines below are wrong. You cannot have a space between the variable name, the equal sign and the variable value.

export PATH = ${PATH}:/home/myaccount/OpenSceneGraph/bin
export LD_LIBRARY_PATH = ${LD_LIBRARY_PATH}:/home/myaccount/OpenSceneGraph/lib
export OSG_FILE_PATH = /home/myaccount/OpenSceneGraph-Data:/home/myaccount/OpenSceneGraph-Data/Images

They should be

export PATH=${PATH}:/home/myaccount/OpenSceneGraph/bin
export LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:/home/myaccount/OpenSceneGraph/lib
export OSG_FILE_PATH=/home/myaccount/OpenSceneGraph-Data:/home/myaccount/OpenSceneGraph-Data/Images

Where is the above?

Quote:
Still another thing, the menu Documentation | Tutorials show only one tutorial "Analysing a Scenegraph". I think that 20 tutorials 8-years-old are not so bad to be thrown away like that, are they?

This is why we've kept around the old tracs.openscenegraph.org
website. We ported over most of the website to Joomla a few years
back but there are bits that we haven;'t had a chance to port across.
Please realize that this work is being done in peoples free time,
there isn't a rich sugar daddy that goes around spreading pixie dust
to magic things to happen, it takes hard graft in between all the rest
of our work.

Robert.


------------------
Post generated by Mail2Forum
Back to top
View user's profile Send private message
Jan Ciger
Guest





PostPosted: Thu Mar 02, 2017 3:01 pm    Post subject:
Up to date tutorials for linux
Reply with quote

On Thu, Mar 2, 2017 at 3:37 PM, Robert Osfield < (
Only registered users can see emails on this board!
Get registred or enter the forums!
)> wrote:
Quote:
It looks like there is an error relating to the osgQt module/cmake's
Qt4Macros.  Either Cmake or Qt might have changed since we made the
3.4.0 (a year and half ago.), or perhaps debian's combination of these
wasn't tested during the OSG-3.4.0 testing cycle.





That looks like a CMake bug, IMO - there is an internal error being reported by CMake. Debian doesn't have the most recent software, CMake 3.0 is a few years old. If Qt4 support is needed for some reason and cannot be turned off, I would suggest downloading/building a newer version of CMake first.


Regards,


Jan

------------------
Post generated by Mail2Forum
Back to top
Alberto Luaces
Guest





PostPosted: Thu Mar 02, 2017 3:05 pm    Post subject:
Up to date tutorials for linux
Reply with quote

"Rodrigo Dias" writes:

Quote:
Hi Robert,

Quote:
Building under linux/unix is explained in the OpenSceneGraph/README

Right. But you also has a link at Documentation | Platform Specific |
Linux. I thought everything platform specific would be there, but it
wasn't, so I went to other sources (before remembering the README),
and did the apt-get install, which scrambled my installation. Maybe
you could add that part to that menu?


1. It should not be possible to "scramble" an installation by installing
packages with apt. I usually compile the latest version having
simultaneously installed Debian's 3.4.

2. I think you have followed incorrectly the instructions: it says run

apt-get build-dep openscenegraph

and not

apt-get install openscenegraph

the point is to have all the dependencies that OSG relies on installed
on your system instead of having to compile or install them manually
yourself, with I see it is giving you additional problems.

--
Alberto



------------------
Post generated by Mail2Forum
Back to top
kornerr
Appreciator


Joined: 01 Oct 2013
Posts: 144

PostPosted: Fri Mar 03, 2017 5:10 am    Post subject:
Up to date tutorials for linux
Reply with quote

Hi.
I currently work on a set of tutorials to build and use OSG for several platforms (desktop, mobile, web), however, they will be only available in 2-3 months.

I'll keep you updated.


2017-03-02 22:03 GMT+07:00 Alberto Luaces < (
Only registered users can see emails on this board!
Get registred or enter the forums!
)>:
Quote:
"Rodrigo Dias" writes:

Quote:
Hi Robert,

Quote:
Building under linux/unix is explained in the OpenSceneGraph/README

Right. But you also has a link at Documentation | Platform Specific |
Linux. I thought everything platform specific would be there, but it
wasn't, so I went to other sources (before remembering the README),
and did the apt-get install, which scrambled my installation. Maybe
you could add that part to that menu?


1. It should not be possible to "scramble" an installation by installing
packages with apt.  I usually compile the latest version having
simultaneously installed Debian's 3.4.

2. I think you have followed incorrectly the instructions: it says run

apt-get build-dep openscenegraph

and not

apt-get install openscenegraph

the point is to have all the dependencies that OSG relies on installed
on your system instead of having to compile or install them manually
yourself, with I see it is giving you additional problems.

--
Alberto

_______________________________________________
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
View user's profile Send private message
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 [Solved] Bug while updating geometry ... Nikkitta General 2 Thu Jan 26, 2017 9:27 am View latest post
No new posts a linux dialog starting to blur while... lq37 General 2 Tue Nov 29, 2016 4:57 pm View latest post
No new posts osgversion command fails with symbol ... crubel@compro.net General 4 Tue Oct 11, 2016 5:31 pm View latest post
No new posts Linux packaging: Qt 4 vs 5 DeadParrot General 14 Thu Jul 14, 2016 8:52 pm View latest post
No new posts Qt5 and OSG port issue: Shaking motio... lpkAtexa General 0 Fri May 27, 2016 8:55 pm 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