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 

Building for Linux on ARM


 
Post new topic   Reply to topic    OpenSceneGraph Forum Forum Index -> Build system [build]
View previous topic :: View next topic  
Author Message
swiehr
Newbie


Joined: 27 Aug 2014
Posts: 5

PostPosted: Wed Aug 27, 2014 3:28 pm    Post subject:
Building for Linux on ARM
Reply with quote

Hi,

I am currently trying to build OpenScenegraph for a custom embedded Linux on an ARM platform (armhf if it matters) with GLESv2 and Wayland but currently already fail on configure.

Current configure is this:

Code:
./configure \
-DOSG_GL1_AVAILABLE=OFF \
-DOSG_GL2_AVAILABLE=OFF \
-DOSG_GL3_AVAILABLE=OFF \
-DOSG_GLES1_AVAILABLE=OFF \
-DOSG_GLES2_AVAILABLE=ON \
-DOSG_GL_LIBRARY_STATIC=OFF \
-DOSG_GL_DISPLAYLISTS_AVAILABLE=OFF \
-DOSG_GL_MATRICES_AVAILABLE=OFF \
-DOSG_GL_VERTEX_FUNCS_AVAILABLE=OFF \
-DOSG_GL_VERTEX_ARRAY_FUNCS_AVAILABLE=OFF \
-DOSG_GL_FIXED_FUNCTION_AVAILABLE=OFF \
-DBUILD_OSG_EXAMPLES=ON


current result is this:

Code:
-- Could NOT find OpenGL (missing: OPENGL_gl_LIBRARY)
-- Could NOT find LibXml2 (missing: LIBXML2_LIBRARIES) (found version "2.9.1")
-- checking for module 'gta'
-- package 'gta' not found
-- Could NOT find CURL (missing: CURL_LIBRARY CURL_INCLUDE_DIR)
-- Could NOT find SDL (missing: SDL_LIBRARY) (found version "1.2.14")
-- checking for module 'poppler-glib'
-- package 'poppler-glib' not found
-- checking for module 'librsvg-2.0>=2.35'
-- package 'librsvg-2.0>=2.35' not found
-- 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 Boost
-- Could NOT find GLUT (missing: GLUT_glut_LIBRARY)
-- Could NOT find wxWidgets (missing: wxWidgets_FOUND)
-- Could NOT find JPEG (missing: JPEG_LIBRARY)
-- Could NOT find ZLIB (missing: ZLIB_LIBRARY) (found version "1.2.3.4")
-- Could NOT find PNG (missing: PNG_LIBRARY PNG_PNG_INCLUDE_DIR)
-- Could NOT find TIFF (missing: TIFF_LIBRARY) (found version "3.9.5")
-- checking for module 'xrandr'
-- package 'xrandr' not found
CMake Error: The following variables are used in this project, but they are set to NOTFOUND.
Please set them or make sure they are set and tested correctly in the CMake files:
OPENGL_gl_LIBRARY (ADVANCED)


Can anyone give me a hint or directions on how to get this to a compilable state?
Checking the current configurations that could use GLESv2 (Apple and Android) I couldn't even figure what I have to set to get my libGLESv2.so being found.

Additionally the question: Which dependencies are actually minimal or important respectively?
From the configure result it looks like some more libraries and/or header files are missing but I am not sure how crucial their absence is.

Thank you!

Cheers,
Stephan[/code]
Back to top
View user's profile Send private message
Chris Hanson
Guest





PostPosted: Wed Aug 27, 2014 5:43 pm    Post subject:
Building for Linux on ARM
Reply with quote

Which ARM platform are you trying to build on?


On Wed, Aug 27, 2014 at 9:28 AM, Stephan Wiehr < (
Only registered users can see emails on this board!
Get registred or enter the forums!
)> wrote:
Quote:
Hi,

I am currently trying to build OpenScenegraph for a custom embedded Linux on an ARM platform (armhf if it matters) with GLESv2 and Wayland but currently already fail on configure.

Current configure is this:


Code:
./configure
-DOSG_GL1_AVAILABLE=OFF
-DOSG_GL2_AVAILABLE=OFF
-DOSG_GL3_AVAILABLE=OFF
-DOSG_GLES1_AVAILABLE=OFF
-DOSG_GLES2_AVAILABLE=ON
-DOSG_GL_LIBRARY_STATIC=OFF
-DOSG_GL_DISPLAYLISTS_AVAILABLE=OFF
-DOSG_GL_MATRICES_AVAILABLE=OFF
-DOSG_GL_VERTEX_FUNCS_AVAILABLE=OFF
-DOSG_GL_VERTEX_ARRAY_FUNCS_AVAILABLE=OFF
-DOSG_GL_FIXED_FUNCTION_AVAILABLE=OFF
-DBUILD_OSG_EXAMPLES=ON



