[opensuse-packaging] Require a specific major version go1.X
Good morning ladies and gentlemen, is there any documentation on how to exactly require a specific version of go1.X (use go1.10, not any later version? Use go1.12 or later?)? I am (once again) new to packaging golang packages, and have some that seem to require newer versions, e.g. go1.12 or go.14. Others like git-lfs seem to not build correctly unless I tell them to build with go1.10. Not sure if this really fixes the build problems, and as I am not a go expert I cannot tell if this idea is complete bogus. Nevertheless, I'd like to try out... ;-) This seems to work: BuildRequire: go < 1.13 BuildRequire: go >= 1.12 This does not: BuildRequire: go1.12 Nope: BuildRequire: go = 1.12 (as the available version is 1.12.9 or something like that) Seems like this would be a useful information to add to https://en.opensuse.org/openSUSE:Packaging_Go (which I will update once I find out how to do that). Kind Regards, Johannes -- Johannes Kastl Linux Consultant & Trainer Tel.: +49 (0) 151 2372 5802 Mail: kastl@b1-systems.de B1 Systems GmbH Osterfeldstraße 7 / 85088 Vohburg http://www.b1-systems.de GF: Ralph Dehner Unternehmenssitz: Vohburg / AG: Ingolstadt,HRB 3537
Hello Johannes Am Donnerstag, 27. Februar 2020, 08:05:02 CET schrieb Johannes Kastl:
Good morning ladies and gentlemen,
is there any documentation on how to exactly require a specific version of go1.X (use go1.10, not any later version? Use go1.12 or later?)?
I am (once again) new to packaging golang packages, and have some that seem to require newer versions, e.g. go1.12 or go.14. Others like git-lfs seem to not build correctly unless I tell them to build with go1.10. Not sure if this really fixes the build problems, and as I am not a go expert I cannot tell if this idea is complete bogus. Nevertheless, I'd like to try out... ;-)
This seems to work: BuildRequire: go < 1.13 BuildRequire: go >= 1.12
Whats wrong with this solution?
This does not: BuildRequire: go1.12
Nope: BuildRequire: go = 1.12 (as the available version is 1.12.9 or something like that)
BuildRequire: go == 1.12 maybe? Ahoi Axel -- To unsubscribe, e-mail: opensuse-packaging+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-packaging+owner@opensuse.org
Hi Axel, Am 27.02.20 um 08:33 schrieb Axel Braun:
This seems to work: BuildRequire: go < 1.13 BuildRequire: go >= 1.12
Whats wrong with this solution?
Nothing. But normally there is a oneliner for these kind of things, so I was wondering how the oneline would look for go.
BuildRequire: go == 1.12 maybe?
Sorry, the single "=" was a typo, actually that was what I tried. I just tried again and now it works. Funny. Johannes -- Johannes Kastl Linux Consultant & Trainer Tel.: +49 (0) 151 2372 5802 Mail: kastl@b1-systems.de B1 Systems GmbH Osterfeldstraße 7 / 85088 Vohburg http://www.b1-systems.de GF: Ralph Dehner Unternehmenssitz: Vohburg / AG: Ingolstadt,HRB 3537
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA256 On 27/02/2020 08:05, Johannes Kastl wrote:
This seems to work: BuildRequire: go < 1.13 BuildRequire: go >= 1.12
Normally the solution that I use in my packages would look like somethin g: BuildRequires: go >= 1.12 BuildConflics: go >= 1.13 At least for me this kind of statement helps me to give an interval of java versions that can be used in different java packages. Cheers F. -----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEE0vVj9jiIqf7C3m1Y/q+OD6Q3QFUFAl5XeBAACgkQ/q+OD6Q3 QFXgQA/9GL8bt8E1ThGO8zjTmdMWJsvKROayCEbfkEbdI/Nh2HFKsrYkscTULU7O jvR7PvYFR6Lgj4NFcl4Y0gfEWUSB/yxy5vfiV5jyI5ymgStvXWfdEaoAt6AXgSG7 N7AFR5SUJ94fv4gWGUfmG0R6TdRZV1nV0R6SAkt8ZwgYAvdtIhteqZQrPqF4RlHP UZZvH931nm5oI21QKlv7XvV/EDzl/4EGkvssMIUwEkHiV9l7yMMqfKerLxZODweg 6oiLrl6NeeKf2AQ3hsikX6DN0kJWuDyuvc4cIg0x5/6E/j3k2c17UPwPbf2LxGh+ JIhV8kT595aQoXXfIRMezCowEzeC7AuqRtxLrZ+cgRetHztYJrzd+Wel6F1Prep2 ZikIwLhJoIX7eceakU2e7yGEsefsb+LXRBREWfCHNjfB5FI1VjR0vxt4N8c0kdAa 9+XjfsucyXOyPjWM5MGaW6t4jLLiLONYCrHNXF197FV9/IRI88yD2mZqHJ1KrKEr TB0miusFuGs5T7dqK13PiJJSV+OTFkO3ZUBO8/bK6ErNXLDBuGaueHr1B3ui49rL JHH2zbexR1NLwxMWV8fe2G43LDh1VX0yHf1ZFRoTf5wO7CwBpjpNm/m6ey7km4eE dY7m5hACSkhZd/2PjX1GLc+GRAAkMswhIbqAk0cCWdlCu0t+xOc= =rX05 -----END PGP SIGNATURE----- -- To unsubscribe, e-mail: opensuse-packaging+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-packaging+owner@opensuse.org
Am 27.02.20 um 09:04 schrieb Fridrich Strba:
Normally the solution that I use in my packages would look like somethin g:
BuildRequires: go >= 1.12 BuildConflics: go >= 1.13
At least for me this kind of statement helps me to give an interval of java versions that can be used in different java packages.
Thanks, will try that. Johannes -- Johannes Kastl Linux Consultant & Trainer Tel.: +49 (0) 151 2372 5802 Mail: kastl@b1-systems.de B1 Systems GmbH Osterfeldstraße 7 / 85088 Vohburg http://www.b1-systems.de GF: Ralph Dehner Unternehmenssitz: Vohburg / AG: Ingolstadt,HRB 3537
Am 2020-02-27 08:05, schrieb Johannes Kastl:
Good morning ladies and gentlemen,
is there any documentation on how to exactly require a specific version of go1.X (use go1.10, not any later version? Use go1.12 or later?)?
I am (once again) new to packaging golang packages, and have some that seem to require newer versions, e.g. go1.12 or go.14. Others like git-lfs seem to not build correctly unless I tell them to build with go1.10. Not sure if this really fixes the build problems, and as I am not a go expert I cannot tell if this idea is complete bogus. Nevertheless, I'd like to try out... ;-)
This seems to work: BuildRequire: go < 1.13 BuildRequire: go >= 1.12
Should be done.
This does not: BuildRequire: go1.12
Why should this not run? Package go1.12-1.12.17-1.1.x86_64.rpm provides go1.12 Perhaps. This is what i use: BuildRequires: config(go1.12) -- Regards Eric -- To unsubscribe, e-mail: opensuse-packaging+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-packaging+owner@opensuse.org
Am 27.02.20 um 11:26 schrieb Eric Schirra:
This does not: BuildRequire: go1.12
Why should this not run? Package go1.12-1.12.17-1.1.x86_64.rpm provides go1.12
Because go1.10 was still installed and used. Johannes -- Johannes Kastl Linux Consultant & Trainer Tel.: +49 (0) 151 2372 5802 Mail: kastl@b1-systems.de B1 Systems GmbH Osterfeldstraße 7 / 85088 Vohburg http://www.b1-systems.de GF: Ralph Dehner Unternehmenssitz: Vohburg / AG: Ingolstadt,HRB 3537
On Thu, Feb 27, 2020 at 2:05 AM Johannes Kastl <kastl@b1-systems.de> wrote:
Good morning ladies and gentlemen,
is there any documentation on how to exactly require a specific version of go1.X (use go1.10, not any later version? Use go1.12 or later?)?
I am (once again) new to packaging golang packages, and have some that seem to require newer versions, e.g. go1.12 or go.14. Others like git-lfs seem to not build correctly unless I tell them to build with go1.10. Not sure if this really fixes the build problems, and as I am not a go expert I cannot tell if this idea is complete bogus. Nevertheless, I'd like to try out... ;-)
This seems to work: BuildRequire: go < 1.13 BuildRequire: go >= 1.12
This does not: BuildRequire: go1.12
Nope: BuildRequire: go = 1.12 (as the available version is 1.12.9 or something like that)
This would be the correct cross-distro dependency: BuildRequires: (golang >= 1.12 with golang < 1.13) (The openSUSE specific variant would be just using "go" instead of "golang") This ensures that the dependency resolver looks for exactly one package that satisfies both terms. -- 真実はいつも一つ!/ Always, there's only one truth! -- To unsubscribe, e-mail: opensuse-packaging+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-packaging+owner@opensuse.org
Am 27.02.20 um 13:00 schrieb Neal Gompa:
This would be the correct cross-distro dependency:
BuildRequires: (golang >= 1.12 with golang < 1.13)
(The openSUSE specific variant would be just using "go" instead of "golang")
This ensures that the dependency resolver looks for exactly one package that satisfies both terms.
Thanks, Neal! Johannes -- Johannes Kastl Linux Consultant & Trainer Tel.: +49 (0) 151 2372 5802 Mail: kastl@b1-systems.de B1 Systems GmbH Osterfeldstraße 7 / 85088 Vohburg http://www.b1-systems.de GF: Ralph Dehner Unternehmenssitz: Vohburg / AG: Ingolstadt,HRB 3537
On 27.02.20 at 08:05 Johannes Kastl wrote:
Good morning ladies and gentlemen,
is there any documentation on how to exactly require a specific version of go1.X (use go1.10, not any later version? Use go1.12 or later?)?
Hmm, something is fishy. Why does Tumbleweed install go1.14 but keeps using go1.12? https://build.opensuse.org/project/monitor/home:ojkastl_buildservice:Branch_... spec contains this line: BuildRequires: (go >= 1.14 with go < 1.15) buildlog for openSUSE Tumbleweed: ######
[ 1s] Building git-lfs for project 'home:ojkastl_buildservice:Branch_git-lfs' repository 'openSUSE_Tumbleweed' arch 'x86_64' srcmd5 '9a07baba2f28c7b5b116610dfb35af98' ... [ 14s] [162/171] cumulate go1.14-1.14-4.1 ... [ 60s] go1.14-1.14-4.1 ######################################## [ 60s] update-alternatives: using /usr/lib64/go/1.14/bin/go to provide /usr/bin/go (go) in auto mode ... [ 73s] Copying deps to /home/abuild/rpmbuild/BUILD/contrib [ 73s] ++ get_gocontrib_path [ 73s] +++ rpm --eval '%{_datadir}' [ 73s] +++ rpm --eval %go_api_ver [ 73s] ++ echo /usr/share/go/1.12/contrib [ 73s] ++ get_buildcontrib_path [ 73s] ++ echo /home/abuild/rpmbuild/BUILD/contrib [ 73s] + cp -rT /usr/share/go/1.12/contrib/src /home/abuild/rpmbuild/BUILD/contrib/src [ 73s] cp: cannot stat '/usr/share/go/1.12/contrib/src': No such file or directory [ 73s] error: Bad exit status from /var/tmp/rpm-tmp.Pf7TbL (%build) ######
openSUSE Leap 15.1 correctly uses go1.14 (but fails later due to missing dependencies, but that is another topic). ######
[ 0s] Building git-lfs for project 'home:ojkastl_buildservice:Branch_git-lfs' repository 'openSUSE_Leap_15.1' arch 'x86_64' srcmd5 '9a07baba2f28c7b5b116610dfb35af98' ... [ 11s] [140/154] cumulate go1.14-1.14-lp151.4.1 ... [ 45s] go1.14-1.14-lp151.4.1 ######################################## [ 46s] update-alternatives: using /usr/lib64/go/1.14/bin/go to provide /usr/bin/go (go) in auto mode ... [ 61s] Copying deps to /home/abuild/rpmbuild/BUILD/contrib [ 61s] ++ get_gocontrib_path [ 61s] +++ rpm --eval '%{_datadir}' [ 61s] +++ rpm --eval %go_api_ver [ 61s] ++ echo /usr/share/go/1.14/contrib ...######
-- Johannes Kastl Linux Consultant & Trainer Tel.: +49 (0) 151 2372 5802 Mail: kastl@b1-systems.de B1 Systems GmbH Osterfeldstraße 7 / 85088 Vohburg http://www.b1-systems.de GF: Ralph Dehner Unternehmenssitz: Vohburg / AG: Ingolstadt,HRB 3537
On 10.03.20 at 08:49 Johannes Kastl wrote:
Hmm, something is fishy. Why does Tumbleweed install go1.14 but keeps using go1.12?
spec contains this line: BuildRequires: (go >= 1.14 with go < 1.15)
Hmm, apparently this does not work as intended. Martin fixed the package by using "BuildRequires: go1.14" (which I had already tried, but which did not work). Now it seems to correctly use go1.14:
[ 67s] + GO_CONTRIBSRCDIR=/usr/share/go/1.14/contrib/src/
Strange... Johannes -- Johannes Kastl Linux Consultant & Trainer Tel.: +49 (0) 151 2372 5802 Mail: kastl@b1-systems.de B1 Systems GmbH Osterfeldstraße 7 / 85088 Vohburg http://www.b1-systems.de GF: Ralph Dehner Unternehmenssitz: Vohburg / AG: Ingolstadt,HRB 3537
On 27.02.20 at 08:05 Johannes Kastl wrote:
Good morning ladies and gentlemen,
is there any documentation on how to exactly require a specific version of go1.X (use go1.10, not any later version? Use go1.12 or later?)?
On Leap 15.2 something is strange, as can be seen here: https://build.opensuse.org/package/show/home:donvipre:influxdb/influxdb (I cannot reproduce this due to all packages being "blocked" at the moment") ####
[ 18s] [127/142] cumulate go1.11-1.11.5-lp152.2.48 ... [ 18s] [131/142] cumulate go-1.12-lp152.1.2 ... [ 98s] go1.11-1.11.5-lp152.2.48 ######################################## [ 99s] update-alternatives: using /usr/lib64/go/1.11/bin/go to provide /usr/bin/go (go) in auto mode ... [ 105s] go-1.12-lp152.1.2 ######################################## ... [ 143s] Copying deps to /home/abuild/rpmbuild/BUILD/contrib [ 143s] ++ get_gocontrib_path [ 143s] +++ rpm --eval '%{_datadir}' [ 143s] +++ rpm --eval %go_api_ver [ 143s] ++ echo /usr/share/go/1.11/contrib
#### Why is go1.12 installed but not being used as alternative for /usr/bin/go? What is this strange go1.11 package and how to get rid of it? I know Leap 15.2 is not yet released, but wanted to mention this in case this needs fixing... Kind Regards, Johannes -- Johannes Kastl Linux Consultant & Trainer Tel.: +49 (0) 151 2372 5802 Mail: kastl@b1-systems.de B1 Systems GmbH Osterfeldstraße 7 / 85088 Vohburg http://www.b1-systems.de GF: Ralph Dehner Unternehmenssitz: Vohburg / AG: Ingolstadt,HRB 3537
Looping in Jeff Kowalczyk, our go maintainer. On Tue, 2020-03-10 at 09:07 +0100, Johannes Kastl wrote:
On 27.02.20 at 08:05 Johannes Kastl wrote:
Good morning ladies and gentlemen,
is there any documentation on how to exactly require a specific version of go1.X (use go1.10, not any later version? Use go1.12 or later?)?
On Leap 15.2 something is strange, as can be seen here: https://build.opensuse.org/package/show/home:donvipre:influxdb/influxdb
(I cannot reproduce this due to all packages being "blocked" at the moment")
####
[ 18s] [127/142] cumulate go1.11-1.11.5-lp152.2.48 ... [ 18s] [131/142] cumulate go-1.12-lp152.1.2 ... [ 98s] go1.11-1.11.5- lp152.2.48 ######################################## [ 99s] update-alternatives: using /usr/lib64/go/1.11/bin/go to provide /usr/bin/go (go) in auto mode ... [ 105s] go-1.12- lp152.1.2 ##################################### ### ... [ 143s] Copying deps to /home/abuild/rpmbuild/BUILD/contrib [ 143s] ++ get_gocontrib_path [ 143s] +++ rpm --eval '%{_datadir}' [ 143s] +++ rpm --eval %go_api_ver [ 143s] ++ echo /usr/share/go/1.11/contrib
####
Why is go1.12 installed but not being used as alternative for /usr/bin/go? What is this strange go1.11 package and how to get rid of it?
I know Leap 15.2 is not yet released, but wanted to mention this in case this needs fixing...
Kind Regards, Johannes
-- Best regards Luboš Kocman Release Manager openSUSE Leap SUSE Software Solutions Germany GmbH Maxfeldstr. 5 90409 Nuremberg Germany (HRB 36809, AG Nürnberg) Managing Director: Felix Imendörffer
I say it again. Use BuildRequires: config(go1.11) This runs well in Leap and Tumbleweed. Regards Eric Am 31. März 2020 10:15:13 MESZ schrieb Lubos Kocman <lubos.kocman@suse.com>:
Looping in Jeff Kowalczyk, our go maintainer.
On Tue, 2020-03-10 at 09:07 +0100, Johannes Kastl wrote:
On 27.02.20 at 08:05 Johannes Kastl wrote:
Good morning ladies and gentlemen,
is there any documentation on how to exactly require a specific version of go1.X (use go1.10, not any later version? Use go1.12 or later?)?
On Leap 15.2 something is strange, as can be seen here:
https://build.opensuse.org/package/show/home:donvipre:influxdb/influxdb
(I cannot reproduce this due to all packages being "blocked" at the moment")
####
[ 18s] [127/142] cumulate go1.11-1.11.5-lp152.2.48 ... [ 18s] [131/142] cumulate go-1.12-lp152.1.2 ... [ 98s] go1.11-1.11.5- lp152.2.48 ######################################## [ 99s] update-alternatives: using /usr/lib64/go/1.11/bin/go to provide /usr/bin/go (go) in auto mode ... [ 105s] go-1.12- lp152.1.2 ##################################### ### ... [ 143s] Copying deps to /home/abuild/rpmbuild/BUILD/contrib [ 143s] ++ get_gocontrib_path [ 143s] +++ rpm --eval '%{_datadir}' [ 143s] +++ rpm --eval %go_api_ver [ 143s] ++ echo /usr/share/go/1.11/contrib
####
Why is go1.12 installed but not being used as alternative for /usr/bin/go? What is this strange go1.11 package and how to get rid of it?
I know Leap 15.2 is not yet released, but wanted to mention this in case this needs fixing...
Kind Regards, Johannes
-- To unsubscribe, e-mail: opensuse-packaging+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-packaging+owner@opensuse.org
participants (6)
-
Axel Braun
-
Eric Schirra
-
Fridrich Strba
-
Johannes Kastl
-
Lubos Kocman
-
Neal Gompa