Hi Patricio,
By default, bzip2 only has one static library, libbz2.a, in its lib/ directory, if the user just does “make install” as the bzip2 README says.
That’s a good question, I agree. Since then, I don’t know why AMBER asks, “Perhaps you should add the directory containing `bzip2.pc' to the PKG_CONFIG_PATH environment variable”. I was unable to generate the pc file and maybe some expert can help.
Luckily, many “other programs that also depend on bzip2” can be independently compiled during the AMBER installation phase (boost is one example). So, I am not very concerned about that issue. To be safe, the user may just add these two lines to the ~/.bashrc file.
export PATH="/<path_to_bzip2>/bzip2/bin:$PATH"
export LD_LIBRARY_PATH="/<path_to_bzip2>/bzip2/lib:$LD_LIBRARY_PATH"
Regards,
Zhen.
From: Patricio Barletta via AMBER <amber.ambermd.org>
Date: Monday, November 4, 2024 at 4:15 PM
To: amber.ambermd.org <amber.ambermd.org>
Subject: [AMBER] BZIP2 Error when building Amber24
Hi,
I noticed that both are linking against a static library of bzip2. Have you tried linking against a dynamic library instead?
There's more than one program using bzip2 and there's also programs depending on other programs that also depend on bzip2. When that happens, the linking is of a static library is a bit more "demanding", since the client target expects the full code to be available, not just the definitions. Also, since linkage is different, CMake treats shared and static libraries differently and that may result in surprising behavior.
_______________________________________________
AMBER mailing list
AMBER.ambermd.org
https://urldefense.com/v3/__http://lists.ambermd.org/mailman/listinfo/amber__;!!HXCxUKc!yQFWVwHfClr63r3CJmJc8utAFN3bJwDt6kJPNkzgUIG53NIFJI2OFy8tL37B5lDOUiVsZNYPwBzWuqJGRMn8WpU$<
https://urldefense.com/v3/__http:/lists.ambermd.org/mailman/listinfo/amber__;!!HXCxUKc!yQFWVwHfClr63r3CJmJc8utAFN3bJwDt6kJPNkzgUIG53NIFJI2OFy8tL37B5lDOUiVsZNYPwBzWuqJGRMn8WpU$>
_______________________________________________
AMBER mailing list
AMBER.ambermd.org
http://lists.ambermd.org/mailman/listinfo/amber
Received on Mon Nov 04 2024 - 14:30:14 PST