current result is this:


Code:
-- Could NOT find OpenGL (missing: OPENGL_gl_LIBRARY)
-- Could NOT find LibXml2 (missing: LIBXML2_LIBRARIES) (found version "2.9.1")
-- checking for module 'gta'
-- package 'gta' not found
-- Could NOT find CURL (missing: CURL_LIBRARY CURL_INCLUDE_DIR)
-- Could NOT find SDL (missing: SDL_LIBRARY) (found version "1.2.14")
-- checking for module 'poppler-glib'
-- package 'poppler-glib' not found
-- checking for module 'librsvg-2.0>=2.35'
-- package 'librsvg-2.0>=2.35' not found
-- 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 Boost
-- Could NOT find GLUT (missing: GLUT_glut_LIBRARY)
-- Could NOT find wxWidgets (missing: wxWidgets_FOUND)
-- Could NOT find JPEG (missing: JPEG_LIBRARY)
-- Could NOT find ZLIB (missing: ZLIB_LIBRARY) (found version "1.2.3.4")
-- Could NOT find PNG (missing: PNG_LIBRARY PNG_PNG_INCLUDE_DIR)
-- Could NOT find TIFF (missing: TIFF_LIBRARY) (found version "3.9.5")
-- checking for module 'xrandr'
-- package 'xrandr' not found
CMake Error: The following variables are used in this project, but they are set to NOTFOUND.
Please set them or make sure they are set and tested correctly in the CMake files:
OPENGL_gl_LIBRARY (ADVANCED)



Can anyone give me a hint or directions on how to get this to a compilable state?
Checking the current configurations that could use GLESv2 (Apple and Android) I couldn't even figure what I have to set to get my libGLESv2.so being found.

Additionally the question: Which dependencies are actually minimal or important respectively?
Quote:
From the configure result it looks like some more libraries and/or header files are missing but I am not sure how crucial their absence is.

Thank you!

Cheers,
Stephan[/code]

------------------
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=60817#60817





_______________________________________________
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




--
Chris 'Xenon' Hanson, omo sanza lettere. http://www.alphapixel.com/
Training • Consulting • Contracting
3D • Scene Graphs (Open Scene Graph/OSG) • OpenGL 2 • OpenGL 3 • OpenGL 4 • GLSL • OpenGL ES 1 • OpenGL ES 2 • OpenCL
Digital Imaging • GIS • GPS • osgEarth • Terrain • Telemetry • Cryptography • Digital Audio • LIDAR • Kinect • Embedded • Mobile • iPhone/iPad/iOS • Android
@alphapixel facebook.com/alphapixel (775) 623-PIXL [7495]

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


Joined: 27 Aug 2014
Posts: 5

PostPosted: Wed Aug 27, 2014 8:24 pm    Post subject:
Re: Building for Linux on ARM
Reply with quote

Chris Hanson wrote:
Which ARM platform are you trying to build on?


It's a TI Jacinto 6 platform (ARM Cortex A15 dual-core with a dual SGX544 GPU)
Back to top
View user's profile Send private message
Chris Hanson
Guest





PostPosted: Wed Aug 27, 2014 9:25 pm    Post subject:
Building for Linux on ARM
Reply with quote

That's not one I've built for, but we've built for the iMX6 and the NVidia Jetson TK1.

