Status: New
Owner: [email protected]
Labels: Type-Defect Priority-Medium

New issue 602 by [email protected]: Protobuf fails to build on Solaris 10/11
http://code.google.com/p/protobuf/issues/detail?id=602

What steps will reproduce the problem?
1. Try to build on Solaris 10/11 with GCC or Solaris Studio.

What is the expected output? What do you see instead?
I expect Protobuf to build and for make check to be successful. Protobuf fails to build.


What version of the product are you using? On what operating system?
2.5.0 and subversion trunk. Solaris 10 and Solaris 11. Both x86 and SPARC.

Please provide any additional information below.
Protobuf fails to build on Solaris for the following reasons:
* sched_yield() requires linking with librt on Solaris 10.
* Solaris Studio requires specifying -features=tmplrefstatic to handle some templates.
* atomic operations are missing for SPARC.

Protobuf make check fails with Solaris Studio because:
* #include <clocale> is missing from stringprintf_unittest.cc
* NULL literal recognition template fails.

Attached is a patch that fixes all these problems. Parts of it overlap issues 561 and 565.

I have tested this patch against the following configurations:

Solaris 10:
 * SPARC:
   * GCC 3.4.3:
     * 32-bit: PASS
     * 64-bit: PASS
   * Solaris Studio 12.3:
     * 32-bit: PASS
     * 64-bit: PASS
 * x86:
   * GCC 3.4.3:
     * 32-bit: PASS
     * 64-bit: PASS
   * Solaris Studio 12.3:
     * 32-bit: PASS
     * 64-bit: PASS

Solaris 11.1:
 * x86:
   * GCC 4.5.2:
     * 32-bit: PASS
     * 64-bit: PASS
   * Solaris Studio 12.3:
     * 32-bit: PASS
     * 64-bit: PASS

Ubuntu 13.10:
(This was a sanity-check to ensure I didn't inadvertently break something.)
 * x86:
    * GCC 4.8.1
      * 64-bit: PASS

Test procedure:

$ ./configure
 or (for 32-bit): $ ./configure --disable-64bit-solaris
$ make
$ make check

PASS = built and all tests passed.

I don't have access to a SPARC Solaris 11 machine so I have not been able to test that configuration, although I believe it should work.

Attachments:
        protobuf-2.5.1-pre_solaris.patch  14.3 KB

--
You received this message because this project is configured to send all issue notifications to this address.
You may adjust your notification preferences at:
https://code.google.com/hosting/settings

--
You received this message because you are subscribed to the Google Groups "Protocol 
Buffers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/protobuf.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to