Skip Menu |

This queue is for tickets about the Prima CPAN distribution.

Report information
The Basics
Id: 102935
Status: resolved
Priority: 0/
Queue: Prima

People
Owner: Nobody in particular
Requestors: SREZIC [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: 1.42
Fixed in: 1.43



Subject: Does not compile anymore on FreeBSD systems
See http://matrix.cpantesters.org/?dist=Prima%201.42 for a fail/pass overview. Build problems are different on FreeBSD 9.2 (sample report: http://www.cpantesters.org/cpan/report/e23e1c0e-c94b-11e4-aeff-b8b9dfbfc7aa - Makefile.PL already fails) and FreeBSD 10 (sample report: http://www.cpantesters.org/cpan/report/abd8c1b2-c87b-11e4-9dcf-e4f1e0bfc7aa )
On 2015-03-21 17:19:49, SREZIC wrote: Show quoted text
> See http://matrix.cpantesters.org/?dist=Prima%201.42 for a fail/pass > overview. Build problems are different on FreeBSD 9.2 (sample report: > http://www.cpantesters.org/cpan/report/e23e1c0e-c94b-11e4-aeff- > b8b9dfbfc7aa - Makefile.PL already fails) and FreeBSD 10 (sample > report: http://www.cpantesters.org/cpan/report/abd8c1b2-c87b-11e4- > 9dcf-e4f1e0bfc7aa )
Possible fix for freebsd 10: strncasecmp and strnicmp take three arguments, not two: diff --git i/include/apricot.h w/include/apricot.h index d0fccd7..097f7be 100644 --- i/include/apricot.h +++ w/include/apricot.h @@ -292,7 +292,7 @@ stricmp(const char *s1, const char *s2); #ifdef HAVE_STRNCASECMP #define strnicmp(a,b,c) strncasecmp((a),(b),(c)) #else -#define strncasecmp(a,b) strnicmp((a),(b)) +#define strncasecmp(a,b,c) strnicmp((a),(b),(c)) #define PRIMA_NEED_OWN_STRNICMP 1 extern int strnicmp(const char *s1, const char *s2, size_t count);
On 2015-03-21 17:19:49, SREZIC wrote: Show quoted text
> See http://matrix.cpantesters.org/?dist=Prima%201.42 for a fail/pass > overview. Build problems are different on FreeBSD 9.2 (sample report: > http://www.cpantesters.org/cpan/report/e23e1c0e-c94b-11e4-aeff- > b8b9dfbfc7aa - Makefile.PL already fails) and FreeBSD 10 (sample > report: http://www.cpantesters.org/cpan/report/abd8c1b2-c87b-11e4- > 9dcf-e4f1e0bfc7aa )
FreeBSD 9 seems to want the -fPIC option when compiling shared objects. I can achieve this by adding an argument to the cc_command_line call in compile() in Makefile.PL like this: my $cc = cc_command_line( $tmpsrc, $tmpo, $tmpexe, $compile_only || 0, $compile_only || 1); With this change Makefile.PL and compilation run successfully.
On Sat Mar 21 17:55:52 2015, SREZIC wrote: Show quoted text
> On 2015-03-21 17:19:49, SREZIC wrote:
> > See http://matrix.cpantesters.org/?dist=Prima%201.42 for a fail/pass > > overview. Build problems are different on FreeBSD 9.2 (sample report: > > http://www.cpantesters.org/cpan/report/e23e1c0e-c94b-11e4-aeff- > > b8b9dfbfc7aa - Makefile.PL already fails) and FreeBSD 10 (sample > > report: http://www.cpantesters.org/cpan/report/abd8c1b2-c87b-11e4- > > 9dcf-e4f1e0bfc7aa )
> > FreeBSD 9 seems to want the -fPIC option when compiling shared > objects. I can achieve this by adding an argument to the > cc_command_line call in compile() in Makefile.PL like this: > > my $cc = cc_command_line( $tmpsrc, $tmpo, $tmpexe, $compile_only || 0, > $compile_only || 1); > > With this change Makefile.PL and compilation run successfully.