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

INSTALL_LOCAL option: allowing a specific compiler to be tested as a "system" compiler #202

Merged
merged 2 commits into from
Jan 29, 2018

Conversation

dra27
Copy link
Member

@dra27 dra27 commented Jan 18, 2018

This PR achieves the dual purpose of addressing my request in #175 which will allow, for example, the first beta of OCaml 4.07.0 to be tested in a Travis matrix and also builds on this tweak to provide a new option INSTALL_LOCAL for the Linux hosts which instead of switching to a particular OCaml version will instead compile it locally, install it to /usr/local and then have opam use that compiler as a system switch.

The primary motivation of this is opam-repository continuous testing of system installation on a platform with "normal" security (i.e. not macOS).

The support can probably be extended to osx hosts, but it's not necessary for what I'm after as brew tracks latest OCaml already and the inability to virtualise macOS makes it more of a pain to test than even I am willing to endure...

dra27 added a commit to dra27/opam-repository that referenced this pull request Jan 18, 2018
Until ocaml/ocaml-ci-scripts#202 is merged, then this commit can be
blown away.
@dra27 dra27 force-pushed the test-system-switches branch from 169bb3a to f8b31df Compare January 18, 2018 13:35
@avsm
Copy link
Member

avsm commented Jan 23, 2018

lgtm, but does need an entry in the README.travis about the new variable. thanks!

dra27 added 2 commits January 24, 2018 09:27
Previously, OPAM_SWITCH was given a default value of system which was
then subsequently ignored in all the branches.

OPAM_SWITCH is now only set if it wasn't previously given which allows,
for example, testing OCaml release candidates by specifying
OCAML_VERSION=4.07 OPAM_SWITCH=4.07.0+beta1 as part of a test matrix.

Resolves ocaml#175
Adding INSTALL_LOCAL=1 for Linux builds will build the compiler and
install it in /usr/local for use in a system opam switch.
@dra27 dra27 force-pushed the test-system-switches branch from f8b31df to 600bcd7 Compare January 24, 2018 09:36
@dra27
Copy link
Member Author

dra27 commented Jan 24, 2018

'tis done - I also took the opportunity to s/OPAM/opam/g - my new paragraphs are the very obvious green lumps in the diff, the other changes in README-travis.md are just that transformation.

@dra27
Copy link
Member Author

dra27 commented Jan 26, 2018

Hooray - it's finally passed CI 🙂

@yomimono
Copy link
Member

Merging this now while I'll be around to see whether it breaks anything. Thanks @dra27 ! :)

@yomimono yomimono merged commit 4dcb682 into ocaml:master Jan 29, 2018
@dra27 dra27 deleted the test-system-switches branch November 16, 2018 08:22
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

Successfully merging this pull request may close these issues.

3 participants