caml-list - the Caml user's mailing list
 help / Atom feed
* [Caml-list] Opam: using both 1.2 and 2.0
@ 2019-01-07  8:12 Sébastien Hinderer
  2019-01-07  9:23 ` Daniel Bünzli
  0 siblings, 1 reply; 9+ messages in thread
From: Sébastien Hinderer @ 2019-01-07  8:12 UTC (permalink / raw)
  To: caml-list

Dear all,

Although Debian now ships Opam 2.0, I'd like to also be able to use Opam
1.2 because one of the projects I'd like to work on still uses that version
of Opam.

Is there a suggested way to achieve this?

I am considering using an older Debian in a chroot but am wondering
whether a lighter solution would be available?

Best wishes,

Sébastien.

-- 
Caml-list mailing list.  Subscription management and archives:
https://sympa.inria.fr/sympa/arc/caml-list https://inbox.ocaml.org/caml-list
Forum: https://discuss.ocaml.org/
Bug reports: http://caml.inria.fr/bin/caml-bugs

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [Caml-list] Opam: using both 1.2 and 2.0
  2019-01-07  8:12 [Caml-list] Opam: using both 1.2 and 2.0 Sébastien Hinderer
@ 2019-01-07  9:23 ` Daniel Bünzli
  2019-01-07  9:25   ` Sébastien Hinderer
  0 siblings, 1 reply; 9+ messages in thread
From: Daniel Bünzli @ 2019-01-07  9:23 UTC (permalink / raw)
  To: caml-list, Sébastien Hinderer

On 7 January 2019 at 09:12:12, Sébastien Hinderer (sebastien.hinderer@inria.fr) wrote:

> Is there a suggested way to achieve this?

I guess the easiest would be to make a wrapper shell script for opam v1.2 that sets OPAMROOT to a place where it can operate without disturbing your opam v2 install. 

Best, 

Daniel





-- 
Caml-list mailing list.  Subscription management and archives:
https://sympa.inria.fr/sympa/arc/caml-list https://inbox.ocaml.org/caml-list
Forum: https://discuss.ocaml.org/
Bug reports: http://caml.inria.fr/bin/caml-bugs

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [Caml-list] Opam: using both 1.2 and 2.0
  2019-01-07  9:23 ` Daniel Bünzli
@ 2019-01-07  9:25   ` Sébastien Hinderer
  2019-01-07  9:52     ` Daniel Bünzli
  2019-01-07 15:50     ` Hendrik Boom
  0 siblings, 2 replies; 9+ messages in thread
From: Sébastien Hinderer @ 2019-01-07  9:25 UTC (permalink / raw)
  To: caml-list

Daniel Bünzli (2019/01/07 10:22 +0100):
> On 7 January 2019 at 09:12:12, Sébastien Hinderer (sebastien.hinderer@inria.fr) wrote:
> 
> > Is there a suggested way to achieve this?
> 
> I guess the easiest would be to make a wrapper shell script for opam
> v1.2 that sets OPAMROOT to a place where it can operate without
> disturbing your opam v2 install. 

Will try that! Thanks! But still have to figure out how to install opam
1 I guess, because it will probably not be possible to install it
through the distribution's package manager.

Best wishes,

Sébastien.

-- 
Caml-list mailing list.  Subscription management and archives:
https://sympa.inria.fr/sympa/arc/caml-list https://inbox.ocaml.org/caml-list
Forum: https://discuss.ocaml.org/
Bug reports: http://caml.inria.fr/bin/caml-bugs

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [Caml-list] Opam: using both 1.2 and 2.0
  2019-01-07  9:25   ` Sébastien Hinderer
@ 2019-01-07  9:52     ` Daniel Bünzli
  2019-01-07 23:25       ` Jacques Garrigue
  2019-01-21 14:54       ` Sébastien Hinderer
  2019-01-07 15:50     ` Hendrik Boom
  1 sibling, 2 replies; 9+ messages in thread
From: Daniel Bünzli @ 2019-01-07  9:52 UTC (permalink / raw)
  To: caml-list, Sébastien Hinderer

On 7 January 2019 at 10:25:10, Sébastien Hinderer (sebastien.hinderer@inria.fr) wrote:

> Will try that! Thanks! But still have to figure out how to install opam
> 1 I guess, because it will probably not be possible to install it
> through the distribution's package manager.

opam dev's are kind enough to provide you with a selection of binaries here: 

  https://github.com/ocaml/opam/releases/tag/1.2.2

I never tried them though. Otherwise given an OCaml install, compiling from the tarball should be easy has never been a problem since it's self-contained.

Best,

Daniel



-- 
Caml-list mailing list.  Subscription management and archives:
https://sympa.inria.fr/sympa/arc/caml-list https://inbox.ocaml.org/caml-list
Forum: https://discuss.ocaml.org/
Bug reports: http://caml.inria.fr/bin/caml-bugs

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [Caml-list] Opam: using both 1.2 and 2.0
  2019-01-07  9:25   ` Sébastien Hinderer
  2019-01-07  9:52     ` Daniel Bünzli
