gofed / go-macros

Rpm mechanics for Go packaging
4 stars 7 forks source link

Error while running %gometa with the -i option #32

Open eclipseo opened 6 years ago

eclipseo commented 6 years ago

-i seems to cause issues when building the SRPM:

$ fedpkg --release f29 srpm                                                                                                                                        
sources file doesn't exist. Source files download skipped.
Failed to get module name from Git url or pushurl
Could not execute srpm: Could not get n-v-r-e from '\n\nForge-specific packaging variables\n\n  forgeurl:        https://github.com/bazil/fuse\n\n  forgesource:     https://github.com/bazil/fuse/archive/371fbbdaa8987b715bdd21d6adc4c9b20155f748/fuse-371fbbdaa8987b715bdd21d6adc4c9b20155f748.tar.gz\n\n  forgesetupargs:  -n fuse-371fbbdaa8987b715bdd21d6adc4c9b20155f748\n\nGeneric variables\n\n  archivename:     fuse-371fbbdaa8987b715bdd21d6adc4c9b20155f748\n\n  archiveext:      tar.gz\n\n  archiveurl:      https://github.com/bazil/fuse/archive/371fbbdaa8987b715bdd21d6adc4c9b20155f748/fuse-371fbbdaa8987b715bdd21d6adc4c9b20155f748.tar.gz\n\n  scm:             git\n\n  tag:             \n\n  commit:          371fbbdaa8987b715bdd21d6adc4c9b20155f748\n\n  dist:            .20180308git371fbbd.fc29 (snapshot date is computed once %{_sourcedir}/%{archivename}.%{archiveext} is available)\n\nGo-specific packaging variables\n  goipath:         bazil.org/fuse\n  goname:          golang-bazil-fuse\n  gourl:           https://github.com/bazil/fuse\n  gosource:        https://github.com/bazil/fuse/archive/371fbbdaa8987b715bdd21d6adc4c9b20155f748/fuse-371fbbdaa8987b715bdd21d6adc4c9b20155f748.tar.gz\ngolang-bazil-fuse (none) 0 0.3.20180308git371fbbd.fc29'
eclipseo commented 6 years ago

It works fine with rpmbuild, it must be a fedpkg issue then.

eclipseo commented 6 years ago

I found the bug, I conquer the bug, I create a PR:

https://pagure.io/rpkg/pull-request/295

ingvagabund commented 6 years ago

@eclipseo what version of fedpkg you have?

eclipseo commented 6 years ago

I have 1.31-5.fc27. But it's a bug in the rpkg library.

ingvagabund commented 6 years ago

@eclipseo is the error occurring only when the -i option is set? Or does it occur even without the option?

eclipseo commented 6 years ago

Only with -i. I decided to remove it from all my SPEC because it was also causing issue with fedpkg clog.

ingvagabund commented 6 years ago

It's causing rpmlint to go crazy as well. I am thinking of the same. I tested all the updated spec files on f24 so can't wait once I upgrade to f27+ :(.