Bug 502554 (mingw32-boost) - Review Request: mingw32-boost - MinGW Windows Boost C++ library
Summary: Review Request: mingw32-boost - MinGW Windows Boost C++ library
Keywords:
Status: CLOSED NEXTRELEASE
Alias: mingw32-boost
Product: Fedora
Classification: Fedora
Component: Package Review
Version: rawhide
Hardware: All
OS: Linux
low
medium
Target Milestone: ---
Assignee: Erik van Pienbroek
QA Contact: Fedora Extras Quality Assurance
URL: http://sailer.fedorapeople.org/
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2009-05-26 06:39 UTC by Thomas Sailer
Modified: 2009-06-19 13:41 UTC (History)
5 users (show)

Fixed In Version: 1.37.0-4.fc11
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2009-06-19 13:41:41 UTC
erik-fedora: fedora-review+
tibbs: fedora-cvs+


Attachments (Terms of Use)

Description Thomas Sailer 2009-05-26 06:39:24 UTC
Spec URL: http://sailer.fedorapeople.org/mingw32-boost.spec
SRPM URL: http://sailer.fedorapeople.org/mingw32-boost-1.37.0-1.fc11.src.rpm
Description:
MinGW Windows Boost C++ library.

Approved MinGW packaging guidelines are here:
http://fedoraproject.org/wiki/Packaging/MinGW

Comment 1 Richard W.M. Jones 2009-05-26 08:26:55 UTC
Fixed Summary line.

Comment 2 Erik van Pienbroek 2009-05-26 09:05:48 UTC
The static subpackage contains some leftovers from libsoup:
 %description static
 Static version of the MinGW Windows Libsoup library.

The %defattr line should be:
 %defattr(-,root,root,-)

What's the dependency problem with the test framework library?