Technically most of those dependencies are optional (though it's hard to get much done without JPEG, PNG, and zlib) but this one:


-- Could NOT find OpenGL (missing: OPENGL_gl_LIBRARY)


will be a showstopper.


Do you have the OGL headers and libs SDK pieces installed ahead of time?





On Wed, Aug 27, 2014 at 2:24 PM, Stephan Wiehr < (
Only registered users can see emails on this board!
Get registred or enter the forums!
)> wrote:
Quote:

Chris Hanson wrote:
Quote:
Which ARM platform are you trying to build on?




It's a TI Jacinto 6 platform (ARM Cortex A15 dual-core with a dual SGX544 GPU)

------------------
Read this topic online here:

http://forum.openscenegraph.org/viewtopic.php?p=60823#60823





_______________________________________________
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






--
Chris 'Xenon' Hanson, omo sanza lettere. http://www.alphapixel.com/
Training • Consulting • Contracting
3D • Scene Graphs (Open Scene Graph/OSG) • OpenGL 2 • OpenGL 3 • OpenGL 4 • GLSL • OpenGL ES 1 • OpenGL ES 2 • OpenCL
Digital Imaging • GIS • GPS • osgEarth • Terrain • Telemetry • Cryptography • Digital Audio • LIDAR • Kinect • Embedded • Mobile • iPhone/iPad/iOS • Android
@alphapixel facebook.com/alphapixel (775) 623-PIXL [7495]

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


Joined: 27 Aug 2014
Posts: 5

PostPosted: Thu Aug 28, 2014 7:19 am    Post subject:
Re: Building for Linux on ARM
Reply with quote

Chris Hanson wrote:
That's not one I've built for, but we've built for the iMX6 and the NVidia Jetson TK1.

Technically most of those dependencies are optional (though it's hard to get much done without JPEG, PNG, and zlib) but this one:


-- Could NOT find OpenGL (missing: OPENGL_gl_LIBRARY)


will be a showstopper.


Do you have the OGL headers and libs SDK pieces installed ahead of time?


Well, my SDK sysroot (built using yocto) contains these headers and libraries (although I am not sure if they are exactly what is searched for):

Code:

/usr/lib ->
-rw-r--r-- 1 root root 2658703 Jun 11 10:13 lib/libGLESv2.so.1.9.6.0
lrwxrwxrwx 1 root root 20 Aug 11 18:26 lib/libGLESv2.so.2 -> libGLESv2.so.1.9.6.0

/usr/include/GLES2 ->
-rw-r--r-- 1 root root 44143 Jun 11 10:13 gl2ext.h
-rw-r--r-- 1 root root 31666 Jun 11 10:13 gl2.h
-rw-r--r-- 1 root root 898 Jun 11 10:13 gl2platform.h


Any idea where I could "debug" the cmake process to figure what it is looking for exactly?

Good to know about those other dependencies, will make sure I get these in.

thx for your feedback so far
Back to top
View user's profile Send private message
robertosfield
OSG Project Lead


Joined: 18 Mar 2009
Posts: 12094

PostPosted: Thu Aug 28, 2014 7:40 am    Post subject:
Building for Linux on ARM
Reply with quote

HI Stephan,


You don't mention which version of the OSG you are using.  I would strongly recommend using svn/trunk or latest 3.3.x developer release as this contains various updates to help with building against GLES and other GL targets.  In particular the cmake build system now has a new OPENGL_PROFILE variable that you can set to the appropriate OpenGL type and it'll set up the rest of the CMAKE variables associated with that target - so no long winded settings like you published in your first post.  Instead you can do:

   cmake -DOPENGL_PROFILE=GLES2


You may still need to adjust the paths to the GLES libs if they aren't found by default, but you should further along the way.


Another advantage of using svn/trunk is if you find a build issue on your particular platform target we can get a fix checked in more readily.

Robert.

------------------
Post generated by Mail2Forum
Back to top
View user's profile Send private message
swiehr
Newbie


Joined: 27 Aug 2014
Posts: 5

PostPosted: Thu Aug 28, 2014 8:27 am    Post subject:
Re: Building for Linux on ARM
Reply with quote

Thanks for that suggestion, so far I went for the latest stable build 3.2.1 now I moved to the subversion trunk as you suggested.

Unfortunately still I get these results (currently checking for OpenGL only, other issues will fix later):

Code:

-- The C compiler identification is GNU 4.7.3
-- The CXX compiler identification is GNU 4.7.3
-- Check for working C compiler: /usr/local/oecore-i686/sysroots/i686-oesdk-linux/usr/bin/arm-linux-gnueabihf-gcc
-- Check for working C compiler: /usr/local/oecore-i686/sysroots/i686-oesdk-linux/usr/bin/arm-linux-gnueabihf-gcc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working CXX compiler: /usr/local/oecore-i686/sysroots/i686-oesdk-linux/usr/bin/arm-linux-gnueabihf-g++
-- Check for working CXX compiler: /usr/local/oecore-i686/sysroots/i686-oesdk-linux/usr/bin/arm-linux-gnueabihf-g++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Looking for include file pthread.h
-- Looking for include file pthread.h - found
-- Looking for pthread_create
-- Looking for pthread_create - not found
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - found
-- Found Threads: TRUE
-- Could NOT find OpenGL (missing: OPENGL_gl_LIBRARY)
-- Could NOT find Freetype (missing: FREETYPE_LIBRARY) (found version "2.4.8")
-- Could NOT find JPEG (missing: JPEG_LIBRARY)
-- Could NOT find Jasper (missing: JASPER_LIBRARIES JASPER_INCLUDE_DIR JPEG_LIBRARIES)
-- Could NOT find LibXml2 (missing: LIBXML2_LIBRARIES) (found version "2.9.1")
-- Could NOT find ZLIB (missing: ZLIB_LIBRARY) (found version "1.2.3.4")
-- Could NOT find ZLIB (missing: ZLIB_LIBRARY) (found version "1.2.3.4")
-- Could NOT find GDAL (missing: GDAL_LIBRARY GDAL_INCLUDE_DIR)
-- Found PkgConfig: /usr/local/oecore-i686/sysroots/i686-oesdk-linux/usr/bin/pkg-config (found version "0.28")
-- checking for module 'gta'
-- package 'gta' not found
-- Could NOT find CURL (missing: CURL_LIBRARY CURL_INCLUDE_DIR)
-- Could NOT find SDL (missing: SDL_LIBRARY) (found version "1.2.14")
-- checking for module 'cairo'
-- found cairo, version 1.12.14
-- checking for module 'poppler-glib'
-- package 'poppler-glib' not found
-- checking for module 'librsvg-2.0>=2.35'
-- package 'librsvg-2.0>=2.35' not found
-- 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 Boost
-- Could NOT find PythonLibs (missing: PYTHON_INCLUDE_DIRS)
-- Looking for Q_WS_X11
-- Looking for Q_WS_X11 - not found
-- Looking for Q_WS_WIN
-- Looking for Q_WS_WIN - not found
-- Looking for Q_WS_QWS
-- Looking for Q_WS_QWS - not found
-- Looking for Q_WS_MAC
-- Looking for Q_WS_MAC - not found
-- Found Qt4: /usr/bin/qmake (found version "4.8.1")
-- Could NOT find OpenGL (missing: OPENGL_gl_LIBRARY)
-- Could NOT find FLTK (missing: FLTK_LIBRARIES FLTK_FLUID_EXECUTABLE)
-- Could NOT find GLUT (missing: GLUT_glut_LIBRARY)
-- Could NOT find wxWidgets (missing: wxWidgets_FOUND)
-- Could NOT find JPEG (missing: JPEG_LIBRARY)
-- Could NOT find ZLIB (missing: ZLIB_LIBRARY) (found version "1.2.3.4")
-- Could NOT find PNG (missing: PNG_LIBRARY PNG_PNG_INCLUDE_DIR)
-- Could NOT find TIFF (missing: TIFF_LIBRARY) (found version "3.9.5")
-- Performing Test _OPENTHREADS_ATOMIC_USE_GCC_BUILTINS
-- Performing Test _OPENTHREADS_ATOMIC_USE_GCC_BUILTINS - Failed
-- Performing Test _OPENTHREADS_ATOMIC_USE_MIPOSPRO_BUILTINS
-- Performing Test _OPENTHREADS_ATOMIC_USE_MIPOSPRO_BUILTINS - Failed
-- Performing Test _OPENTHREADS_ATOMIC_USE_SUN
-- Performing Test _OPENTHREADS_ATOMIC_USE_SUN - Failed
-- Performing Test _OPENTHREADS_ATOMIC_USE_WIN32_INTERLOCKED
-- Performing Test _OPENTHREADS_ATOMIC_USE_WIN32_INTERLOCKED - Failed
-- Performing Test _OPENTHREADS_ATOMIC_USE_BSD_ATOMIC
-- Performing Test _OPENTHREADS_ATOMIC_USE_BSD_ATOMIC - Failed
-- Looking for pthread_yield
-- Looking for pthread_yield - not found
-- Looking for sched_yield
-- Looking for sched_yield - found
-- Looking for pthread_setconcurrency
-- Looking for pthread_setconcurrency - not found
-- Looking for pthread_getconcurrency
-- Looking for pthread_getconcurrency - not found
-- Looking for pthread_setaffinity_np
-- Looking for pthread_setaffinity_np - not found
-- Performing Test HAVE_THREE_PARAM_SCHED_SETAFFINITY
-- Performing Test HAVE_THREE_PARAM_SCHED_SETAFFINITY - Success
-- checking for module 'xrandr'
-- package 'xrandr' not found
-- Looking for gethostbyname in nsl
-- Looking for gethostbyname in nsl - found
-- Looking for socket in socket
-- Looking for socket in socket - not found


robertosfield wrote:
HI Stephan,


You don't mention which version of the OSG you are using.  I would strongly recommend using svn/trunk or latest 3.3.x developer release as this contains various updates to help with building against GLES and other GL targets.  In particular the cmake build system now has a new OPENGL_PROFILE variable that you can set to the appropriate OpenGL type and it'll set up the rest of the CMAKE variables associated with that target - so no long winded settings like you published in your first post.  Instead you can do:

   cmake -DOPENGL_PROFILE=GLES2


You may still need to adjust the paths to the GLES libs if they aren't found by default, but you should further along the way.


Another advantage of using svn/trunk is if you find a build issue on your particular platform target we can get a fix checked in more readily.

Robert.

------------------
Post generated by Mail2Forum
Back to top
View user's profile Send private message
swiehr
Newbie


Joined: 27 Aug 2014
Posts: 5

PostPosted: Thu Aug 28, 2014 10:56 am    Post subject:
Reply with quote

Hi,

just an additional thing I found when checking through my sysroots libs and headers:

Everything seems to be there for freetype, libxml2, libjpeg, libpng, zlib still the cmake output says these could not be found.

Anyone having an idea about this?

With a cross-compile environment like the following (excerpt from yocto generated file) this should work ok, right?

Code:
export CC="arm-linux-gnueabihf-gcc -march=armv7-a -marm -mthumb-interwork -mfloat-abi=hard -mfpu=neon -mtune=cortex-a15 --sysroot=/usr/local/oecore-i686/sysroots/cortexa15hf-vfp-neon-oe-linux-gnueabi"
export CXX="arm-linux-gnueabihf-g++ -march=armv7-a -marm -mthumb-interwork -mfloat-abi=hard -mfpu=neon -mtune=cortex-a15 --sysroot=/usr/local/oecore-i686/sysroots/cortexa15hf-vfp-neon-oe-linux-gnueabi"
export CPP="arm-linux-gnueabihf-gcc -E -march=armv7-a -marm -mthumb-interwork -mfloat-abi=hard -mfpu=neon -mtune=cortex-a15 --sysroot=/usr/local/oecore-i686/sysroots/cortexa15hf-vfp-neon-oe-linux-gnueabi"
export AS="arm-linux-gnueabihf-as "
export LD="arm-linux-gnueabihf-ld --sysroot=/usr/local/oecore-i686/sysroots/cortexa15hf-vfp-neon-oe-linux-gnueabi"


Thank you!

Cheers,
Stephan
Back to top
View user's profile Send private message
camila
Newbie


Joined: 06 Sep 2014
Posts: 1

PostPosted: Sat Sep 06, 2014 9:45 am    Post subject:
Reply with quote

I built the latest OSG version as you suggested (3.2.1) and everything is back to normal. I used the exact same process to build and compile the programs, so maybe a bug that was still present in 3.0.1 along with my system led to this one.






_______________________________________________________________
Back to top
View user's profile Send private message
rhennicey21
Newbie


Joined: 03 Oct 2014
Posts: 2

PostPosted: Fri Oct 03, 2014 6:22 am    Post subject:
Hi there! :)
Reply with quote

Hi,

The Linux 3.12 kernel is coming to an end and 3.12-rc1 should be released soon. An overview of the interesting merges that happened over the past two weeks as new features for Linux 3.12.Linux 3.12-rc1 kernel as the first major development release of this major forthcoming open source kernel update. Linux 3.12 at least from our perspective with the fanatic and desktop hardware angle. There is lots of open source graphics driver improvement, the constant growth of Linux file-systems, more ARM work, and various latest updated hardware drivers.

Thank you!

Cheers,
rhen Wink
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    OpenSceneGraph Forum Forum Index -> Build system [build] 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 Cross-platform examples for Linux, ma... kornerr Announcement [ANN] 0 Tue Aug 14, 2018 10:51 am View latest post
No new posts Missing OpenThreads PDB when building... guyv Build system [build] 0 Thu Jul 12, 2018 12:39 pm View latest post
No new posts Building OpenSceneGraph-3.6.0 on Wind... ravidavi Build system [build] 5 Thu Apr 19, 2018 4:44 pm View latest post
No new posts Cross-platform examples for Linux, ma... kornerr Announcement [ANN] 3 Mon Apr 09, 2018 9:36 am View latest post
No new posts Building OpenSceneGraph Windows Skaldi Build system [build] 3 Sun Dec 24, 2017 4:13 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