OCaml Forge
Bugs
Search the entire project
This project's trackers
This project's releases
This project's documents
This project's news
Project
People
Advanced search
Log In
New Account
Home
My Page
Projects
Code Snippets
OASIS
Summary
Activity
Tracker
Lists
Docs
News
Files
Detail: [#718] --prefix & --destdir aren't honoured by *all* things that are installed
Bugs: Browse
|
Download .csv
|
Monitor
[#718] --prefix & --destdir aren't honoured by *all* things that are installed
Date:
2010-08-21 23:20
Priority:
3
State:
Open
Submitted by:
Magnus Therning (
magthe
)
Assigned to:
Sylvain Le Gall (gildor-admin)
Product:
None
Due in version:
0.4.9
Resolution:
Accepted As Bug
Severity:
None
Version:
None
Component:
None
Operating System:
None
URL:
Summary:
--prefix & --destdir aren't honoured by *all* things that are installed
Detailed description
During my attempts of packaging OASIS and its dependencies for ArchLinux I basically performed the following steps:
% ocaml ./setup.ml -configure --prefix /usr --destdir pkg_taging_dir
% ocaml ./setup.ml -build
% ocaml ./setup.ml -install
Just to find that the destination dir I passed in at the configuration step wasn't honoured when the package included an ocaml library/module. In that case OASIS attempted to install the files in /usr/lib/ocaml/site-lib/<pkg name>.
The expectation was that *exactly* the steps above would be all that's needed to stage a package using OASIS.
Followup
Message
Date: 2016-06-19 14:24
Sender:
Sylvain Le Gall
Related:
[#1125]
setup.ml -configure --prefix is sometimes ignored
https://forge.ocamlcore.org/tracker/index.php?func=detail&aid=1125&group_id=54&atid=291
Date: 2014-11-12 21:02
Sender:
Nicolas Braud-Santoni
PS: I believe that having ocamlfind_destdir be destdir/`ocamlfind printconf destdir` by default would be reasonable semantics for -destdir, tough.
As Magnus remarked, expecting an ocamlfind-specific flag exposes the fact that ocamlfind is being used, and breaks the principle of least astonishment.
Date: 2014-11-12 20:55
Sender:
Nicolas Braud-Santoni
This issue can be worked-around in the following way:
OCAMLFIND_DESTDIR="${DESTDIR}$(ocamlfind printconf destdir)"
mkdir -p "${OCAMLFIND_DESTDIR}"
OCAMLFIND_DESTDIR="${OCAMLFIND_DESTDIR}" ocaml setup.ml -install --destdir "${DESTDIR}"
However, it would be great if this bug was fixed.
Date: 2010-08-25 19:58
Sender:
Magnus Therning
Sure, it's OK.
I just have to say that it isn't very elegant at all, since it leaks the fact that "ocamlfind" is used underneath. I fully realise that it is the most logical choice, and that this relative ugliness in oasis stems from the fact that "ocamlfind" is an amazingly confused tool that reeks of feature creep and strange design decisions.
Date: 2010-08-24 10:35
Sender:
Sylvain Le Gall
--destdir has a special meaning for general configure flag (just as prefix) and it applies to everything that is installed (data/bin) except.
The best option I can provide to you is the following:
- add an ocamlfind_destdir variable default to None
- you can configure it with --ocamlfind-destdir XXX/usr/lib/ocaml
- if you set destdir set ocamlfind_destdir to $(destdir)/$(ocamlfind printconf destdir)
- when invoking ocam setup.ml -install, if the variable ocamlfind_destdir has a value, add --destdir $(ocamlfind_destdir) to the command line, otherwise don't add anything
Is this ok for you ?
Attached Files:
Changes:
Field
Old Value
Date
By
Due in version
0.4.7
2016-09-03 21:31
gildor-admin
Due in version
None
2016-06-19 14:24
gildor-admin
Resolution
None
2016-06-19 14:24
gildor-admin
assigned_to
none
2010-08-24 10:35
gildor-admin