patrykcieslak / stonefish

Stonefish - an advanced C++ simulation library designed for (but not limited to) marine robotics.
https://stonefish.readthedocs.io/
GNU General Public License v3.0
126 stars 32 forks source link

Compiling on MacOSX #11

Closed jdbodyfelt closed 4 years ago

jdbodyfelt commented 4 years ago

Builds great in Ubuntu 20.04 (work remotes), however my laptop runs Mac OSX Catalina. Reckoned I'd post this small bug fix for others that might hit this same problem.

Describe the bug Following Unix install instructions, there path errors within MacOSX SDL2 and glm libraries.

Solution

  1. Install both SDL2 and glm using brew install <package>.
  2. Use brew info to determine install paths.
  3. Make a symbolic link within Library/include.

For example, my build succeeded with the following two linkages:

If you're using Windows...may Heaven have mercy on your poor masochistic soul.

jdbodyfelt commented 4 years ago

ACKKK. Spoke too soon - builds fine, but execution fails with [CRITICAL] SDL2: Failed creating OpenGL context at version requested...

patrykcieslak commented 4 years ago

Hello! I have bad news for you. I am also a Mac user and I was developing the library on Mac when I started, but I work on Ubuntu now and we always combine the simulator with ROS. I had to made a decision and move to OpenGL 4.3, to be able to use compute shaders. Apple is supporting max OpenGL 4.1 and that is why SDL2 fails. They don't care about the OpenGL anymore and 4.1 is an ancient version. I don't want to be limited. Therefore, I dropped the compatibility with Mac. I will think about Windows users because as much as I hate this system, there is a lot of poor fellow researchers using it :) Cheers