bugPSPP - Bugs: bug #29965, Not possible to crosscompile...

 
 

bug #29965: Not possible to crosscompile latest master version.

Submitted by:  Harry Thijssen <unknown_one>
Submitted on:  Wed 26 May 2010 07:11:04 AM UTC  
 
Category: Compilation/PortabilitySeverity: 5 - Average
Status: FixedAssigned to: None
Open/Closed: ClosedRelease: None
Effort: 0.00

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

(Jump to the original submission Jump to the original submission)

Thu 17 Jun 2010 03:48:59 AM UTC, comment #17:

Closing, as this should now be fixed. Please re-open if this is incorrect.

Ben Pfaff <blp>
Project Administrator
Tue 15 Jun 2010 04:16:32 PM UTC, comment #16:

>The strtod problem still exists but seems to be a gnulib problem.


Bruno Haible and I fixed this problem in Gnulib now. Please ignore the patch and try the latest Gnulib.

Ben Pfaff <blp>
Project Administrator
Fri 11 Jun 2010 01:51:23 PM UTC, comment #15:

The fix solves the issue of the tmpfile. The strtod problem still exists but seems to be a gnulib problem. The configure switch is a workaround for this. So this issue can be closed.

The gnulib patch doesn't work.

patching file lib/stdlib.in.h
Hunk #1 FAILED at 29.
1 out of 1 hunk FAILED -- saving rejects to file lib/stdlib.in.h.rej
patching file m4/strtod.m4
Hunk #1 FAILED at 82.
1 out of 1 hunk FAILED -- saving rejects to file m4/strtod.m4.rej

See also the attached reject file

