{"action":"created","issue":{"url":"https://api.github.com/repos/Boomaga/boomaga/issues/27","labels_url":"https://api.github.com/repos/Boomaga/boomaga/issues/27/labels{/name}","comments_url":"https://api.github.com/repos/Boomaga/boomaga/issues/27/comments","events_url":"https://api.github.com/repos/Boomaga/boomaga/issues/27/events","html_url":"https://github.com/Boomaga/boomaga/issues/27","id":91808259,"number":27,"title":"SPEC file for building RPM x86_64","user":{"login":"XOlegator","id":2227351,"avatar_url":"https://avatars.githubusercontent.com/u/2227351?v=3","gravatar_id":"","url":"https://api.github.com/users/XOlegator","html_url":"https://github.com/XOlegator","followers_url":"https://api.github.com/users/XOlegator/followers","following_url":"https://api.github.com/users/XOlegator/following{/other_user}","gists_url":"https://api.github.com/users/XOlegator/gists{/gist_id}","starred_url":"https://api.github.com/users/XOlegator/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/XOlegator/subscriptions","organizations_url":"https://api.github.com/users/XOlegator/orgs","repos_url":"https://api.github.com/users/XOlegator/repos","events_url":"https://api.github.com/users/XOlegator/events{/privacy}","received_events_url":"https://api.github.com/users/XOlegator/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":7,"created_at":"2015-06-29T13:52:18Z","updated_at":"2015-07-19T12:19:18Z","closed_at":null,"body":"I try to do valid RPM package for Fedora x86_64. There is worked example of SPEC file (but not valid according to the guidelines):\r\n```bash\r\nName:           boomaga\r\nVersion:        0.7.0\r\nRelease:        1%{?dist}\r\nSummary:        Boomaga is a virtual printer for viewing a document before printing\r\n\r\nLicense:        GPLv2 and LGPLv2+\r\nURL:            http://boomaga.github.io\r\nSource0:        %{name}-%{version}.tar.gz\r\n\r\nBuildRequires:  cmake,cups-devel,poppler-devel,poppler-cpp-devel,qt5-qtbase-devel,qt5-qttools-devel,snappy-devel\r\nRequires:       cups\r\n\r\n%description\r\nBoomaga (BOOklet MAnager) is a virtual printer for viewing a document before printing it out using the\r\nphysical printer.\r\nThe program is very simple to work with. Running any program, click “print” and select “Boomaga” to\r\nsee in several seconds (CUPS takes some time to respond) the Boomaga window open.\r\nIf you print out one more document, it gets added to the previous one, and you can also print them out as one.\r\n\r\n\r\n%prep\r\n%setup -q\r\n\r\n\r\n%build\r\nmkdir build\r\ncd build\r\ncmake ..\r\n\r\n\r\n%make_install\r\n\r\n\r\n%files\r\n%defattr(0755,root,root,-)\r\n/usr/lib/cups/backend/boomaga\r\n/usr/lib/cups/filter/boomaga_pstopdf\r\n/usr/local/bin/boomaga\r\n/usr/local/lib/boomaga/boomagabackend\r\n/usr/local/lib/boomaga/boomagamerger\r\n/usr/local/share/applications/boomaga.desktop\r\n/usr/local/share/boomaga/translations/boomaga_cs.qm\r\n/usr/local/share/boomaga/translations/boomaga_de.qm\r\n/usr/local/share/boomaga/translations/boomaga_el.qm\r\n/usr/local/share/boomaga/translations/boomaga_fr.qm\r\n/usr/local/share/boomaga/translations/boomaga_it.qm\r\n/usr/local/share/boomaga/translations/boomaga_lt.qm\r\n/usr/local/share/boomaga/translations/boomaga_pl_PL.qm\r\n/usr/local/share/boomaga/translations/boomaga_ru.qm\r\n/usr/local/share/boomaga/translations/boomaga_uz@Latn.qm\r\n/usr/local/share/dbus-1/services/org.boomaga.service\r\n/usr/local/share/icons/hicolor/128x128/apps/boomaga.png\r\n/usr/local/share/icons/hicolor/16x16/apps/boomaga.png\r\n/usr/local/share/icons/hicolor/32x32/apps/boomaga.png\r\n/usr/local/share/icons/hicolor/64x64/apps/boomaga.png\r\n/usr/local/share/mime/packages/boomaga.xml\r\n/usr/share/ppd/boomaga/boomaga.ppd\r\n%attr(0644,root,root)\r\n%doc\r\n/usr/local/share/man/man1/boomaga.1.gz\r\n\r\n\r\n%changelog\r\n* Mon Jun 22 2015 Oleg\r\n- \r\n```\r\nThe guidelines (https://fedoraproject.org/wiki/How_to_create_an_RPM_package) said: \"_You should follow the Filesystem Hierarchy Standard (FHS). Executables go in /usr/bin, global configuration files go in /etc, libraries go into /usr/lib (or /usr/lib64) and so on. **Do not install files into /opt or /usr/local.**_\"\r\nThere is valid according to the guidelines - https://fedoraproject.org/wiki/Packaging:Cmake - SPEC file (but it doesn't work for x86_64. See %files section):\r\n```bash\r\nName:           boomaga\r\nVersion:        0.7.0\r\nRelease:        1%{?dist}\r\nSummary:        Boomaga is a virtual printer for viewing a document before printing\r\n\r\nLicense:        GPLv2 and LGPLv2+\r\nURL:            http://boomaga.github.io\r\nSource0:        %{name}-%{version}.tar.gz\r\n\r\nBuildRequires:  cmake,cups-devel,poppler-devel,poppler-cpp-devel,qt5-qtbase-devel,qt5-qttools-devel,snappy-devel\r\nRequires:       cups\r\n\r\n%description\r\nBoomaga (BOOklet MAnager) is a virtual printer for viewing a document\r\nbefore printing it out using the physical printer.\r\nThe program is very simple to work with.\r\nRunning any program, click “print” and select “Boomaga” to see in several\r\nseconds (CUPS takes some time to respond) the Boomaga window open.\r\nIf you print out one more document,\r\nit gets added to the previous one, and you can also print them out as one.\r\n\r\n\r\n%prep\r\n%setup -q\r\n\r\n\r\n%build\r\n%cmake .\r\nmake %{?_smp_mflags}\r\n\r\n%install\r\nmake install DESTDIR=%{buildroot}\r\n\r\n\r\n%files\r\n%defattr(755,root,root,-)\r\n%{_libdir}/cups/backend/boomaga\r\n%defattr(-,root,root,-)\r\n%{_libdir}/cups/filter/boomaga_pstopdf\r\n%{_bindir}/boomaga\r\n%{_libdir}/boomaga/boomagabackend\r\n%{_libdir}/boomaga/boomagamerger\r\n%{_datadir}/applications/boomaga.desktop\r\n%{_datadir}/boomaga/translations/*\r\n%{_datadir}/dbus-1/services/org.boomaga.service\r\n%{_datadir}/icons/hicolor/*\r\n%{_datadir}/mime/packages/boomaga.xml\r\n%{_datadir}/ppd/boomaga/boomaga.ppd\r\n\r\n%doc COPYING GPL LGPL README.md\r\n%{_mandir}/man1/boomaga.1.gz\r\n\r\n\r\n%changelog\r\n* Mon Jun 22 2015 Oleg Ekhlakov <subspam@mail.ru> 0.7.0-1.fc21.R\r\n- Initial version of the package\r\n```\r\nIt is aborted with an error:\r\n> error: File not found: /home/oleg/rpmbuild/BUILDROOT/boomaga-0.7.0-1.fc21.R.x86_64/usr/lib64/cups/backend/boomaga\r\n> error: File not found: /home/oleg/rpmbuild/BUILDROOT/boomaga-0.7.0-1.fc21.R.x86_64/usr/lib64/cups/filter/boomaga_pstopdf\r\n> error: File not found: /home/oleg/rpmbuild/BUILDROOT/boomaga-0.7.0-1.fc21.R.x86_64/usr/lib64/boomaga/boomagabackend\r\n> error: File not found: /home/oleg/rpmbuild/BUILDROOT/boomaga-0.7.0-1.fc21.R.x86_64/usr/lib64/boomaga/boomagamerger\r\n\r\nAs far as I understood, %{_libdir} should be /usr/lib for x32 only and %{_libdir} should be /usr/lib64 for x86_64 only. The guidelines said: \"*Unfortunately, many programs do not follow the FHS by default. In particular, architecture-independent libraries get placed in /usr/lib instead of /usr/share. The former is for architecture-dependent libraries, while the latter is for architecture-independent libraries, which means that systems with different CPU architectures can share /usr/share. There are many exceptions in Fedora (such as Python and Perl), but Fedora applies this rule more strictly than some distributions. rpmlint will generally complain if you put anything other than ELF files into /usr/lib.*\" **It seems that in the project need to change the location of the files (for the x86_64 architecture), but I don't know how to do it correctly**:\r\n/usr/lib/cups/backend/boomaga -> /usr/lib64/cups/backend/boomaga\r\n/usr/lib/cups/filter/boomaga_pstopdf -> /usr/lib64/cups/filter/boomaga_pstopdf\r\n/usr/lib/boomaga/boomagabackend -> /usr/lib64/boomaga/boomagabackend\r\n/usr/lib/boomaga/boomagamerger -> /usr/lib64/boomaga/boomagamerger"},"comment":{"url":"https://api.github.com/repos/Boomaga/boomaga/issues/comments/122655245","html_url":"https://github.com/Boomaga/boomaga/issues/27#issuecomment-122655245","issue_url":"https://api.github.com/repos/Boomaga/boomaga/issues/27","id":122655245,"user":{"login":"SokoloffA","id":854935,"avatar_url":"https://avatars.githubusercontent.com/u/854935?v=3","gravatar_id":"","url":"https://api.github.com/users/SokoloffA","html_url":"https://github.com/SokoloffA","followers_url":"https://api.github.com/users/SokoloffA/followers","following_url":"https://api.github.com/users/SokoloffA/following{/other_user}","gists_url":"https://api.github.com/users/SokoloffA/gists{/gist_id}","starred_url":"https://api.github.com/users/SokoloffA/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SokoloffA/subscriptions","organizations_url":"https://api.github.com/users/SokoloffA/orgs","repos_url":"https://api.github.com/users/SokoloffA/repos","events_url":"https://api.github.com/users/SokoloffA/events{/privacy}","received_events_url":"https://api.github.com/users/SokoloffA/received_events","type":"User","site_admin":false},"created_at":"2015-07-19T12:19:18Z","updated_at":"2015-07-19T12:19:18Z","body":"Hi all!\r\nI'm not a guru in RPM-specs, in 2013 I wrote [spec for ROSA-linux](https://abf.rosalinux.ru/sokoloff/Boomaga/blob/master/boomaga.spec), and guys from rosa team was made some changes.  Let's write one universal RPM-spec."}}