Bug 891909
Summary: | Can't make install with non-standard prefix as non-root | ||
---|---|---|---|
Product: | [Community] Virtualization Tools | Reporter: | Matthew Booth <mbooth> |
Component: | libguestfs | Assignee: | Richard W.M. Jones <rjones> |
Status: | NEW --- | QA Contact: | |
Severity: | unspecified | Docs Contact: | |
Priority: | unspecified | ||
Version: | unspecified | CC: | berrange |
Target Milestone: | --- | ||
Target Release: | --- | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | Bug Fix | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | Type: | Bug | |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: |
Description
Matthew Booth
2013-01-04 12:24:53 UTC
Yeah I suspect there are lots of issues with using a prefix. We have never tested this. (DESTDIR OTOH *does* work, since that's what we use to build RPMs). Anyhow, patches welcome! (In reply to comment #0) > In the ocaml directory, the issue is: > > $(OCAMLFIND) install \ > -ldconf ignore -destdir $(DESTDIR)$(OCAMLLIB) \ > guestfs \ > META *.so *.a *.cma *.cmx *.cmxa *.cmi $(srcdir)/*.mli > > It tries to install to $(OCAMLLIB), which was obtained from 'ocamlc -where', > and therefore points to the system location rather than a directory under > $(prefix). Note that DESTDIR is orthoganal to this issue. About this, I don't really think you would want this to obey $(prefix). The correct place to install OCaml libraries is in `ocamlc -where`. If you install them some other place then you end up having to set environment variables. (In reply to comment #1) > > In the ocaml directory, the issue is: > > > > $(OCAMLFIND) install \ > > -ldconf ignore -destdir $(DESTDIR)$(OCAMLLIB) \ > > guestfs \ > > META *.so *.a *.cma *.cmx *.cmxa *.cmi $(srcdir)/*.mli > > > > It tries to install to $(OCAMLLIB), which was obtained from 'ocamlc -where', > > and therefore points to the system location rather than a directory under > > $(prefix). Note that DESTDIR is orthoganal to this issue. > > About this, I don't really think you would want this to > obey $(prefix). The correct place to install OCaml libraries > is in `ocamlc -where`. If you install them some other place > then you end up having to set environment variables. IMHO if you are trying to build into a non-standard prefix, then setting environment variables is to be expected. eg if you build into $HOME/libguestfs you'll already need to set $PATH, $LD_LIBRARY_PATH for the binaries/libraries. Setting other things like PERL5LIB, PYTHONPATH, and whatever for OCAML is totally reasonable. |