Spec URL: https://github.com/FZUG/repo/blob/master/rpms/deepin_project/deepin-go-lib.spec SRPM URL: https://copr-be.cloud.fedoraproject.org/results/mosquito/deepin/fedora-25-x86_64/00501565-deepin-go-lib/deepin-go-lib-0.5.3-1.git44767e8.fc25.src.rpm Koji: https://koji.fedoraproject.org/koji/taskinfo?taskID=17613760 Description: Go bindings for Deepin Desktop Environment development Fedora Account System Username: mosquito
> Name: deepin-%{repo} I assume the package should be named golang-deepin-lib according to our Go packaging draft. You should also define the import path like: %global import_path pkg.deepin.io/lib Others looks good at the moment. Package Review ============== Legend: [x] = Pass, [!] = Fail, [-] = Not applicable, [?] = Not evaluated Issues: ======= - Header files in -devel subpackage, if present. Note: deepin-go-lib : /usr/share/gocode/src/pkg.deepin.io/lib/gdkpixbuf/blur.h deepin-go-lib : /usr/share/gocode/src/pkg.deepin.io/lib/gdkpixbuf/gaussianiir2d.h deepin- go-lib : /usr/share/gocode/src/pkg.deepin.io/lib/gdkpixbuf/gdk_pixbuf_utils.h deepin-go-lib : /usr/share/gocode/src/pkg.deepin.io/lib/pulse/dde-pulse.h deepin-go-lib : /usr/share/gocode/src/pkg.deepin.io/lib/sound/player.h See: http://fedoraproject.org/wiki/Packaging/Guidelines#DevelPackages - Package installs a %{name}.desktop using desktop-file-install or desktop- file-validate if there is such a file. ===== MUST items ===== Generic: [ ]: Package is licensed with an open-source compatible license and meets other legal requirements as defined in the legal section of Packaging Guidelines. [ ]: License field in the package spec file matches the actual license. Note: Checking patched sources after %prep for licenses. Licenses found: "BSD (2 clause)", "GPL (v3 or later)", "Unknown or generated", "*No copyright* GPL". 127 files have unknown license. Detailed output of licensecheck in /home/felix/projects/fedora/fedora-staging/deepin- go-lib/review-deepin-go-lib/licensecheck.txt [ ]: Package requires other packages for directories it uses. Note: No known owner of /usr/share/gocode/src/pkg.deepin.io [ ]: Package must own all directories that it creates. Note: Directories without known owners: /usr/share/gocode/src, /usr/share/gocode/src/pkg.deepin.io, /usr/share/gocode [ ]: Package contains no bundled libraries without FPC exception. [ ]: Changelog in prescribed format. [ ]: Sources contain only permissible code or content. [ ]: Each %files section contains %defattr if rpm < 4.4 Note: %defattr present but not needed [ ]: Development files must be in a -devel package [ ]: Package uses nothing in %doc for runtime. [ ]: Package consistently uses macros (instead of hard-coded directory names). [ ]: Package is named according to the Package Naming Guidelines. [ ]: Package does not generate any conflict. [ ]: Package obeys FHS, except libexecdir and /usr/target. [ ]: If the package is a rename of another package, proper Obsoletes and Provides are present. [ ]: Requires correct, justified where necessary. [ ]: Spec file is legible and written in American English. [ ]: Package contains systemd file(s) if in need. [ ]: Package is not known to require an ExcludeArch tag. [ ]: Large documentation must go in a -doc subpackage. Large could be size (~1MB) or number of files. Note: Documentation size is 10240 bytes in 1 files. [ ]: Package complies to the Packaging Guidelines [x]: Package successfully compiles and builds into binary rpms on at least one supported primary architecture. [x]: Package installs properly. [x]: Rpmlint is run on all rpms the build produces. Note: There are rpmlint messages (see attachment). [x]: If (and only if) the source package includes the text of the license(s) in its own file, then that file, containing the text of the license(s) for the package is included in %license. [x]: Package does not own files or directories owned by other packages. [x]: All build dependencies are listed in BuildRequires, except for any that are listed in the exceptions section of Packaging Guidelines. [x]: Package uses either %{buildroot} or $RPM_BUILD_ROOT [x]: Package does not run rm -rf %{buildroot} (or $RPM_BUILD_ROOT) at the beginning of %install. [x]: Macros in Summary, %description expandable at SRPM build time. [x]: Package contains desktop file if it is a GUI application. [x]: Dist tag is present. [x]: Package does not contain duplicates in %files. [x]: Permissions on files are set properly. [x]: Package use %makeinstall only when make install DESTDIR=... doesn't work. [x]: Package is named using only allowed ASCII characters. [x]: Package does not use a name that already exists. [x]: Package is not relocatable. [x]: Sources used to build the package match the upstream source, as provided in the spec URL. [x]: Spec file name must match the spec package %{name}, in the format %{name}.spec. [x]: File names are valid UTF-8. [x]: Packages must not store files under /srv, /opt or /usr/local ===== SHOULD items ===== Generic: [ ]: If the source package does not include license text(s) as a separate file from upstream, the packager SHOULD query upstream to include it. [ ]: Final provides and requires are sane (see attachments). [ ]: Package functions as described. [ ]: Latest version is packaged. [ ]: Package does not include license text files separate from upstream. [ ]: Description and summary sections in the package spec file contains translations for supported Non-English languages, if available. [ ]: Package should compile and build into binary rpms on all supported architectures. [ ]: %check is present and all tests pass. [ ]: Packages should try to preserve timestamps of original installed files. [x]: Reviewer should test that the package builds in mock. [x]: Buildroot is not present [x]: Package has no %clean section with rm -rf %{buildroot} (or $RPM_BUILD_ROOT) [x]: No file requires outside of /etc, /bin, /sbin, /usr/bin, /usr/sbin. [x]: Packager, Vendor, PreReq, Copyright tags should not be in spec file [x]: Sources can be downloaded from URI in Source: tag [x]: SourceX is a working URL. [x]: Spec use %global instead of %define unless justified. ===== EXTRA items ===== Generic: [x]: Rpmlint is run on all installed packages. Note: There are rpmlint messages (see attachment). [x]: Spec file according to URL is the same as in SRPM. Rpmlint ------- Checking: deepin-go-lib-1.0.3-1.gitb084e27.fc27.noarch.rpm deepin-go-lib-1.0.3-1.gitb084e27.fc27.src.rpm deepin-go-lib.noarch: W: spelling-error %description -l en_US DLib -> D Lib, Lib, Glib deepin-go-lib.noarch: W: spelling-error %description -l en_US guelfey -> Guernsey deepin-go-lib.noarch: W: devel-file-in-non-devel-package /usr/share/gocode/src/pkg.deepin.io/lib/gdkpixbuf/blur.c deepin-go-lib.noarch: W: devel-file-in-non-devel-package /usr/share/gocode/src/pkg.deepin.io/lib/gdkpixbuf/blur.h deepin-go-lib.noarch: W: devel-file-in-non-devel-package /usr/share/gocode/src/pkg.deepin.io/lib/gdkpixbuf/gaussianiir2d.c deepin-go-lib.noarch: W: devel-file-in-non-devel-package /usr/share/gocode/src/pkg.deepin.io/lib/gdkpixbuf/gaussianiir2d.h deepin-go-lib.noarch: W: devel-file-in-non-devel-package /usr/share/gocode/src/pkg.deepin.io/lib/gdkpixbuf/gdk_pixbuf_utils.c deepin-go-lib.noarch: W: devel-file-in-non-devel-package /usr/share/gocode/src/pkg.deepin.io/lib/gdkpixbuf/gdk_pixbuf_utils.h deepin-go-lib.noarch: E: zero-length /usr/share/gocode/src/pkg.deepin.io/lib/log/testdata/dde_debug deepin-go-lib.noarch: E: zero-length /usr/share/gocode/src/pkg.deepin.io/lib/log/testdata/stdout deepin-go-lib.noarch: W: devel-file-in-non-devel-package /usr/share/gocode/src/pkg.deepin.io/lib/pulse/dde-pulse.c deepin-go-lib.noarch: W: devel-file-in-non-devel-package /usr/share/gocode/src/pkg.deepin.io/lib/pulse/dde-pulse.h deepin-go-lib.noarch: W: devel-file-in-non-devel-package /usr/share/gocode/src/pkg.deepin.io/lib/pulse/meter.c deepin-go-lib.noarch: W: devel-file-in-non-devel-package /usr/share/gocode/src/pkg.deepin.io/lib/sound/player.c deepin-go-lib.noarch: W: devel-file-in-non-devel-package /usr/share/gocode/src/pkg.deepin.io/lib/sound/player.h deepin-go-lib.noarch: W: file-not-in-%lang /usr/share/gocode/src/pkg.deepin.io/lib/gettext/testdata/locale/ar/LC_MESSAGES/test.mo deepin-go-lib.noarch: W: file-not-in-%lang /usr/share/gocode/src/pkg.deepin.io/lib/gettext/testdata/locale/zh_CN/LC_MESSAGES/test.mo deepin-go-lib.noarch: W: file-not-in-%lang /usr/share/gocode/src/pkg.deepin.io/lib/gettext/testdata/plural/locale/es/LC_MESSAGES/test.mo deepin-go-lib.noarch: W: file-not-in-%lang /usr/share/gocode/src/pkg.deepin.io/lib/gettext/testdata/plural/locale/zh_CN/LC_MESSAGES/test.mo deepin-go-lib.src: W: spelling-error %description -l en_US DLib -> D Lib, Lib, Glib deepin-go-lib.src: W: spelling-error %description -l en_US dbus -> dubs, bus, buds deepin-go-lib.src: W: spelling-error %description -l en_US guelfey -> Guernsey deepin-go-lib.src: W: spelling-error %description -l en_US gdkpixbuf 2 packages and 0 specfiles checked; 2 errors, 21 warnings. Rpmlint (installed packages) ---------------------------- sh: /usr/bin/python: No such file or directory deepin-go-lib.noarch: W: spelling-error %description -l en_US DLib -> D Lib, Lib, Glib deepin-go-lib.noarch: W: spelling-error %description -l en_US guelfey -> Guernsey deepin-go-lib.noarch: W: devel-file-in-non-devel-package /usr/share/gocode/src/pkg.deepin.io/lib/gdkpixbuf/blur.c deepin-go-lib.noarch: W: devel-file-in-non-devel-package /usr/share/gocode/src/pkg.deepin.io/lib/gdkpixbuf/blur.h deepin-go-lib.noarch: W: devel-file-in-non-devel-package /usr/share/gocode/src/pkg.deepin.io/lib/gdkpixbuf/gaussianiir2d.c deepin-go-lib.noarch: W: devel-file-in-non-devel-package /usr/share/gocode/src/pkg.deepin.io/lib/gdkpixbuf/gaussianiir2d.h deepin-go-lib.noarch: W: devel-file-in-non-devel-package /usr/share/gocode/src/pkg.deepin.io/lib/gdkpixbuf/gdk_pixbuf_utils.c deepin-go-lib.noarch: W: devel-file-in-non-devel-package /usr/share/gocode/src/pkg.deepin.io/lib/gdkpixbuf/gdk_pixbuf_utils.h deepin-go-lib.noarch: E: zero-length /usr/share/gocode/src/pkg.deepin.io/lib/log/testdata/dde_debug deepin-go-lib.noarch: E: zero-length /usr/share/gocode/src/pkg.deepin.io/lib/log/testdata/stdout deepin-go-lib.noarch: W: devel-file-in-non-devel-package /usr/share/gocode/src/pkg.deepin.io/lib/pulse/dde-pulse.c deepin-go-lib.noarch: W: devel-file-in-non-devel-package /usr/share/gocode/src/pkg.deepin.io/lib/pulse/dde-pulse.h deepin-go-lib.noarch: W: devel-file-in-non-devel-package /usr/share/gocode/src/pkg.deepin.io/lib/pulse/meter.c deepin-go-lib.noarch: W: devel-file-in-non-devel-package /usr/share/gocode/src/pkg.deepin.io/lib/sound/player.c deepin-go-lib.noarch: W: devel-file-in-non-devel-package /usr/share/gocode/src/pkg.deepin.io/lib/sound/player.h deepin-go-lib.noarch: W: file-not-in-%lang /usr/share/gocode/src/pkg.deepin.io/lib/gettext/testdata/locale/ar/LC_MESSAGES/test.mo deepin-go-lib.noarch: W: file-not-in-%lang /usr/share/gocode/src/pkg.deepin.io/lib/gettext/testdata/locale/zh_CN/LC_MESSAGES/test.mo deepin-go-lib.noarch: W: file-not-in-%lang /usr/share/gocode/src/pkg.deepin.io/lib/gettext/testdata/plural/locale/es/LC_MESSAGES/test.mo deepin-go-lib.noarch: W: file-not-in-%lang /usr/share/gocode/src/pkg.deepin.io/lib/gettext/testdata/plural/locale/zh_CN/LC_MESSAGES/test.mo 1 packages and 0 specfiles checked; 2 errors, 17 warnings. Requires -------- deepin-go-lib (rpmlib, GLIBC filtered): /bin/bash /bin/sh Provides -------- deepin-go-lib: deepin-go-lib Source checksums ---------------- https://github.com/linuxdeepin/go-lib/archive/b084e27172bb28e68f44ea4cecddb25d7dcfdc49/go-lib-b084e27.tar.gz : CHECKSUM(SHA256) this package : c468b6a1b23b1a155849917ec4d2b97ba2cb45fff1a1660c9d4e11ce26e9824f CHECKSUM(SHA256) upstream package : c468b6a1b23b1a155849917ec4d2b97ba2cb45fff1a1660c9d4e11ce26e9824f Generated by fedora-review 0.6.1 (f03e4e7) last change: 2016-05-02 Command line :/usr/bin/fedora-review -n deepin-go-lib Buildroot used: fedora-rawhide-x86_64 Active plugins: Generic, Shell-api Disabled plugins: Java, C/C++, Python, fonts, SugarActivity, Ocaml, Perl, Haskell, R, PHP Disabled flags: EXARCH, DISTTAG, EPEL5, BATCH, EPEL6
Some comments from #1421041 apply: - "_" prefix in macro names is not necessary - update to latest version (1.0.5 seems to be released) > Group: Development/Libraries → please remove [https://fedoraproject.org/wiki/Packaging:Guidelines#Tags_and_Sections] > %defattr(-,root,root,-) Likewise. Link to the guidelines: https://fedoraproject.org/wiki/PackagingDrafts/Go (I think that's the right draft… Too bad this wasn't finalized.) Unfortunately I don't know anything about go, so I cannot offer an opinion on the go-specific packaging.
SPEC: https://copr-be.cloud.fedoraproject.org/results/mosquito/deepin/fedora-26-x86_64/00587260-golang-deepin-go-lib/deepin-go-lib.spec SRPM: https://copr-be.cloud.fedoraproject.org/results/mosquito/deepin/fedora-26-x86_64/00587260-golang-deepin-go-lib/golang-deepin-go-lib-1.0.5-2.fc26.src.rpm Rename package name to golang-deepin-go-lib, and require the golang-github-go-fsnotify-fsnotify instead of golang-github-howeyc-fsnotify package.
SPEC: https://copr-be.cloud.fedoraproject.org/results/mosquito/deepin/fedora-25-x86_64/00587925-golang-deepin-go-lib/deepin-go-lib.spec SRPM: https://copr-be.cloud.fedoraproject.org/results/mosquito/deepin/fedora-25-x86_64/00587925-golang-deepin-go-lib/golang-deepin-go-lib-1.0.5-2.fc25.src.rpm Back to use golang-github-howeyc-fsnotify package.
Hello, I think you should use the gofed script as your basis and not go too far away from this script. For example, your Provides should list all the libraries provided by the package: Provides: golang(%{import_path}) = %{version}-%{release} Provides: golang(%{import_path}/app) = %{version}-%{release} Provides: golang(%{import_path}/appinfo) = %{version}-%{release} Provides: golang(%{import_path}/appinfo/desktopappinfo) = %{version}-%{release} Provides: golang(%{import_path}/arch) = %{version}-%{release} Provides: golang(%{import_path}/archive) = %{version}-%{release} Provides: golang(%{import_path}/archive/gzip) = %{version}-%{release} Provides: golang(%{import_path}/archive/utils) = %{version}-% and so on. Otherwise golang packages using this library won't be able to find their dependencies. By the way, this is a problem you have on your other golang libraries you have on your COPR. If you intend to submit them, I recommend you to start with the basis of the gofed script and then fix whatever issue remains. Also you have no %check for this library. This is highly recommended. Don't forget to add the various testdata to your unit-test-devel.file-list. For example: # pack testdata for file in $(find */*testdata */*/testdata) ; do dirprefix=$(dirname $file) install -d -p %{buildroot}/%{gopath}/src/%{import_path}/$dirprefix cp -pav $file %{buildroot}/%{gopath}/src/%{import_path}/$file echo "%%{gopath}/src/%%{import_path}/$file" >> unit-test-devel.file-list done You'll some BR for the tests, there are specified in the README.md. Shortlist: # Required for tests BuildRequires: dbus-x11 BuildRequires: pkgconfig(gdk-pixbuf-xlib-2.0) BuildRequires: pkgconfig(libpulse) BuildRequires: pkgconfig(libcanberra) BuildRequires: mobile-broadband-provider-info If some checks fail and you don't know why, best is to report them upstream and deactivate them with the bugreport url in comment. This shouldn't be a noarch, you should use the ExclusiveArch for Go: ExclusiveArch: %{?go_arches:%{go_arches}}%{!?go_arches:%{ix86} x86_64 aarch64 %{arm}} And BR the right compiler: BuildRequires: %{?go_compiler:compiler(go-compiler)}%{!?go_compiler:golang}
Diff: https://github.com/FZUG/repo/commit/09b62a0da75d00b9a69b626f6632160a429d1d21 SPEC: https://raw.githubusercontent.com/FZUG/repo/09b62a0da75d00b9a69b626f6632160a429d1d21/rpms/deepin_project/deepin-go-lib.spec Hi Robert I have fixed some problems. If your think it would be ok. I will submit other golang packages for package review. Thanks a lot.
Hello, You should rename your spec golang-deepin-go-lib: it should be the same as the name of the package. Missing dependencies: DEBUG util.py:450: No matching package to install: 'deepin-gir-generator' → Bug #1421063 : accepted but not yet built DEBUG util.py:450: No matching package to install: 'golang(github.com/BurntSushi/xgbutil)' → Bug #1480972 : accepted but not yet built DEBUG util.py:450: No matching package to install: 'golang(gopkg.in/alecthomas/kingpin.v2)' → Bug #1480973: nobody's working on it yet
$ fedrepo-req golang-github-BurntSushi-xgbutil -t 1480972 Error: The Bugzilla ticket is not approved yet golang-github-BurntSushi-xgbutil is not approve. :)
I've got test failures, so I commented them. #%%gotest %%{import_path}/users/group #%%gotest %%{import_path}/users/passwd If you get them too, you should report them upstream. There's a new release 1.1.0: https://github.com/linuxdeepin/go-lib/releases Problem is, this new release dropped the dependency to golang-github-howeyc-fsnotify and deepin forked it locally. This release also dropped launchpad.net/gocheck and replaced it with gopkg.in/check.v1 You need to update the BR accordingly: - remove: BuildRequires: golang(github.com/howeyc/fsnotify) and Requires: golang(github.com/howeyc/fsnotify) - change BuildRequires: golang(launchpad.net/gocheck) to BuildRequires: golang(gopkg.in/check.v1)
Diff: https://github.com/FZUG/repo/commit/d8fb40d14bbdc08d96f0ad30a6fc07e17ab73d53 I build pass without failure. Package was updated to 1.1.0, but built not done in Copr. Please see https://copr.fedorainfracloud.org/coprs/mosquito/deepin/build/593683/
It's all good for me, package accepted.
(fedrepo-req-admin): The Pagure repository was created at https://src.fedoraproject.org/rpms/golang-deepin-go-lib
This is already in Rawhide. Closing on behalf of the Deepin Desktop packaging effort.