georgmartius / vid.stab

Video stabilization library
http://public.hronopik.de/vid.stab/
Other
838 stars 110 forks source link

Openmp: Try using FindOpenMP again #94

Closed 1480c1 closed 3 years ago

1480c1 commented 3 years ago

https://github.com/georgmartius/vid.stab/commit/ce0ea9ac5edcdc568a72ee169b800e39a6c543c6

as mentioned here, the previous attempt needed to be reverted

georgmartius commented 3 years ago

How is the status of this? I didn't follow up on this. The FindOpenMP was not available for older CMake versions, right?

1480c1 commented 3 years ago

For now, it's working on Ubuntu 20.04 gcc and clang and mingw-w64 gcc and mingw-w64 clang

FindOpenMP is listed under cmake's doc for 2.8.5 (the required version I see in the CMakeLists.txt) https://cmake.org/cmake/help/v2.8.5/cmake.html#module:FindOpenMP

I think @ddennedy said it's working on his machines, except macOS, and I don't remember if I heard a followup on if there were any new issues

I am considering instead adding a small compile and link test to the CMakeLists to make sure that the found flags for openmp actually work, but I am not sure if it will be completely worth the added complexity. Do you have any comments or suggestion on that part?

ddennedy commented 3 years ago

I approve of merging this. FYI, upon further troubleshooting here is the interesting problem I had. I am building vid.stab on macOS with gcc and libgomp because Xcode does not include OpenMP. This puts a -fopenmp into the png-config file. Later when I link my code that is built with the default compiler - clang from Xcode - against vid.stab it does not understand that flag. :-S