@ 2019-01-07 15:50     ` Hendrik Boom
  2019-01-07 21:11       ` Sébastien Hinderer
  1 sibling, 1 reply; 9+ messages in thread
From: Hendrik Boom @ 2019-01-07 15:50 UTC (permalink / raw)
  To: caml-list

On Mon, Jan 07, 2019 at 10:25:10AM +0100, Sébastien Hinderer wrote:
> Daniel Bünzli (2019/01/07 10:22 +0100):
> > On 7 January 2019 at 09:12:12, Sébastien Hinderer (sebastien.hinderer@inria.fr) wrote:
> > 
> > > Is there a suggested way to achieve this?
> > 
> > I guess the easiest would be to make a wrapper shell script for opam
> > v1.2 that sets OPAMROOT to a place where it can operate without
> > disturbing your opam v2 install. 
> 
> Will try that! Thanks! But still have to figure out how to install opam
> 1 I guess, because it will probably not be possible to install it
> through the distribution's package manager.

You could try dowloading the .deb from an older Deboan release and using dpkg.
That's if the package depedencies haven't changed much.

Or you could try edit /etc/apt/sources.lst,
    apt-get update, 
    apt-get-install opam
and then put sources.lst back the way it was and
    apt-get update
again.

That requires the old dependencies not to conflict with the new ones.  

And in any case you'd probably have to move the old opam binary before 
you reinstall the new one.

-- hendrik

> 
> Best wishes,
> 
> Sébastien.
> 
> -- 
> Caml-list mailing list.  Subscription management and archives:
> https://sympa.inria.fr/sympa/arc/caml-list https://inbox.ocaml.org/caml-list
> Forum: https://discuss.ocaml.org/
> Bug reports: http://caml.inria.fr/bin/caml-bugs

-- 
Caml-list mailing list.  Subscription management and archives:
https://sympa.inria.fr/sympa/arc/caml-list https://inbox.ocaml.org/caml-list
Forum: https://discuss.ocaml.org/
Bug reports: http://caml.inria.fr/bin/caml-bugs

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [Caml-list] Opam: using both 1.2 and 2.0
  2019-01-07 15:50     ` Hendrik Boom
@ 2019-01-07 21:11       ` Sébastien Hinderer
  0 siblings, 0 replies; 9+ messages in thread
From: Sébastien Hinderer @ 2019-01-07 21:11 UTC (permalink / raw)
  To: caml-list

Hi,

May thanks for your response.

> You could try dowloading the .deb from an older Deboan release and using dpkg.
> That's if the package depedencies haven't changed much.
> 
> Or you could try edit /etc/apt/sources.lst,
>     apt-get update, 
>     apt-get-install opam
> and then put sources.lst back the way it was and
>     apt-get update
> again.
> 
> That requires the old dependencies not to conflict with the new ones.

I don't think that would work because dpkg wouldn't let you intall two
packages with the exact same name.

But that's okay, I'll figure something out and report back here, thanks.

Sébastien.

