Please read this before reporting a bug:
https://wiki.archlinux.org/title/Bug_reporting_guidelines
Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.
REPEAT: Do NOT report bugs for outdated packages!
https://wiki.archlinux.org/title/Bug_reporting_guidelines
Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.
REPEAT: Do NOT report bugs for outdated packages!
FS#17672 - [llvm] [llvm-ocaml] mssing shared libs and incorrect permissions
Attached to Project:
Community Packages
Opened by George Giorgidze (giorgidze) - Friday, 01 January 2010, 20:06 GMT
Last edited by Evangelos Foutras (foutrelis) - Saturday, 09 January 2010, 19:36 GMT
Opened by George Giorgidze (giorgidze) - Friday, 01 January 2010, 20:06 GMT
Last edited by Evangelos Foutras (foutrelis) - Saturday, 09 January 2010, 19:36 GMT
|
DetailsDescription:
* Shared libraries are missing in llvm package * Static libraries do not have 644 file permission in llvm-ocaml package Additional info: * package version(s): llvm 2.6-4 Steps to reproduce: > pacman -S llvm > pacman -S llvm-ocaml I also suggest to configure llvm with "--enable-targets=all". Cheers, George |
This task depends upon
Closed by Evangelos Foutras (foutrelis)
Saturday, 09 January 2010, 19:36 GMT
Reason for closing: Fixed
Additional comments about closing: Fixed library permissions in llvm-ocaml and enabled all targets (2.6-5). Enabled libffi (2.6-6).
Saturday, 09 January 2010, 19:36 GMT
Reason for closing: Fixed
Additional comments about closing: Fixed library permissions in llvm-ocaml and enabled all targets (2.6-5). Enabled libffi (2.6-6).
What benefit(s) would '--enable-targets=all' give us?
If I'm mistaken somewhere, please let me know. :)
Yes it does,
# Install shared libs
make -j1 SHARED_LIBRARY=1 || return 1
cp Release/lib/libLLVM*.so "${pkgdir}/usr/lib/llvm" || return 1
will install the shared libraries. I am attaching PKGBUILD that makes use of the above code. For further details see http://llvm.org/docs/MakefileGuide.html
> applications that use it, link statically to it.
No, shared libs are essential for many LLVM applications, e.g., to load LLVM JIT compiler (libLLVMJIT.so) dynamically if needed, to name just one.
> What benefit(s) would '--enable-targets=all' give us?
Cross compilation, i.e., to generate code for target architectures and platforms other than the host.
Hope this helps.
Thanks for taking your time for improving llvm package.
Cheers, George
The permissions issue with llvm-ocaml should be corrected in 2.6-5. I also enabled all targets, like you suggested.
At any rate, you certainly seem to know more about LLVM than I do, so please excuse me if I'm misunderstanding something. Feel free to provide further suggestions for improvement. :)
I do understand . However, I do not think that if something is wrong with Debian and Fedora packages Arch needs to inherit the deficiencies. Quite opposite Arch should try to improve on them. All shared vs. static arguments do apply here, I also outlined why LLVM shared libraries are really useful, and after all LLVM's build system provides a way to build shared libraries, both in its CMake and autotool incarnations. So why should not we use it and improve the package.
I am attaching PKGBUILD that builds LLVM shared libraries as a separate package. I am not suggesting that we should use the provided PKGBUILD. This just to demonstrate that it can be done.
> The permissions issue with llvm-ocaml should be corrected in 2.6-5. I also enabled all targets, like you suggested.
Thanks a lot, very much appreciated, I have seen the improvements in LLVM 2.6-5.
> Feel free to provide further suggestions for improvement. :)
One more improvement please. Because libffi header files are installed in a non-standard location, LLVM's configure script assumes that libffi is not available. libffi support is enabled by default in LLVM and is needed to run natively compiled code in LLVM interpreter (very useful feature).
I suggest we add CPPFLAGS="-I/usr/lib/libffi-3.0.8/include" to configure and make lines see attached PKGBUILD. This also required libffi to be added as a dependency.
Thanks in advance for your consideration.
Cheers, George
I'm still not going forward with the shared libraries (at least for now). I'm not interested in following what Fedora or Debian does, but I'm obviously not going to ignore them completely either. Setting SHARED_LIBRARY ourselves simply feels like something that we shouldn't do. That is also the feeling I got when I asked in #llvm on IRC (although one of the two people that replied did acknowledge the validity of your libLLVMJIT.so example).
If I'm being overly stubborn, please excuse me and correct me. :)
Thanks a lot for the improvement, very much appreciated.
> I'm still not going forward with the shared libraries (at least for now). I'm not interested in following what Fedora or Debian does, but I'm obviously not going to ignore them completely either. Setting SHARED_LIBRARY ourselves simply feels like something that we shouldn't do. That is also the feeling I got when I asked in #llvm on IRC (although one of the two people that replied did acknowledge the validity of your libLLVMJIT.so example).
I do understand your concern regarding setting SHARED_LIBRARY ourselves. I am not suggesting to build shared libraries this way. All I am saying is that shared libraries for LLVM should be available. Almost all libraries in Arch (and other distros) come in both, static and shared, flavours. Why should LLVM be different. LLVM is a library for building compilers.
Going back to SHARED_LIBRARY variable. The reason I used it to build the shared libraries is that configure's "--enable-shared" flag had some problems on my system. The fact that such flag exists confirms the fact that LLVM is indeed intended to be used as a shared lib as well. As I understand the breakage of the flag is a bug in LLVM's autotools-based build system and building of shared libs is properly supported in LLVM's cmake-based build system.
I would like to suggest to investigate ways of building shared libs proper/acceptable way and even get in touch upstream with build system improvements and queries (if needed).
Cheers, George