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

Possibly wrong library path/pkg_arch on debian/ubuntu 64bit #11

Open
daritter opened this issue Mar 1, 2016 · 4 comments
Open

Possibly wrong library path/pkg_arch on debian/ubuntu 64bit #11

daritter opened this issue Mar 1, 2016 · 4 comments

Comments

@daritter
Copy link
Contributor

daritter commented Mar 1, 2016

Hi,

when compiling DAVIX on debian/ubuntu 64bit the logic to determine the library path suffix is not correct: It checks for the existence of /usr/lib64 but this directory does (usually) not exist on debian/ubuntu. As such PKG_ARCH is usually set to i386 but that doesn't seem to be a problem. However we do have some issues wen using davix with ROOT as the ROOT compilation cannot find the library in some cases.

The official GNUInstallDirs module from cmake determines the path differently by checking if /etc/debian_version exists and doing a different logic in that case. Would it be possible to adapt the same logic for davix? Or just use GNUInstallDirs?

Cheers,

Martin

@adevress
Copy link
Contributor

adevress commented Mar 1, 2016

Hi Martin,

You can override this behavior at compilation time by adding
'-DLIB_SUFFIX="" ' to the cmake command line. It will force davix to use
/usr/lib and not /usr/lib64

Cheers,
Adrien

Le 01/03/2016 12:02, Martin Ritter a écrit :

Hi,

when compiling DAVIX on debian/ubuntu 64bit the logic to determine the
library path suffix is not correct: It checks for the existence of
/usr/lib64 but this directory does (usually) not exist on
debian/ubuntu. As such PKG_ARCH is usually set to i386 but that
doesn't seem to be a problem. However we do have some issues wen using
davix with ROOT as the ROOT compilation cannot find the library in
some cases.

The official GNUInstallDirs module from cmake determines the path
differently by checking if /etc/debian_version exists and doing a
different logic in that case. Would it be possible to adapt the same
logic for davix? Or just use GNUInstallDirs?

Cheers,

Martin


Reply to this email directly or view it on GitHub
#11.

@daritter
Copy link
Contributor Author

daritter commented Mar 1, 2016

Dear Adrien,

thanks for the information. While this is fine for me I still think that the current behavior is not correct on debian/ubuntu. Are you planning to fix this in the future?

Cheers,
Martin

@gbitzes
Copy link
Contributor

gbitzes commented Mar 2, 2016

Hi Martin,

You are right that in this case, setting PKG_ARCH to i386 is not semantically correct, but this variable isn't used anywhere else, as far I see, and the binaries produced are indeed x86_64, not x86.

A change we could make is place the library in /usr/lib/x86_64-linux-gnu instead of /usr/lib - is this what you are suggesting?

If not, in which cases does ROOT complain? Could you specify an example?

Thanks

@daritter
Copy link
Contributor Author

daritter commented Mar 2, 2016

Dear Georgios,

ROOT only complained if davix was compiled automatically during root compilation as there could be a mismatch between the place davix puts the library and where root looks for it. But I think this is now solved using the -DLIB_SUFFIX and this should be more robust then the previous approach (https://sft.its.cern.ch/jira/browse/ROOT-7912).

But yes, in general I suggest putting the library in /usr/lib/x86_64-linux-gnu on platforms which use this scheme.

Cheers,

Martin

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

No branches or pull requests

3 participants