-- 
Caml-list mailing list.  Subscription management and archives:
https://sympa.inria.fr/sympa/arc/caml-list https://inbox.ocaml.org/caml-list
Forum: https://discuss.ocaml.org/
Bug reports: http://caml.inria.fr/bin/caml-bugs

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [Caml-list] Opam: using both 1.2 and 2.0
  2019-01-07  9:52     ` Daniel Bünzli
@ 2019-01-07 23:25       ` Jacques Garrigue
  2019-01-21 14:54       ` Sébastien Hinderer
  1 sibling, 0 replies; 9+ messages in thread
From: Jacques Garrigue @ 2019-01-07 23:25 UTC (permalink / raw)
  To: Daniel Bünzli; +Cc: Mailing List OCaml, Sébastien Hinderer

[-- Attachment #1: Type: text/plain, Size: 1414 bytes --]

Actually I'm always using those binaries.
It's simpler than going through another package manager which may be late
to update, and you just have to install one file in your path.

Jacques

2019年1月7日(月) 18:52、Daniel Bünzli さん(daniel.buenzli@erratique.ch)のメッセージ:

> On 7 January 2019 at 10:25:10, Sébastien Hinderer (
> sebastien.hinderer@inria.fr) wrote:
>
> > Will try that! Thanks! But still have to figure out how to install opam
> > 1 I guess, because it will probably not be possible to install it
> > through the distribution's package manager.
>
> opam dev's are kind enough to provide you with a selection of binaries
> here:
>
>   https://github.com/ocaml/opam/releases/tag/1.2.2
>
> I never tried them though. Otherwise given an OCaml install, compiling
> from the tarball should be easy has never been a problem since it's
> self-contained.
>
> Best,
>
> Daniel
>
>
>
> --
> Caml-list mailing list.  Subscription management and archives:
> https://sympa.inria.fr/sympa/arc/caml-list
> https://inbox.ocaml.org/caml-list
> Forum: https://discuss.ocaml.org/
> Bug reports: http://caml.inria.fr/bin/caml-bugs

-- 
Caml-list mailing list.  Subscription management and archives:
https://sympa.inria.fr/sympa/arc/caml-list https://inbox.ocaml.org/caml-list
Forum: https://discuss.ocaml.org/
Bug reports: http://caml.inria.fr/bin/caml-bugs

[-- Attachment #2: Type: text/html, Size: 2114 bytes --]

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [Caml-list] Opam: using both 1.2 and 2.0
  2019-01-07  9:52     ` Daniel Bünzli
  2019-01-07 23:25       ` Jacques Garrigue
@ 2019-01-21 14:54       ` Sébastien Hinderer
  2019-01-21 16:09         ` Anil Madhavapeddy
  1 sibling, 1 reply; 9+ messages in thread
From: Sébastien Hinderer @ 2019-01-21 14:54 UTC (permalink / raw)
  To: caml-list

Hi,

Daniel Bünzli (2019/01/07 10:52 +0100):
> On 7 January 2019 at 10:25:10, Sébastien Hinderer (sebastien.hinderer@inria.fr) wrote:
> 
> > Will try that! Thanks! But still have to figure out how to install opam
> > 1 I guess, because it will probably not be possible to install it
> > through the distribution's package manager.
> 
> opam dev's are kind enough to provide you with a selection of binaries here: 
> 
>   https://github.com/ocaml/opam/releases/tag/1.2.2
> 
> I never tried them though. Otherwise given an OCaml install, compiling
> from the tarball should be easy has never been a problem since it's
> self-contained.

I just wanted to thank you for the suggestion and confirm that it worked
quite well. I downloaded the binary for my platform and installed it in my
private bin directory as 'opam1'. When I want to use it, rather than the
system-provided opam (version 2), I create a symlink in my bin
directory.

Then I just had to do:

opam init --root=~/.opam1

and everything wored fine.

Bets wishes,

Sébastien.

-- 
Caml-list mailing list.  Subscription management and archives:
https://sympa.inria.fr/sympa/arc/caml-list https://inbox.ocaml.org/caml-list
Forum: https://discuss.ocaml.org/
Bug reports: http://caml.inria.fr/bin/caml-bugs

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [Caml-list] Opam: using both 1.2 and 2.0
  2019-01-21 14:54       ` Sébastien Hinderer
@ 2019-01-21 16:09         ` Anil Madhavapeddy
  0 siblings, 0 replies; 9+ messages in thread
From: Anil Madhavapeddy @ 2019-01-21 16:09 UTC (permalink / raw)
  To: Sébastien Hinderer; +Cc: caml-list

On 21 Jan 2019, at 14:54, Sébastien Hinderer <Sebastien.Hinderer@inria.fr> wrote:
> 
> Hi,
> 
> Daniel Bünzli (2019/01/07 10:52 +0100):
>> On 7 January 2019 at 10:25:10, Sébastien Hinderer (sebastien.hinderer@inria.fr) wrote:
>> 
>>> Will try that! Thanks! But still have to figure out how to install opam
>>> 1 I guess, because it will probably not be possible to install it
>>> through the distribution's package manager.
>> 
>> opam dev's are kind enough to provide you with a selection of binaries here: 
>> 
>>   https://github.com/ocaml/opam/releases/tag/1.2.2
>> 
>> I never tried them though. Otherwise given an OCaml install, compiling
>> from the tarball should be easy has never been a problem since it's
>> self-contained.
> 
> I just wanted to thank you for the suggestion and confirm that it worked
> quite well. I downloaded the binary for my platform and installed it in my
> private bin directory as 'opam1'. When I want to use it, rather than the
> system-provided opam (version 2), I create a symlink in my bin
> directory.
> 
> Then I just had to do:
> 
> opam init --root=~/.opam1
> 
> and everything wored fine.
> 

Excellent, glad to hear that’s working for you now!

In the medium-term, please do let us opam developers know if there is
some fundamental reason why you cannot migrate your projects from
opam 1 to 2.  We will do our best to unblock it in opam 2, since we
can’t fully leave opam 1 behind until the last user has closed the door
behind them :-)

regards,
Anil


-- 
Caml-list mailing list.  Subscription management and archives:
https://sympa.inria.fr/sympa/arc/caml-list https://inbox.ocaml.org/caml-list
Forum: https://discuss.ocaml.org/
Bug reports: http://caml.inria.fr/bin/caml-bugs

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, back to index

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-01-07  8:12 [Caml-list] Opam: using both 1.2 and 2.0 Sébastien Hinderer
2019-01-07  9:23 ` Daniel Bünzli
2019-01-07  9:25   ` Sébastien Hinderer
2019-01-07  9:52     ` Daniel Bünzli
2019-01-07 23:25       ` Jacques Garrigue
2019-01-21 14:54       ` Sébastien Hinderer
2019-01-21 16:09         ` Anil Madhavapeddy
2019-01-07 15:50     ` Hendrik Boom
2019-01-07 21:11       ` Sébastien Hinderer

caml-list - the Caml user's mailing list

Archives are clonable: git clone --mirror https://inbox.ocaml.org/caml-list

AGPL code for this site: git clone https://public-inbox.org/ public-inbox