Comment 3 Thomas Sailer 2009-05-26 09:53:52 UTC
(In reply to comment #1)
> Fixed Summary line.  

Thanks!

(In reply to comment #2)
> What's the dependency problem with the test framework library?  

All of:
libboost_prg_exec_monitor.lib
libboost_prg_exec_monitor-mt.lib
libboost_test_exec_monitor.lib
libboost_test_exec_monitor-mt.lib
libboost_unit_test_framework.lib
libboost_unit_test_framework-mt.lib
link to external, undefined functions. While under unix, this is possible, under windows, DLL's do not allow undefined external references. Therefore, we can only provide static libraries for these.

Specifically, test_exec_monitor wants test_main(int, char**), prg_exec_monitor wants cpp_main(int, char**), and unit_test_framework wants init_unit_test_suite(int, char**).

> The static subpackage contains some leftovers from libsoup:
>  %description static
>  Static version of the MinGW Windows Libsoup library.
> 
> The %defattr line should be:
>  %defattr(-,root,root,-)

An update for these is in progress.

Comment 4 Thomas Sailer 2009-05-26 10:46:21 UTC
The promised update:
Spec URL: http://sailer.fedorapeople.org/mingw32-boost.spec
SRPM URL: http://sailer.fedorapeople.org/mingw32-boost-1.37.0-2.fc11.src.rpm

Comment 5 Erik van Pienbroek 2009-05-26 18:39:01 UTC
While trying to build this package using rpmbuild I noticed several occurences of lines like this:

gcc.archive bin.v2/libs/math/build/gcc-mingw-4.4.0/release/debug-symbols-on/link-static/target-os-windows/libboost_math_c99f.lib

    "/usr/bin/ar"  rc "bin.v2/libs/math/build/gcc-mingw-4.4.0/release/debug-symbols-on/link-static/target-os-windows/libboost_math_c99f.lib" "bin.v2/libs/math/build/gcc-mingw-4.4.0/release/debug-symbols-on/link-static/target-os-windows/acoshf.o" "bin.v2/libs/math/build/gcc-mingw-4.4.0/release/debug-symbols-on/link-static/target-os-windows/asinhf.o" "bin.v2/libs/math/build/gcc-mingw-4.4.0/release/debug-symbols-on/link-static/target-os-windows/atanhf.o" "bin.v2/libs/math/build/gcc-mingw-4.4.0/release/debug-symbols-on/link-static/target-os-windows/cbrtf.o" "bin.v2/libs/math/build/gcc-mingw-4.4.0/release/debug-symbols-on/link-static/target-os-windows/copysignf.o" "bin.v2/libs/math/build/gcc-mingw-4.4.0/release/debug-symbols-on/link-static/target-os-windows/erfcf.o" "bin.v2/libs/math/build/gcc-mingw-4.4.0/release/debug-symbols-on/link-static/target-os-windows/erff.o" "bin.v2/libs/math/build/gcc-mingw-4.4.0/release/debug-symbols-on/link-static/target-os-windows/expm1f.o" "bin.v2/libs/math/build/gcc-mingw-4.4.0/release/debug-symbols-on/link-static/target-os-windows/fmaxf.o" "bin.v2/libs/math/build/gcc-mingw-4.4.0/release/debug-symbols-on/link-static/target-os-windows/fminf.o" "bin.v2/libs/math/build/gcc-mingw-4.4.0/release/debug-symbols-on/link-static/target-os-windows/fpclassifyf.o" "bin.v2/libs/math/build/gcc-mingw-4.4.0/release/debug-symbols-on/link-static/target-os-windows/hypotf.o" "bin.v2/libs/math/build/gcc-mingw-4.4.0/release/debug-symbols-on/link-static/target-os-windows/lgammaf.o" "bin.v2/libs/math/build/gcc-mingw-4.4.0/release/debug-symbols-on/link-static/target-os-windows/llroundf.o" "bin.v2/libs/math/build/gcc-mingw-4.4.0/release/debug-symbols-on/link-static/target-os-windows/log1pf.o" "bin.v2/libs/math/build/gcc-mingw-4.4.0/release/debug-symbols-on/link-static/target-os-windows/lroundf.o" "bin.v2/libs/math/build/gcc-mingw-4.4.0/release/debug-symbols-on/link-static/target-os-windows/nextafterf.o" "bin.v2/libs/math/build/gcc-mingw-4.4.0/release/debug-symbols-on/link-static/target-os-windows/nexttowardf.o" "bin.v2/libs/math/build/gcc-mingw-4.4.0/release/debug-symbols-on/link-static/target-os-windows/roundf.o" "bin.v2/libs/math/build/gcc-mingw-4.4.0/release/debug-symbols-on/link-static/target-os-windows/tgammaf.o" "bin.v2/libs/math/build/gcc-mingw-4.4.0/release/debug-symbols-on/link-static/target-os-windows/truncf.o"

It looks like the native 'ar' is used (/usr/bin/ar) instead of i686-pc-mingw32-ar. This might need some further investigation.


Another issue I noticed in the .spec file is this:
 if a2dll libboost_thread-mt.lib libboost_thread-mt "-lpthreadGC2"; then
As of mingw32-pthreads-2.8.0-8{.fc11,.fc12} it isn't necessary to use '-lpthreadGC2' anymore. It should be sufficient to use just '-lpthread' here.


For the link errors in the testsuite libraries. I might have found out a way to get it operational as shared libraries. Would it be possible to add a main() function to those testsuite libraries which looks something like this:

int main(int argc, char **argv)
{
    void (*test_main_func) (int, char**);

    test_main_func = GetProcAddress(NULL, "test_main");
    if (!test_main_func) {
        printf("No test_main() function found\n");
        return -1;
    }

    test_main_func(arg1, arg2);

    return 0;
}

Comment 6 Richard W.M. Jones 2009-05-26 19:06:02 UTC
Is there any practical difference between native 'ar'
and i686-pc-mingw32-ar?  I thought it was just a generic
archive tool ...

Comment 7 Thomas Sailer 2009-05-27 11:36:25 UTC
(In reply to comment #5)

> It looks like the native 'ar' is used (/usr/bin/ar) instead of
> i686-pc-mingw32-ar. This might need some further investigation.

I thought too that ar was just a simple archiver. But I fixed this anyway.

> Another issue I noticed in the .spec file is this:
>  if a2dll libboost_thread-mt.lib libboost_thread-mt "-lpthreadGC2"; then
> As of mingw32-pthreads-2.8.0-8{.fc11,.fc12} it isn't necessary to use
> '-lpthreadGC2' anymore. It should be sufficient to use just '-lpthread' here.

I've seen you made the change too, but it seems it hasn't propagated yet to my mirror. Anyway, I would like to keep it that way for some time until your change has fully propagated...

> For the link errors in the testsuite libraries. I might have found out a way to
> get it operational as shared libraries. Would it be possible to add a main()
> function to those testsuite libraries which looks something like this:

Sure, if you write your own dynamic linker :)

Seriously though, this is quite a lot of work to implement, I won't have time to do this in the next couple of weeks. If someone else wants to give it a try, be my guest.

Comment 9 Thomas Sailer 2009-05-28 20:33:58 UTC
Further update. Now the package uses the boost build system to build the dynamic libraries as well. As a side effect, this fixes building DLLs for the above mentioned DLLs.

Spec URL: http://sailer.fedorapeople.org/mingw32-boost.spec
SRPM URL: http://sailer.fedorapeople.org/mingw32-boost-1.37.0-4.fc11.src.rpm

Comment 10 Thomas Sailer 2009-05-29 04:12:44 UTC
Scratch Build:
http://koji.fedoraproject.org/koji/taskinfo?taskID=1382220

Comment 11 Thomas Sailer 2009-05-29 13:57:51 UTC
I won't have time to work on this package for the next couple of weeks, if someone wants to take over, be my guest.

Comment 12 Erik van Pienbroek 2009-06-05 18:21:50 UTC
$ rpmlint mingw32-boost.spec 
mingw32-boost.spec:95: W: rpm-buildroot-usage %build #BUILD_FLAGS="--with-toolset=gcc --prefix=$RPM_BUILD_ROOT%{_prefix}"
mingw32-boost.spec:108: W: configure-without-libdir-spec
mingw32-boost.spec: W: patch-not-applied Patch7: boost-1_37_0-smp.patch
0 packages and 1 specfiles checked; 0 errors, 3 warnings.

The rpm-buildroot-usage is a false positive as that line is commented out
The configure-without-libdir-spec is also a false positive as boost uses a different build system
The patch-not-applied is also a false positive as the patch is applied by a custom command

$ rpmlint mingw32-boost-*.rpm
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_system.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_math_tr1l.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_system-mt.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_math_c99.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_date_time.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_math_tr1.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_test_exec_monitor-mt.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_math_c99f.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_wave-mt.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_regex-mt.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_regex.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_math_c99-mt.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_date_time-mt.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_signals-mt.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_wserialization.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_iostreams.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_prg_exec_monitor.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_thread-mt.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_filesystem-mt.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_serialization-mt.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_program_options.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_wave.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_math_tr1-mt.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_iostreams-mt.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_serialization.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_test_exec_monitor.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_program_options-mt.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_unit_test_framework.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_graph-mt.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_wserialization-mt.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_math_tr1f-mt.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_math_c99l-mt.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_signals.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_math_tr1l-mt.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_unit_test_framework-mt.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_math_tr1f.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_math_c99f-mt.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_prg_exec_monitor-mt.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_math_c99l.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_graph.a
mingw32-boost-static.noarch: E: arch-independent-package-contains-binary-or-object /usr/i686-pc-mingw32/sys-root/mingw/lib/libboost_filesystem.a
mingw32-boost-static.noarch: W: no-documentation
2 packages and 0 specfiles checked; 41 errors, 1 warnings.

These warnings are all false positives

$ md5sum boost_1_37_0.tar.bz2 
8d9f990bfb7e83769fa5f1d6f065bc92  boost_1_37_0.tar.bz2
$ curl http://ovh.dl.sourceforge.net/sourceforge/boost/boost_1_37_0.tar.bz2 --silent | md5sum
8d9f990bfb7e83769fa5f1d6f065bc92  -

+ OK
! Needs to be looked into
/ Not applicable
* Overridden by MinGW guidelines

[+] Files are installed in /usr/i686-pc-mingw32/sys-root/mingw
[+] BuildRequires: mingw32-filesystem >= xx is in the .spec file
[+] Requires are OK
[+] BuildArch: noarch
[+] No man pages or info files
[+] default strip and objdump commands are overridden with mingw32 specific ones


[+] rpmlint must be run on every package. The output should be posted in the review
[+] MUST: The package must be named according to the Package Naming Guidelines
[+] MUST: The spec file name must match the base package %{name}, in the format %{name}.spec unless your package has an exemption on Package Naming Guidelines
[+] MUST: The package must meet the Packaging Guidelines
[+] MUST: The package must be licensed with a Fedora approved license and meet the Licensing Guidelines .
[+] MUST: The License field in the package spec file must match the actual license.
[+] MUST: 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 must be included in %doc.
[+] MUST: The spec file must be written in American English.
[+] MUST: The spec file for the package MUST be legible.
[+] MUST: The sources used to build the package must match the upstream source, as provided in the spec URL.
[+] MUST: The package must successfully compile and build into binary rpms on at least one supported architecture.
[+] MUST: If the package does not successfully compile, build or work on an architecture, then those architectures should be listed in the spec in ExcludeArch.
[+] MUST: All build dependencies must be listed in BuildRequires, except for any that are listed in the exceptions section of the Packaging Guidelines; inclusion of those as B ildRequires is optional.
[/] MUST: The spec file MUST handle locales properly. This is done by using the %find_lang macro. Using %{_datadir}/locale/* is strictly forbidden.
[*] MUST: Every binary RPM package which stores shared library files (not just symlinks) in any of the dynamic linker's default paths, must call ldconfig in %post and %postun. 
[/] MUST: If the package is designed to be relocatable, the packager must state this fact in the request for review, along with the rationalization for relocation of that specific package.
[+] MUST: A package must own all directories that it creates. 
[+] MUST: A package must not contain any duplicate files in the %files listing.
[+] MUST: Permissions on files must be set properly.
[+] MUST: Each package must have a %clean section, which contains rm -rf %{buildroot} ( or $RPM_BUILD_ROOT ).
[+] MUST: Each package must consistently use macros, as described in the macros section of Packaging Guidelines .
[+] MUST: The package must contain code, or permissable content.
[/] MUST: Large documentation files should go in a -doc subpackage.
[/] MUST: If a package includes something as %doc, it must not affect the runtime of the application.
[*] MUST: Header files must be in a -devel package.
[+] MUST: Static libraries must be in a -static package.
[/] MUST: Packages containing pkgconfig(.pc) files must 'Requires: pkgconfig' (for directory ownership and usability).
[*] MUST: If a package contains library files with a suffix (e.g. libfoo.so.1.1), then library files that end in .so (without suffix) must go in a -devel package.
[*] MUST: In the vast majority of cases, devel packages must require the base package using a fully versioned dependency: Requires: %{name} = %{version}-%{release}
[*] MUST: Packages must NOT contain any .la libtool archives, these should be removed in the spec.
[/] MUST: Packages containing GUI applications must include a %{name}.desktop file, and that file must be properly installed with desktop-file-install in the %install section.
[+] MUST: Packages must not own files or directories already owned by other packages.
[+] MUST: At the beginning of %install, each package MUST run rm -rf %{buildroot} ( or $RPM_BUILD_ROOT ). See Prepping BuildRoot For %install for details.
[+] MUST: All filenames in rpm packages must be valid UTF-8.
[/] SHOULD: If the source package does not include license text(s) as a separate file from upstream, the packager SHOULD query upstream to include it.
[/] SHOULD: The description and summary sections in the package spec file should contain translations for supported Non-English languages, if available.
[+] SHOULD: The reviewer should test that the package builds in mock. See MockTricks for details on how to do this.
[+] SHOULD: The package should compile and build into binary rpms on all supported architectures.
[/] SHOULD: The reviewer should test that the package functions as described. A package should not segfault instead of running, for example.
[/] SHOULD: If scriptlets are used, those scriptlets must be sane. This is vague, and left up to the reviewers judgement to determine sanity.
[+] SHOULD: Usually, subpackages other than devel should require the base package using a fully versioned dependency.
[/] SHOULD: The placement of pkgconfig(.pc) files depends on their usecase, and this is usually for development purposes, so should be placed in a -devel pkg.
[/] SHOULD: If the package has file dependencies outside of /etc, /bin, /sbin, /usr/bin, or /usr/sbin consider requiring the package which provides the file instead of the file itself.

All okay, so:

===================================================

 The package mingw32-boost is APPROVED by epienbro

===================================================

Comment 13 Thomas Sailer 2009-06-16 12:42:29 UTC
Thanks for the review!

New Package CVS Request
=======================
Package Name: mingw32-boost
Short Description: MinGW Windows Boost C++ library
Owners: sailer epienbro rjones
Branches: F-11
InitialCC:

Comment 14 Jason Tibbitts 2009-06-17 16:34:42 UTC
CVS done.

Comment 15 Fedora Update System 2009-06-18 14:33:37 UTC
mingw32-boost-1.37.0-4.fc11 has been submitted as an update for Fedora 11.
http://admin.fedoraproject.org/updates/mingw32-boost-1.37.0-4.fc11

Comment 16 Fedora Update System 2009-06-19 13:41:35 UTC
mingw32-boost-1.37.0-4.fc11 has been pushed to the Fedora 11 stable repository.  If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.