Op zaterdag 05-09-2009 om 12:06 uur [tijdzone -0400], schreef Michael Ansel: > While working on a project for class, I needed to cross-compile a > program built with wxWidgets onto Windows. Since all I could find was > an RPM built for F10, I went ahead and updated the spec to build on > F11, and would really love to include it in the Fedora repos.
Hi, Welcome to the Fedora community! Thanks for your work on getting wxWidgets packaged. To get this package in Fedora you (or somebody else who is interested in maintaining it) should put it up for review at http://bugzilla.redhat.com Details about this review process can be found at https://fedoraproject.org/wiki/Package_Review_Process and https://fedoraproject.org/wiki/Join_the_package_collection_maintainers To comply with the Fedora packaging guidelines the .spec file needs some changes before it will be accepted for inclusion in Fedora. Here's a small list of things that need to be changed: > # Workaround for the problem of /usr/bin/strip not handling PE binaries. > %define __strip /usr/bin/i686-pc-mingw32-strip All Fedora-MinGW packages should start with this set of instructions: %global __strip %{_mingw32_strip} %global __objdump %{_mingw32_objdump} %global _use_internal_dependency_generator 0 %global __find_requires %{_mingw32_findrequires} %global __find_provides %{_mingw32_findprovides} > License: wxWidgets Library Licence The License tag should be just 'wxWidgets' as is done with the native Fedora package: http://cvs.fedoraproject.org/viewvc/rpms/wxGTK/devel/wxGTK.spec?revision=1.48&view=markup > Packager: Keiichi Takahashi <[email protected]> > Vendor: bitWalk Co., Ltd. The Packages and Vendor tags need to be removed > Buildroot: %{_tmppath}/%{name}-root This needs to be changed to '%(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX)' as can be seen at https://fedoraproject.org/wiki/Packaging/Guidelines#BuildRoot_tag > BuildPrereq: mingw32-runtime, mingw32-w32api, mingw32-binutils, > mingw32-expat, mingw32-gcc, mingw32-gcc-c++, mingw32-libjpeg, > mingw32-libpng, mingw32-libtiff, mingw32-zlib In Fedora, the BuildRequires tag is used instead of BuildPrereq. For readability it's also recommended to split the individual requirements across multiple lines. Several dependencies are unneeded as they're already pulled in by other packages. This list should be sufficient: BuildRequires: mingw32-gcc-c++ BuildRequires: mingw32-expat BuildRequires: mingw32-libjpeg BuildRequires: mingw32-libpng BuildRequires: mingw32-libtiff BuildRequires: mingw32-zlib > Requires: mingw32-runtime, mingw32-expat, mingw32-libjpeg, > mingw32-libpng, mingw32-libtiff, mingw32-zlib It isn't necessary to use the Requires for Fedora-MinGW packages as the requirements are automatically discovered by RPM during the build. > if [ "$SMP" != "" ]; then > %_mingw32_make -j$SMP > else > %_mingw32_make > fi It isn't necessary to use %_mingw32_make here. The regular 'make' should be sufficient. This block of code can be replaced by this single command: make %{?_smp_mflags} > %_mingw32_makeinstall -C obj-shared > %_mingw32_makeinstall -C obj-static The regular 'make install' can be used here instead of % _mingw32_makeinstall. Have you verified that no files installed by the first command will be overwritten while executing the second command? > %files > %defattr(-,root,root,-) > %{_mingw32_prefix} > #TODO Need to select all files EXCEPT for static libraries As the TODO says, the individual files and folders need to be listed here. See https://fedoraproject.org/wiki/Packaging/Guidelines#File_and_Directory_Ownership and https://fedoraproject.org/wiki/Packaging:UnownedDirectories for more information about this subject The issues I mentioned above are all relative small so they should be quite easy to fix. Regards, Erik van Pienbroek _______________________________________________ fedora-mingw mailing list [email protected] https://admin.fedoraproject.org/mailman/listinfo/fedora-mingw