(file #20734)

Harry Thijssen <unknown_one>
Fri 11 Jun 2010 04:33:42 AM UTC, comment #14:

I pushed a fix for the tmpfile problem.

Ben Pfaff <blp>
Project Administrator
Fri 11 Jun 2010 04:19:25 AM UTC, comment #13:

I'm attaching a patch against Gnulib that fixes the strtod.c build error. This is under review on the Gnulib mailing list.

(file #20731)

Ben Pfaff <blp>
Project Administrator
Wed 02 Jun 2010 08:40:45 PM UTC, comment #12:

From Harry via email:

Ben Pfaff <blp>
Project Administrator
Wed 02 Jun 2010 03:56:06 PM UTC, comment #11:

Harry, could you pass the -k option to make, so that we can get all the compile errors at once?

Ben Pfaff <blp>
Project Administrator
Wed 02 Jun 2010 03:26:45 PM UTC, comment #10:

This results in the next error:

libtool: compile: i686-pc-mingw32-gcc -std=gnu99 -DHAVE_CONFIG_H -I. -I ./src/libpspp -I./gl -I./gl -DINSTALLDIR=\"/usr/i686-pc-mingw32/sys-root/mingw/bin\" -I./src -I./lib -I./src/language/stats -I./src/language/expressions -I./src/language/expressions -Isrc -I/usr/i686-pc-mingw32/sys-root/mingw/include -mms-bitfields -I/usr/i686-pc-mingw32/sys-root/mingw/include/cairo -I/usr/i686-pc-mingw32/sys-root/mingw/include/pixman-1 -I/usr/i686-pc-mingw32/sys-root/mingw/include/freetype2 -I/usr/i686-pc-mingw32/sys-root/mingw/include -I/usr/i686-pc-mingw32/sys-root/mingw/include/libpng14 -I/usr/i686-pc-mingw32/sys-root/mingw/include/pango-1.0 -I/usr/i686-pc-mingw32/sys-root/mingw/include/glib-2.0 -I/usr/i686-pc-mingw32/sys-root/mingw/lib/glib-2.0/include -Wall -W -Wwrite-strings -Wstrict-prototypes -Wpointer-arith -Wno-sign-compare -Wmissing-prototypes -O2 -g -pipe -Wall -fexceptions -fno-omit-frame-pointer -fno-optimize-sibling-calls --param=ssp-buffer-size=4 -mms-bitfields -Wdeclaration-after-statement -MT src/libpspp/src_libpspp_libpspp_la-tmpfile.lo -MD -MP -MF src/libpspp/.deps/src_libpspp_libpspp_la-tmpfile.Tpo -c src/libpspp/tmpfile.c -DDLL_EXPORT -DPIC -o src/libpspp/.libs/src_libpspp_libpspp_la-tmpfile.o
src/libpspp/tmpfile.c:51: error: conflicting types for 'tmpfile_create'
./src/libpspp/tmpfile.h:26: note: previous declaration of 'tmpfile_create' was here
src/libpspp/tmpfile.c:65: error: conflicting types for 'tmpfile_destroy'
./src/libpspp/tmpfile.h:27: note: previous declaration of 'tmpfile_destroy' was here
src/libpspp/tmpfile.c: In function 'tmpfile_destroy':
src/libpspp/tmpfile.c:70: warning: passing argument 1 of 'tmpfile_error' from incompatible pointer type
./src/libpspp/tmpfile.h:30: note: expected 'const struct tmpfile ' but argument is of type 'struct rpl_tmpfile '
src/libpspp/tmpfile.c: In function 'do_seek':
src/libpspp/tmpfile.c:87: warning: passing argument 1 of 'tmpfile_error' from incompatible pointer type
./src/libpspp/tmpfile.h:30: note: expected 'const struct tmpfile ' but argument is of type 'struct rpl_tmpfile '
src/libpspp/tmpfile.c: In function 'do_read':
src/libpspp/tmpfile.c:112: warning: passing argument 1 of 'tmpfile_error' from incompatible pointer type
./src/libpspp/tmpfile.h:30: note: expected 'const struct tmpfile ' but argument is of type 'struct rpl_tmpfile '
src/libpspp/tmpfile.c: In function 'do_write':
src/libpspp/tmpfile.c:134: warning: passing argument 1 of 'tmpfile_error' from incompatible pointer type
./src/libpspp/tmpfile.h:30: note: expected 'const struct tmpfile ' but argument is of type 'struct rpl_tmpfile '
src/libpspp/tmpfile.c: At top level:
src/libpspp/tmpfile.c:147: error: conflicting types for 'tmpfile_read'
./src/libpspp/tmpfile.h:28: note: previous declaration of 'tmpfile_read' was here
src/libpspp/tmpfile.c:155: error: conflicting types for 'tmpfile_write'
./src/libpspp/tmpfile.h:29: note: previous declaration of 'tmpfile_write' was here
src/libpspp/tmpfile.c:163: error: conflicting types for 'tmpfile_error'
./src/libpspp/tmpfile.h:30: note: previous declaration of 'tmpfile_error' was here
make[2]: *** [src/libpspp/src_libpspp_libpspp_la-tmpfile.lo] Fout 1
make[2]: Map '/home/harry/pspp-master-20100602/pspp-0.7.5-g38392c' wordt verlaten
make[1]: *** [all-recursive] Fout 1

Have fun

Harry Thijssen <unknown_one>
Wed 02 Jun 2010 04:44:11 AM UTC, comment #9:

Harry: could you try adding "ac_cv_func_strtod=yes" to your invocation of "configure"? That may work around the problem for now.

Ben Pfaff <blp>
Project Administrator
Wed 02 Jun 2010 04:39:20 AM UTC, comment #8:

>It is strange because configure thinks that your toolchain
>doesn't have a working strtod without even test for it


It assumes that it needs to replace strtod() when it is cross-compiling, presumably because there's no way to test whether strtod() works properly when cross-compiling.

Ben Pfaff <blp>
Project Administrator
Thu 27 May 2010 04:32:42 PM UTC, comment #7:

Unfortunately this doesn't solve the issue. Looking at the gnulib patch I also tried inserting the line between line 13 and 14, but this didn't solve the issue either.

Harry Thijssen <unknown_one>
Thu 27 May 2010 11:31:51 AM UTC, comment #6:

I think this may be the cause: http://git.savannah.gnu.org/gitweb/?p=gnulib.git;a=commit;h=e692396584de5b495575f50860b91d37ebd2ff51

Can you please insert "REPLACE_STRTOD=1" between lines 12 and 13 of your gl/m4/strtod.m4 and try to compile?

Michel Boaventura <michelboaventura>
Project Member
Thu 27 May 2010 07:27:31 AM UTC, comment #5:

I tried it with an "old" and with an updated toolchain and with the same result. Versions prior to 13-5-2010 don't have this issue.

This http://lists.gnu.org/archive/html/pspp-dev/2010-05/msg00098.html change might be the source of the problem.

Harry Thijssen <unknown_one>
Wed 26 May 2010 10:55:44 PM UTC, comment #4:

It is strange because configure thinks that your toolchain doesn't have a working strtod without even test for it (config.log lines 34002-34003):

configure:41124: checking for working strtod
configure:41175: result: no

More strange is this error to appears just now. There is nothing on gnulib neither pspp that has changed related with strtod.

Did you update your toolchain? What is the last version which compiles?

Michel Boaventura <michelboaventura>
Project Member
Wed 26 May 2010 03:43:20 PM UTC, comment #3:

Now with a compressed config.log

(file #20629)

Harry Thijssen <unknown_one>
Wed 26 May 2010 03:35:41 PM UTC, comment #2:

Hereby the config.log and config.h

(file #20628)

Harry Thijssen <unknown_one>
Wed 26 May 2010 09:25:23 AM UTC, comment #1:

I suggest that you post your config.log file and any other information that might indicate why the system thinks that a replacement strtod is necessary.

John Darrington <jmd>
Project Administrator
Wed 26 May 2010 07:11:04 AM UTC, original submission:

I used the latest tarball from pfaff.org. On openSUSE everything
seems to work nice. But when use Mingw for cross compiling to MSWindows I get the next error:
======================

depbase=`echo strtod.lo | sed 's|[^/]*$|.deps/&|;s|\.lo$||'`;\
/bin/sh ../libtool --tag=CC --mode=compile
i686-pc-mingw32-gcc -std=gnu99 -DHAVE_CONFIG_H -DEXEEXT=\".exe\" -I.
-I.. -I/usr/i686-pc-mingw32/sys-root/mingw/include -mms-bitfields
-I/usr/i686-pc-mingw32/sys-root/mingw/include/cairo
-I/usr/i686-pc-mingw32/sys-root/mingw/include/pixman-1
-I/usr/i686-pc-mingw32/sys-root/mingw/include/freetype2
-I/usr/i686-pc-mingw32/sys-root/mingw/include
-I/usr/i686-pc-mingw32/sys-root/mingw/include/libpng14
-I/usr/i686-pc-mingw32/sys-root/mingw/include/pango-1.0
-I/usr/i686-pc-mingw32/sys-root/mingw/include/glib-2.0
-I/usr/i686-pc-mingw32/sys-root/mingw/lib/glib-2.0/include -O2 -g
-pipe -Wall -fexceptions -fno-omit-frame-pointer
-fno-optimize-sibling-calls --param=ssp-buffer-size=4 -mms-bitfields
-Wdeclaration-after-statement -MT strtod.lo -MD -MP -MF $depbase.Tpo
-c -o strtod.lo strtod.c &&\
mv -f $depbase.Tpo $depbase.Plo
libtool: compile: i686-pc-mingw32-gcc -std=gnu99 -DHAVE_CONFIG_H
-DEXEEXT=\".exe\" -I. -I..
-I/usr/i686-pc-mingw32/sys-root/mingw/include -mms-bitfields
-I/usr/i686-pc-mingw32/sys-root/mingw/include/cairo
-I/usr/i686-pc-mingw32/sys-root/mingw/include/pixman-1
-I/usr/i686-pc-mingw32/sys-root/mingw/include/freetype2
-I/usr/i686-pc-mingw32/sys-root/mingw/include
-I/usr/i686-pc-mingw32/sys-root/mingw/include/libpng14
-I/usr/i686-pc-mingw32/sys-root/mingw/include/pango-1.0
-I/usr/i686-pc-mingw32/sys-root/mingw/include/glib-2.0
-I/usr/i686-pc-mingw32/sys-root/mingw/lib/glib-2.0/include -O2 -g
-pipe -Wall -fexceptions -fno-omit-frame-pointer
-fno-optimize-sibling-calls --param=ssp-buffer-size=4 -mms-bitfields
-Wdeclaration-after-statement -MT strtod.lo -MD -MP -MF
.deps/strtod.Tpo -c strtod.c -DDLL_EXPORT -DPIC -o .libs/strtod.o
strtod.c:37: error: redefinition of 'strtod'
/usr/i686-pc-mingw32/sys-root/mingw/include/stdlib.h:319: note:
previous definition of 'strtod' was here
make[4]: *** [strtod.lo] Fout 1
make[4]: Map '/home/harry/pspp-master-20100522/pspp-0.7.5-g0ee0a3/gl'
wordt verlaten

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

Using the a newer master version or updating the mingw toolchain doesn't solve the issue.

Harry Thijssen <unknown_one>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach File(s):
   
   
Comment:
   

Attached Files
file #20734:  stdlib.in.h.rej added by unknown_one (593B - application/x-reject)
file #20731:  0001-Bypass-broken-inline-strtod-definition-in-stdlib.h-o.patch added by blp (3KiB - text/x-diff - gnuilb patch to fix strtod issue)
file #20629:  config.log.tar.gz added by unknown_one (70KiB - application/x-gzip)
file #20628:  config.h added by unknown_one (62KiB - text/x-chdr)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by blp (Posted a comment)
  • -unavailable- added by michelboaventura (Posted a comment)
  • -unavailable- added by jmd (Posted a comment)
  • -unavailable- added by unknown_one (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 8 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Thu 17 Jun 2010 03:48:59 AM UTCblpStatusWorks For Me=>Fixed
      Open/ClosedOpen=>Closed
    Tue 15 Jun 2010 04:16:32 PM UTCblpStatusReady for Test/Review=>Works For Me
    Fri 11 Jun 2010 01:51:23 PM UTCunknown_oneAttached File-=>Added stdlib.in.h.rej, #20734
    Fri 11 Jun 2010 04:35:34 AM UTCblpStatusNone=>Ready for Test/Review
    Fri 11 Jun 2010 04:19:25 AM UTCblpAttached File-=>Added 0001-Bypass-broken-inline-strtod-definition-in-stdlib.h-o.patch, #20731
    Wed 26 May 2010 03:43:20 PM UTCunknown_oneAttached File-=>Added config.log.tar.gz, #20629
    Wed 26 May 2010 03:35:41 PM UTCunknown_oneAttached File-=>Added config.h, #20628

    Back to the top


    Powered by Savane 3.1-cleanup1