Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add linux gomp and post link to screened poisson #55

Merged
merged 2 commits into from
Jan 17, 2017
Merged

Add linux gomp and post link to screened poisson #55

merged 2 commits into from
Jan 17, 2017

Conversation

bartoszek
Copy link
Contributor

@bartoszek bartoszek commented Jan 15, 2017

The project file for screened poisson is lacking linux linker flag -lgomp and post link filter_screened_poisson.xml copying script.
The libfilter_screened_poisson.xml link is somehow needed for plugin manager to work correctly on linux (help>about_plugins menu is empty for screened_poisson plugin without it)
mutualinfo, measure, and sketchfab plugins share this problem too

also extend post link file copying to include linux build ( linking is somewhat strange but wont work without )
@eboudrand
Copy link
Contributor

eboudrand commented Jan 16, 2017

I recompiled meshlab with your patch and run it. When I apply Screened poisson plugin, Meshlab crashes with error "undefined symbol: omp_get_num_procs". I am using Ubuntu 16.04 64bit. Do you met this issue ?

@bartoszek
Copy link
Contributor Author

bartoszek commented Jan 16, 2017

Yes, this is the issue I got when building bare meshlab repository on Arch Linux.
This patch fixes the issue for me.
Already include it in my AUR meshlab package

@eboudrand
Copy link
Contributor

I added test -h "lib"$$TARGET".xml" in QMAKE_POST_LINK before ln -s "$$TARGET".xml lib"$$TARGET".xml" because I had an error (file already exists). My QMAKE_POST_LINK line is :

linux:QMAKE_POST_LINK = "cp "$$_PRO_FILE_PWD_/$$TARGET".xml ../../distrib/plugins/"$$TARGET".xml; cd ../../distrib/plugins/ ; test -h "lib"$$TARGET".xml" || ln -s "$$TARGET".xml lib"$$TARGET".xml"

@bartoszek
Copy link
Contributor Author

bartoszek commented Jan 16, 2017

I recompiled meshlab with your patch and run it. When I apply Screened poisson plugin, Meshlab crashes with error "undefined symbol: omp_get_num_procs"

Have the same error on Ubuntu 16.10 despite correct flags passed to linker invocation

g++ -m64 -lgomp -Wl,-O1 -shared -o libfilter_screened_poisson.so filter_screened_poisson.o MarchingCubes.o PlyFile.o Factor.o Geometry.o moc_filter_screened_poisson.o -L/usr/X11R6/lib64 -L../../distrib -lcommon -lGLU -lQt5OpenGL -lQt5Widgets -lQt5Gui -lQt5Xml -lQt5XmlPatterns -lQt5Network -lQt5Script -lQt5Core -lGL -lpthread

@bartoszek
Copy link
Contributor Author

bartoszek commented Jan 17, 2017

Solution was to add -fopenmp linker flag.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants