mersenneforum.org  

Go Back   mersenneforum.org > Great Internet Mersenne Prime Search > Software

Reply
 
Thread Tools
Old 2014-10-24, 04:41   #1
hangxanh
 
"hang"
Oct 2014
ho chi minh city

3 Posts
Default Information about PRPNet Build Errors on Linux

Hi. I've tried numerous times to build PRPNet on Linux, with no success. The error message says that it cannot be linked. Any solutions? Trying to use PRPNet 5.0.7 on Kubuntu 11.10 (soon to be 12.04) x64.
thank's.
hangxanh is offline   Reply With Quote
Old 2014-10-24, 08:52   #2
amphoria
 
amphoria's Avatar
 
"Dave"
Sep 2005
UK

277610 Posts
Default

If it's the same error as I got, then the linking will work if you move -lpthread after all the object files on the line that links prpserver. Goodness knows why Ubuntu requires this but it does work if the error message relates to functions in the pthread library.
amphoria is offline   Reply With Quote
Old 2014-10-24, 16:22   #3
Dubslow
Basketry That Evening!
 
Dubslow's Avatar
 
"Bunslow the Bold"
Jun 2011
40<A<43 -89<O<-88

722110 Posts
Default

Quote:
Originally Posted by amphoria View Post
If it's the same error as I got, then the linking will work if you move -lpthread after all the object files on the line that links prpserver. Goodness knows why Ubuntu requires this but it does work if the error message relates to functions in the pthread library.
The way ld parses parameters means that how it searches for unlinked symbols depends on the order of the parameters.

Namely, when searching a targeted -l<whatever>, it doesn't create a list of all symbols in that lib, but rather only looks for any currently-unlinked symbols in the lib.

So if it searches the lib *before* the unlinked-symbol is declared, it will declare that symbol unlinked, even though the correct lib is in the command. The solution is to put all libs last.

This "bug" has been a well known issue for years, and sadly can be quite difficult to diagnose (especially for beginners/those who haven't encountered it before) because it's such an unintuitive problem (and the error message it produces it entirely unrelated to the error).
Dubslow is offline   Reply With Quote
Reply



Similar Threads
Thread Thread Starter Forum Replies Last Post
Configuring PRPNet ODBC on Linux amphoria Software 11 2020-01-14 14:23
[Patch] CPU affinity prompt problem in mprime Linux / OS X build Explorer09 Software 1 2017-03-01 02:34
PRPNet Build Errors on Linux Happy5214 Software 8 2012-05-18 12:42
Is More Information Better? davar55 Puzzles 3 2009-07-02 20:25
Linux build for LLRNet client available! axn Sierpinski/Riesel Base 5 9 2008-11-26 03:47

All times are UTC. The time now is 09:13.


Sat Jul 17 09:13:10 UTC 2021 up 50 days, 7 hrs, 1 user, load averages: 1.50, 1.71, 1.62

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2021, Jelsoft Enterprises Ltd.

This forum has received and complied with 0 (zero) government requests for information.

Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation.
A copy of the license is included in the FAQ.