Installation problem with Msys

488 views
Skip to first unread message

david allen

unread,
Dec 9, 2013, 2:55:20 PM12/9/13
to fltkg...@googlegroups.com
My University just supplied me with a Windows 7 laptop. Msys installed with no apparent problems. Using 1.3.2, "make" failed when it hit  factory.cxx. The message was

previous declaration of  int _stricmp ...

Help appreciated.

Greg Ercolano

unread,
Dec 9, 2013, 3:02:34 PM12/9/13
to fltkg...@googlegroups.com, david allen

Ian MacArthur

unread,
Dec 9, 2013, 4:47:31 PM12/9/13
to fltkg...@googlegroups.com
Just “for the record” I’m using various iterations of fltk on Win7 with Msys/Mingw and it works fine.

However, I have a vague sense that I’ve seen this warning flagged before: might have been on the list here, or it may have been someone at my work... And I can’t recall what the issue was, either... So not all that helpful.

If it was related to my work, and if Brian T’s reading this, then he might have some ideas... He’s also a heavy user of fltk on different WinXX versions, often with mingw, so if there’s some weirdness, there’s a good chance he has seen it!

Which reminds me... which shell / console are you using with mingw? Brian recommends that people use the mintty console on Win7, as the old favourite rxvt derived one sometimes does Weird Stuff, and was corrupting his builds by returning duff paths and duff environment values - switching to the minty console “fixed” things... Might be relevant here if the configure is returning odd looking states.




Greg Ercolano

unread,
Dec 9, 2013, 5:02:06 PM12/9/13
to fltkg...@googlegroups.com
On 12/09/13 13:41, Allen, David wrote:
> I tried your suggestion. This time configure gives an error message:
>
> configure: error: cannot run /bin/sh ./config.sub
>

Hmm, need more info; can you include a bit of screen history so we can see your
shell prompt and the command you're running, and all the output from the command
up to and including the error.

Allen, David

unread,
Dec 10, 2013, 11:32:42 AM12/10/13
to fltkg...@googlegroups.com
My most recent problem was due to my not doing

automake --add-missing

after autoconf

After correcting that, the configure process worked fine. However, make failed for r10022 at the same
place it failed for 1.3.2, ie when it encountered factory.cxx

Regarding Ian's suggestion about the console, I am using what a freshly installed Msys gave me.
I wasn't aware there is an alternative.

thanks so much for your efforts on this.
________________________________________
From: fltkg...@googlegroups.com [fltkg...@googlegroups.com] on behalf of Greg Ercolano [erco_...@seriss.com]
Sent: Monday, December 09, 2013 5:02 PM
To: fltkg...@googlegroups.com
Subject: Re: [fltk.general] Installation problem with Msys

--
You received this message because you are subscribed to the Google Groups "fltk.general" group.
To unsubscribe from this group and stop receiving emails from it, send an email to fltkgeneral...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Ian MacArthur

unread,
Dec 10, 2013, 6:33:30 PM12/10/13
to fltkg...@googlegroups.com

On 10 Dec 2013, at 16:32, Allen, David <david...@uky.edu> wrote:

> My most recent problem was due to my not doing
>
> automake --add-missing
>
> after autoconf
>
> After correcting that, the configure process worked fine. However, make failed for r10022 at the same
> place it failed for 1.3.2, ie when it encountered factory.cxx


OK; I see this - I set up XP in a clean VM then pulled the tar ball for fltk-1.3.x-r10022.tar.gz and did:

ianuser@XP-PRO-VM1 /d/source/test-fltk
$ tar -zxf fltk-1.3.x-r10022.tar.gz

ianuser@XP-PRO-VM1 /d/source/test-fltk
$ cd fltk-1.3.x-r10022

ianuser@XP-PRO-VM1 /d/source/test-fltk/fltk-1.3.x-r10022
$ autoconf

ianuser@XP-PRO-VM1 /d/source/test-fltk/fltk-1.3.x-r10022
$ automake --add-missing
configure.in: no proper invocation of AM_INIT_AUTOMAKE was found.
configure.in: You should verify that configure.in invokes AM_INIT_AUTOMAKE,
configure.in: that aclocal.m4 is present in the top-level directory,
configure.in: and that aclocal.m4 was recently regenerated (using aclocal).
configure.in:27: installing `./config.guess'
configure.in:27: installing `./config.sub'
automake-1.11: no `Makefile.am' found for any configure output

ianuser@XP-PRO-VM1 /d/source/test-fltk/fltk-1.3.x-r10022
$ ./configure
checking build system type... i686-pc-mingw32
checking host system type... i686-pc-mingw32
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.exe
checking for suffix of executables... .exe
checking whether we are cross compiling... no

(blah blah...)


Compiling code.cxx...
Compiling factory.cxx...
In file included from factory.cxx:33:0:
../src/flstring.h:43:37: error: 'int _stricmp' redeclared as different kind of symbol
# define strcasecmp(s,t) _stricmp((s), (t))
^
factory.cxx:46:1: note: in expansion of macro 'strcasecmp'
strcasecmp(const char *s, const char *t) {
^
In file included from ../FL/fl_utf8.h:34:0,
from ../FL/Fl.H:30,
from factory.cxx:27:
d:\mingw\include\string.h:81:37: error: previous declaration of 'int _stricmp(const char*, const char*)'
_CRTIMP int __cdecl __MINGW_NOTHROW _stricmp (const char*, const char*);
^
In file included from factory.cxx:33:0:
factory.cxx:46:12: error: expected primary-expression before 'const'
strcasecmp(const char *s, const char *t) {
^
../src/flstring.h:43:39: note: in definition of macro 'strcasecmp'
# define strcasecmp(s,t) _stricmp((s), (t))
^
factory.cxx:46:12: error: expected ')' before 'const'
strcasecmp(const char *s, const char *t) {
^
../src/flstring.h:43:39: note: in definition of macro 'strcasecmp'
# define strcasecmp(s,t) _stricmp((s), (t))
^
make[1]: *** [factory.o] Error 1
make: *** [all] Error 1


Which is the problem as reported.

Odd: I have not seen that before.

Seems like it might be a bug in configure perhaps?


If you edit config.h, try changing

/* #undef HAVE_STRCASECMP */

To instead say:

#define HAVE_STRCASECMP 1

Then redo the make, see if that is any better...

Not sure why this happened, will need more investigation; now is not the time though...

>
> Regarding Ian's suggestion about the console, I am using what a freshly installed Msys gave me.
> I wasn't aware there is an alternative.

There are many, and varied. Use mingw-get to install them; I favour the mintty option these days, most of the time...


MacArthur, Ian (Selex ES, UK)

unread,
Dec 11, 2013, 7:52:47 AM12/11/13
to fltkg...@googlegroups.com
OK, I'm at something of a loss now: I tried to recreate the failure I saw yesterday on the WinXP VM, here on a Win7 box, with mingw.

Basically, it all *worked fine* this time around.

Below is the log for the build:

Initially I unrolled the tarball, then went through a sequence of trying to invoke configure *before* running "autoconf" or "automake --add-missing" as I wanted to see what actually happened in that case (it just fails for want of ./config.sub in each case...)

The I ran configure, with no options set, then make. All worked fine, and the test folder built and runs OK.

In practice, with this version of mingw, I'd probably want to do:

LDFLAGS="-static-libgcc -static-libstdc++" ./configure

instead of course, to work around the dynamic libgcc/stdc++ libs issue, as normal.

Anyway, here is the full (and very long, sorry about that) log, in case anyone sees anything unusual (I did not..)

---------------


Win7 /d/examples/fltk-test
$ tar -jxf fltk-1.3.x-r10022.tar.bz2

Win7 /d/examples/fltk-test
$ cd fltk-1.3.x-r10022

Win7 /d/examples/fltk-test/fltk-1.3.x-r10022
$ ./configure
configure: error: cannot run /bin/sh ./config.sub

Win7 /d/examples/fltk-test/fltk-1.3.x-r10022
$ autoconf

Win7 /d/examples/fltk-test/fltk-1.3.x-r10022
$ ./configure
configure: error: cannot run /bin/sh ./config.sub

Win7 /d/examples/fltk-test/fltk-1.3.x-r10022
$ automake --add-missing
configure.in: no proper invocation of AM_INIT_AUTOMAKE was found.
configure.in: You should verify that configure.in invokes AM_INIT_AUTOMAKE,
configure.in: that aclocal.m4 is present in the top-level directory,
configure.in: and that aclocal.m4 was recently regenerated (using aclocal).
configure.in:27: installing `./config.guess'
configure.in:27: installing `./config.sub'
automake-1.11: no `Makefile.am' found for any configure output

Win7 /d/examples/fltk-test/fltk-1.3.x-r10022
$ ./configure
checking build system type... i686-pc-mingw32
checking host system type... i686-pc-mingw32
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.exe
checking for suffix of executables... .exe
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking for g++... g++
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking for a BSD-compatible install... /bin/install -c
checking for nroff... no
checking for htmldoc... no
checking for doxygen... /c/Program_Files_User/doxygen/bin/doxygen
checking for ranlib... ranlib
checking for ar... /mingw/bin/ar
checking for windres... /mingw/bin/windres
checking how to run the C preprocessor... gcc -E
checking for grep that handles long lines and -e... /bin/grep
checking for egrep... /bin/grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking size of short... 2
checking size of int... 4
checking size of long... 4
checking whether byte ordering is bigendian... no
checking whether the compiler recognizes bool as a built-in type... yes
checking for dirent.h that defines DIR... yes
checking for library containing opendir... none required
checking sys/select.h usability... no
checking sys/select.h presence... no
checking for sys/select.h... no
checking sys/stdtypes.h usability... no
checking sys/stdtypes.h presence... no
checking for sys/stdtypes.h... no
checking whether we have the POSIX compatible scandir() prototype... no
checking for scandir... no
checking for vsnprintf... yes
checking for snprintf... yes
checking for strings.h... (cached) yes
checking for strcasecmp... yes
checking for strlcat... no
checking for strlcpy... no
checking locale.h usability... yes
checking locale.h presence... yes
checking for locale.h... yes
checking for localeconv... yes
checking for library containing pow... none required
checking for special C compiler options needed for large files... no
checking for _FILE_OFFSET_BITS value needed for large files... unknown
checking for _LARGE_FILES value needed for large files... unknown
checking for long long int... yes
checking for library containing dlsym... no
checking dlfcn.h usability... no
checking dlfcn.h presence... no
checking for dlfcn.h... no
checking for jpeg_CreateCompress in -ljpeg... no
checking for gzgets in -lz... no
checking for png_read_info in -lpng... no
checking GL/gl.h usability... yes
checking GL/gl.h presence... yes
checking for GL/gl.h... yes
checking GL/glu.h usability... yes
checking GL/glu.h presence... yes
checking for GL/glu.h... yes
checking if GCC supports -fno-exceptions... yes
checking if GCC supports -fno-strict-aliasing... yes

Configuration Summary
-------------------------------------------------------------------------
Directories: prefix=/usr/local
bindir=${exec_prefix}/bin
datadir=${datarootdir}
datarootdir=${prefix}/share
exec_prefix=${prefix}
includedir=${prefix}/include
libdir=${exec_prefix}/lib
mandir=${datarootdir}/man
MSys docpath=D:/MinGW/msys/1.0/local/share/doc/fltk

Graphics: GDI
Image Libraries: JPEG=Builtin
PNG=Builtin
ZLIB=Builtin
Large Files: YES
OpenGL: YES
Threads: YES
configure: creating ./config.status
config.status: creating makeinclude
config.status: creating fltk.list
config.status: creating fltk-config
config.status: creating fltk.spec
config.status: creating FL/Makefile
config.status: creating config.h

Win7 /d/examples/fltk-test/fltk-1.3.x-r10022
$ make
=== making jpeg ===
Compiling jaricom.c...
Compiling jcapimin.c...
Compiling jcapistd.c...
Compiling jcarith.c...
Compiling jccoefct.c...
Compiling jccolor.c...
Compiling jcdctmgr.c...
Compiling jchuff.c...
Compiling jcinit.c...
Compiling jcmainct.c...
Compiling jcmarker.c...
Compiling jcmaster.c...
Compiling jcomapi.c...
Compiling jcparam.c...
Compiling jcprepct.c...
Compiling jcsample.c...
Compiling jctrans.c...
Compiling jdapimin.c...
Compiling jdapistd.c...
Compiling jdarith.c...
Compiling jdatadst.c...
Compiling jdatasrc.c...
Compiling jdcoefct.c...
Compiling jdcolor.c...
Compiling jddctmgr.c...
Compiling jdhuff.c...
Compiling jdinput.c...
Compiling jdmainct.c...
Compiling jdmarker.c...
Compiling jdmaster.c...
Compiling jdmerge.c...
Compiling jdpostct.c...
Compiling jdsample.c...
Compiling jdtrans.c...
Compiling jerror.c...
Compiling jfdctflt.c...
Compiling jfdctfst.c...
Compiling jfdctint.c...
Compiling jidctflt.c...
Compiling jidctfst.c...
Compiling jidctint.c...
Compiling jmemmgr.c...
Compiling jmemnobs.c...
Compiling jquant1.c...
Compiling jquant2.c...
Compiling jutils.c...
Archiving ../lib/libfltk_jpeg.a...
=== making zlib ===
Compiling adler32.c...
Compiling compress.c...
Compiling crc32.c...
Compiling uncompr.c...
Compiling deflate.c...
Compiling trees.c...
Compiling zutil.c...
Compiling inflate.c...
Compiling inftrees.c...
Compiling inffast.c...
Compiling gzclose.c...
Compiling gzlib.c...
Compiling gzread.c...
Compiling gzwrite.c...
Compiling infback.c...
Archiving ../lib/libfltk_z.a...
=== making png ===
Compiling png.c...
Compiling pngset.c...
Compiling pngget.c...
Compiling pngrutil.c...
Compiling pngtrans.c...
Compiling pngwutil.c...
Compiling pngread.c...
Compiling pngrio.c...
Compiling pngwio.c...
Compiling pngwrite.c...
Compiling pngrtran.c...
Compiling pngwtran.c...
Compiling pngmem.c...
Compiling pngerror.c...
Compiling pngpread.c...
Archiving ../lib/libfltk_png.a...
=== making src ===
Compiling Fl.cxx...
Compiling Fl_Adjuster.cxx...
Compiling Fl_Bitmap.cxx...
Compiling Fl_Browser.cxx...
Compiling Fl_Browser_.cxx...
Compiling Fl_Browser_load.cxx...
Compiling Fl_Box.cxx...
Compiling Fl_Button.cxx...
Compiling Fl_Chart.cxx...
Compiling Fl_Check_Browser.cxx...
Compiling Fl_Check_Button.cxx...
Compiling Fl_Choice.cxx...
Compiling Fl_Clock.cxx...
Compiling Fl_Color_Chooser.cxx...
Compiling Fl_Counter.cxx...
Compiling Fl_Dial.cxx...
Compiling Fl_Device.cxx...
Compiling Fl_Double_Window.cxx...
Compiling Fl_File_Browser.cxx...
Compiling Fl_File_Chooser.cxx...
Compiling Fl_File_Chooser2.cxx...
Compiling Fl_File_Icon.cxx...
Compiling Fl_File_Input.cxx...
Compiling Fl_Group.cxx...
Compiling Fl_Help_View.cxx...
Compiling Fl_Image.cxx...
Compiling Fl_Input.cxx...
Compiling Fl_Input_.cxx...
Compiling Fl_Light_Button.cxx...
Compiling Fl_Menu.cxx...
Compiling Fl_Menu_.cxx...
Compiling Fl_Menu_Bar.cxx...
Compiling Fl_Menu_Button.cxx...
Compiling Fl_Menu_Window.cxx...
Compiling Fl_Menu_add.cxx...
Compiling Fl_Menu_global.cxx...
Compiling Fl_Multi_Label.cxx...
Compiling Fl_Native_File_Chooser.cxx...
Compiling Fl_Overlay_Window.cxx...
Compiling Fl_Pack.cxx...
Compiling Fl_Paged_Device.cxx...
Compiling Fl_Pixmap.cxx...
Compiling Fl_Positioner.cxx...
Compiling Fl_Preferences.cxx...
Compiling Fl_Printer.cxx...
Compiling Fl_Progress.cxx...
Compiling Fl_Repeat_Button.cxx...
Compiling Fl_Return_Button.cxx...
Compiling Fl_Roller.cxx...
Compiling Fl_Round_Button.cxx...
Compiling Fl_Scroll.cxx...
Compiling Fl_Scrollbar.cxx...
Compiling Fl_Shared_Image.cxx...
Compiling Fl_Single_Window.cxx...
Compiling Fl_Slider.cxx...
Compiling Fl_Table.cxx...
Compiling Fl_Table_Row.cxx...
Compiling Fl_Tabs.cxx...
Compiling Fl_Text_Buffer.cxx...
Compiling Fl_Text_Display.cxx...
Compiling Fl_Text_Editor.cxx...
Compiling Fl_Tile.cxx...
Compiling Fl_Tiled_Image.cxx...
Compiling Fl_Tree.cxx...
Compiling Fl_Tree_Item.cxx...
Compiling Fl_Tree_Item_Array.cxx...
Compiling Fl_Tree_Prefs.cxx...
Compiling Fl_Tooltip.cxx...
Compiling Fl_Valuator.cxx...
Compiling Fl_Value_Input.cxx...
Compiling Fl_Value_Output.cxx...
Compiling Fl_Value_Slider.cxx...
Compiling Fl_Widget.cxx...
Compiling Fl_Window.cxx...
Compiling Fl_Window_fullscreen.cxx...
Compiling Fl_Window_hotspot.cxx...
Compiling Fl_Window_iconize.cxx...
Compiling Fl_Wizard.cxx...
Compiling Fl_XBM_Image.cxx...
Compiling Fl_XPM_Image.cxx...
Compiling Fl_abort.cxx...
Compiling Fl_add_idle.cxx...
Compiling Fl_arg.cxx...
Compiling Fl_compose.cxx...
Compiling Fl_display.cxx...
Compiling Fl_get_key.cxx...
Compiling Fl_get_system_colors.cxx...
Compiling Fl_grab.cxx...
Compiling Fl_lock.cxx...
Compiling Fl_own_colormap.cxx...
Compiling Fl_visual.cxx...
Compiling Fl_x.cxx...
Compiling filename_absolute.cxx...
Compiling filename_expand.cxx...
Compiling filename_ext.cxx...
Compiling filename_isdir.cxx...
Compiling filename_list.cxx...
Compiling filename_match.cxx...
Compiling filename_setext.cxx...
Compiling fl_arc.cxx...
Compiling fl_arci.cxx...
Compiling fl_ask.cxx...
Compiling fl_boxtype.cxx...
Compiling fl_color.cxx...
Compiling fl_cursor.cxx...
Compiling fl_curve.cxx...
Compiling fl_diamond_box.cxx...
Compiling fl_dnd.cxx...
Compiling fl_draw.cxx...
Compiling fl_draw_image.cxx...
Compiling fl_draw_pixmap.cxx...
Compiling fl_encoding_latin1.cxx...
Compiling fl_encoding_mac_roman.cxx...
Compiling fl_engraved_label.cxx...
Compiling fl_file_dir.cxx...
Compiling fl_font.cxx...
Compiling fl_gtk.cxx...
Compiling fl_labeltype.cxx...
Compiling fl_line_style.cxx...
Compiling fl_open_uri.cxx...
Compiling fl_oval_box.cxx...
Compiling fl_overlay.cxx...
Compiling fl_overlay_visual.cxx...
Compiling fl_plastic.cxx...
Compiling fl_read_image.cxx...
Compiling fl_rect.cxx...
Compiling fl_round_box.cxx...
Compiling fl_rounded_box.cxx...
Compiling fl_set_font.cxx...
Compiling fl_set_fonts.cxx...
Compiling fl_scroll_area.cxx...
Compiling fl_shadow_box.cxx...
Compiling fl_shortcut.cxx...
Compiling fl_show_colormap.cxx...
Compiling fl_symbols.cxx...
Compiling fl_vertex.cxx...
Compiling screen_xywh.cxx...
Compiling fl_utf8.cxx...
Compiling ps_image.cxx...
Compiling fl_call_main.c...
Compiling flstring.c...
Compiling scandir.c...
Compiling numericsort.c...
Compiling vsnprintf.c...
Compiling fl_utf.c...
Compiling xutf8/case.c...
Compiling xutf8/is_right2left.c...
Compiling xutf8/is_spacing.c...
Compiling xutf8/keysym2Ucs.c...
Compiling xutf8/utf8Input.c...
Compiling xutf8/utf8Utils.c...
Compiling xutf8/utf8Wrap.c...
/mingw/bin/ar cr ../lib/libfltk.a ...
Compiling forms_compatability.cxx...
Compiling forms_bitmap.cxx...
Compiling forms_free.cxx...
Compiling forms_fselect.cxx...
Compiling forms_pixmap.cxx...
Compiling forms_timer.cxx...
/mingw/bin/ar cr ../lib/libfltk_forms.a ...
Compiling Fl_Gl_Choice.cxx...
Compiling Fl_Gl_Overlay.cxx...
Compiling Fl_Gl_Device_Plugin.cxx...
Compiling Fl_Gl_Window.cxx...
Compiling freeglut_geometry.cxx...
Compiling freeglut_stroke_mono_roman.cxx...
Compiling freeglut_stroke_roman.cxx...
Compiling freeglut_teapot.cxx...
Compiling gl_draw.cxx...
Compiling gl_start.cxx...
Compiling glut_compatability.cxx...
Compiling glut_font.cxx...
/mingw/bin/ar cr ../lib/libfltk_gl.a ...
Compiling fl_images_core.cxx...
Compiling Fl_BMP_Image.cxx...
Compiling Fl_File_Icon2.cxx...
Compiling Fl_GIF_Image.cxx...
Compiling Fl_Help_Dialog.cxx...
Compiling Fl_JPEG_Image.cxx...
Compiling Fl_PNG_Image.cxx...
Compiling Fl_PNM_Image.cxx...
/mingw/bin/ar cr ../lib/libfltk_images.a ...
=== making fluid ===
Compiling CodeEditor.cxx...
Compiling Fl_Function_Type.cxx...
Compiling Fl_Group_Type.cxx...
Compiling Fl_Menu_Type.cxx...
Compiling Fl_Type.cxx...
Compiling Fl_Widget_Type.cxx...
Compiling Fl_Window_Type.cxx...
Compiling Fluid_Image.cxx...
Compiling about_panel.cxx...
Compiling align_widget.cxx...
Compiling alignment_panel.cxx...
Compiling code.cxx...
Compiling factory.cxx...
Compiling file.cxx...
Compiling fluid.cxx...
Compiling function_panel.cxx...
Compiling template_panel.cxx...
Compiling undo.cxx...
Compiling widget_panel.cxx...
Linking fluid.exe...
=== making test ===
Compiling unittests.cxx...
Linking unittests.exe...
Compiling adjuster.cxx...
Linking adjuster.exe...
Compiling arc.cxx...
Linking arc.exe...
Compiling ask.cxx...
Linking ask.exe...
Compiling bitmap.cxx...
Linking bitmap.exe...
Compiling blocks.cxx...
Linking blocks.exe...
Compiling boxtype.cxx...
Linking boxtype.exe...
Compiling browser.cxx...
Linking browser.exe...
Compiling button.cxx...
Linking button.exe...
Compiling buttons.cxx...
Linking buttons.exe...
Compiling cairo_test.cxx...
Linking cairo_test.exe...
Compiling checkers.cxx...
Linking checkers.exe...
Compiling clock.cxx...
Linking clock.exe...
Compiling colbrowser.cxx...
Linking colbrowser.exe...
Compiling color_chooser.cxx...
Linking color_chooser.exe...
Compiling cursor.cxx...
Linking cursor.exe...
Compiling curve.cxx...
Linking curve.exe...
Compiling demo.cxx...
Linking demo.exe...
Compiling device.cxx...
Linking device.exe...
Compiling doublebuffer.cxx...
Linking doublebuffer.exe...
Compiling editor.cxx...
Linking editor.exe...
Generating fast_slow.cxx and header from fast_slow.fl...
Compiling fast_slow.cxx...
Linking fast_slow.exe...
Compiling file_chooser.cxx...
Linking file_chooser.exe...
Compiling fonts.cxx...
Linking fonts.exe...
Compiling forms.cxx...
Linking forms.exe...
Compiling hello.cxx...
Linking hello.exe...
Compiling help.cxx...
Linking help.exe...
Compiling iconize.cxx...
Linking iconize.exe...
Compiling image.cxx...
Linking image.exe...
Generating inactive.cxx and header from inactive.fl...
Compiling inactive.cxx...
Linking inactive.exe...
Compiling input.cxx...
Linking input.exe...
Compiling input_choice.cxx...
Linking input_choice.exe...
Generating keyboard_ui.cxx and header from keyboard_ui.fl...
Compiling keyboard_ui.cxx...
Compiling keyboard.cxx...
Linking keyboard.exe...
Compiling label.cxx...
Linking label.exe...
Compiling line_style.cxx...
Linking line_style.exe...
Compiling list_visuals.cxx...
Linking list_visuals.exe...
Generating mandelbrot_ui.cxx and header from mandelbrot_ui.fl...
Compiling mandelbrot_ui.cxx...
Compiling mandelbrot.cxx...
Linking mandelbrot.exe...
Compiling menubar.cxx...
Linking menubar.exe...
Compiling message.cxx...
Linking message.exe...
Compiling minimum.cxx...
Linking minimum.exe...
Compiling native-filechooser.cxx...
Linking native-filechooser.exe...
Compiling navigation.cxx...
Linking navigation.exe...
Compiling output.cxx...
Linking output.exe...
Compiling overlay.cxx...
Linking overlay.exe...
Compiling pack.cxx...
Linking pack.exe...
Compiling pixmap.cxx...
Linking pixmap.exe...
Compiling pixmap_browser.cxx...
Linking pixmap_browser.exe...
Generating preferences.cxx and header from preferences.fl...
Compiling preferences.cxx...
Linking preferences.exe...
Generating radio.cxx and header from radio.fl...
Compiling radio.cxx...
Linking radio.exe...
Generating resize.cxx and header from resize.fl...
Compiling resize.cxx...
Linking resize.exe...
Compiling resizebox.cxx...
Linking resizebox.exe...
Compiling rotated_text.cxx...
Linking rotated_text.exe...
Compiling scroll.cxx...
Linking scroll.exe...
Compiling subwindow.cxx...
Linking subwindow.exe...
Compiling sudoku.cxx...
Linking sudoku.exe...
Compiling symbols.cxx...
Linking symbols.exe...
Compiling table.cxx...
Linking table.exe...
Generating tabs.cxx and header from tabs.fl...
Compiling tabs.cxx...
Linking tabs.exe...
Compiling threads.cxx...
Linking threads.exe...
Compiling tile.cxx...
Linking tile.exe...
Compiling tiled_image.cxx...
Linking tiled_image.exe...
Generating tree.cxx and header from tree.fl...
Compiling tree.cxx...
Linking tree.exe...
Generating valuators.cxx and header from valuators.fl...
Compiling valuators.cxx...
Linking valuators.exe...
Compiling utf8.cxx...
Linking utf8.exe...
Compiling cube.cxx...
Linking cube.exe...
Generating CubeViewUI.h and header from CubeViewUI.fl...
Compiling CubeMain.cxx...
Compiling CubeView.cxx...
Compiling CubeViewUI.cxx...
Linking CubeView.exe...
Compiling fractals.cxx...
Compiling fracviewer.cxx...
Linking fractals.exe...
Compiling fullscreen.cxx...
Linking fullscreen.exe...
Compiling gl_overlay.cxx...
Linking gl_overlay.exe...
Compiling glpuzzle.cxx...
Linking glpuzzle.exe...
Compiling shape.cxx...
Linking shape.exe...
=== making documentation ===
Formatting src/fltk.man...
/bin/sh: man: command not found
Formatting src/fltk-config.man...
/bin/sh: man: command not found
Formatting src/fluid.man...
/bin/sh: man: command not found
Formatting src/blocks.man...
/bin/sh: man: command not found
Formatting src/checkers.man...
/bin/sh: man: command not found
Formatting src/sudoku.man...
/bin/sh: man: command not found

Win7 /d/examples/fltk-test/fltk-1.3.x-r10022
$ gcc -v
Using built-in specs.
COLLECT_GCC=D:\MinGW\bin\gcc.exe
COLLECT_LTO_WRAPPER=d:/mingw/bin/../libexec/gcc/mingw32/4.7.2/lto-wrapper.exe
Target: mingw32
Configured with: ../gcc-4.7.2/configure --enable-languages=c,c++,ada,fortran,objc,obj-c++ --disable-sjlj-exceptions --with-dwarf2 --enable-shared --enable-libgomp --disable-win32-registry --enable-libstdcxx-debug --disable-build-poststage1-with-cxx --enable-version-specific-runtime-libs --build=mingw32 --prefix=/mingw
Thread model: win32
gcc version 4.7.2 (GCC)


-- end of log output --



Selex ES Ltd
Registered Office: Sigma House, Christopher Martin Road, Basildon, Essex SS14 3EL
A company registered in England & Wales. Company no. 02426132
********************************************************************
This email and any attachments are confidential to the intended
recipient and may also be privileged. If you are not the intended
recipient please delete it from your system and notify the sender.
You should not copy it or use it for any purpose nor disclose or
distribute its contents to any other person.
********************************************************************

Allen, David

unread,
Dec 11, 2013, 11:07:16 AM12/11/13
to fltkg...@googlegroups.com

Thanks Ian. I followed your recipe exactly and got comparable results up until this:
=== making fluid ===

Compiling factory.cxx...
In file included from factory.cxx:33:0:
../src/flstring.h:43:37: error: 'int _stricmp' redeclared as different kind of symbol
# define strcasecmp(s,t) _stricmp((s), (t))
^
factory.cxx:46:1: note: in expansion of macro 'strcasecmp'
strcasecmp(const char *s, const char *t) {
^
In file included from ../FL/fl_utf8.h:34:0,
from ../FL/Fl.H:30,
from factory.cxx:27:
c:\mingw\include\string.h:81:37: error: previous declaration of 'int _stricmp(const char*, const cha

r*)'
_CRTIMP int __cdecl __MINGW_NOTHROW _stricmp (const char*, const char*);
^
In file included from factory.cxx:33:0:
factory.cxx:46:12: error: expected primary-expression before 'const'
strcasecmp(const char *s, const char *t) {
^
../src/flstring.h:43:39: note: in definition of macro 'strcasecmp'
# define strcasecmp(s,t) _stricmp((s), (t))
^
factory.cxx:46:12: error: expected ')' before 'const'
strcasecmp(const char *s, const char *t) {
^
../src/flstring.h:43:39: note: in definition of macro 'strcasecmp'
# define strcasecmp(s,t) _stricmp((s), (t))
^
make[1]: *** [factory.o] Error 1
make: *** [all] Error 1

I did a basic install of Msys --- could I missed some needed component?
________________________________________
From: fltkg...@googlegroups.com [fltkg...@googlegroups.com] on behalf of MacArthur, Ian (Selex ES, UK) [ian.ma...@selex-es.com]
Sent: Wednesday, December 11, 2013 7:52 AM
To: fltkg...@googlegroups.com
Subject: RE: [fltk.general] Installation problem with Msys

LDFLAGS="-static-libgcc -static-libstdc++" ./configure

---------------

Win7 /d/examples/fltk-test/fltk-1.3.x-r10022
$ autoconf

--

MacArthur, Ian (Selex ES, UK)

unread,
Dec 11, 2013, 11:45:39 AM12/11/13
to fltkg...@googlegroups.com

> Thanks Ian. I followed your recipe exactly and got comparable results
> up until this:
> === making fluid ===
> Compiling factory.cxx...
> In file included from factory.cxx:33:0:
> ../src/flstring.h:43:37: error: 'int _stricmp' redeclared as different
> kind of symbol
> # define strcasecmp(s,t) _stricmp((s), (t))

<snip>

Yes, did you see my earlier post?

I saw that failure in a test build on my WinXP VM, but can not reproduce it on my regular Win7 test box.

It *seems* to be something to do with the way configure is detecting strcasecmp support.

If you hand-edit config.h, find the undef of HAVE_STRCASECMP and replace it with

#define HAVE_STRCASECMP 1

and re-run the make. It *should* then succeed.

I do not know why configure is not setting the HAVE_STRCASECMP define correctly.
It seems odd that it works fine *on some systems* but not others.



Which version of gcc is you mingw? Maybe that is relevant?

The one I have here is:

$ gcc -v

Using built-in specs.
COLLECT_GCC=D:\MinGW\bin\gcc.exe
COLLECT_LTO_WRAPPER=d:/mingw/bin/../libexec/gcc/mingw32/4.7.2/lto-wrapper.exe
Target: mingw32
Configured with: ../gcc-4.7.2/configure --enable-languages=c,c++,ada,fortran,objc,obj-c++ --disable-sjlj-exceptions --with-dwarf2 --enable-shared --enable-libgomp --disable-win32-registry --enable-libstdcxx-debug --disable-build-poststage1-with-cxx --enable-version-specific-runtime-libs --build=mingw32 --prefix=/mingw
Thread model: win32
gcc version 4.7.2 (GCC)


So that's 4.7.2; I *think* the version of gcc on the build that failed was more recent, as it was "up to date", which this machine is not.
I'd guess the gcc on the failed build might have been 4.8.1.

Might be relevant, not sure.

What version of gcc do you have?

Does the build complete OK if you edit config.h as noted above?

--
Ian

Allen, David

unread,
Dec 11, 2013, 12:26:07 PM12/11/13
to fltkg...@googlegroups.com
YES!!!!! thanks so much.

________________________________________
From: fltkg...@googlegroups.com [fltkg...@googlegroups.com] on behalf of MacArthur, Ian (Selex ES, UK) [ian.ma...@selex-es.com]
Sent: Wednesday, December 11, 2013 11:45 AM

To: fltkg...@googlegroups.com
Subject: RE: [fltk.general] Installation problem with Msys

> Thanks Ian. I followed your recipe exactly and got comparable results

<snip>

#define HAVE_STRCASECMP 1

$ gcc -v

--
Ian

--

MacArthur, Ian (Selex ES, UK)

unread,
Dec 11, 2013, 12:54:02 PM12/11/13
to fltkg...@googlegroups.com

> YES!!!!! thanks so much.


OK - glad that worked.

What version of gcc is your mingw using?
I do wonder if that is the crux to this problem...

Allen, David

unread,
Dec 11, 2013, 4:24:52 PM12/11/13
to fltkg...@googlegroups.com
g++ --version

gives

4.8.1

________________________________________
From: fltkg...@googlegroups.com [fltkg...@googlegroups.com] on behalf of MacArthur, Ian (Selex ES, UK) [ian.ma...@selex-es.com]

Sent: Wednesday, December 11, 2013 12:54 PM


To: fltkg...@googlegroups.com
Subject: RE: [fltk.general] Installation problem with Msys

> YES!!!!! thanks so much.

--

Ian MacArthur

unread,
Dec 11, 2013, 5:25:03 PM12/11/13
to fltkg...@googlegroups.com

On 11 Dec 2013, at 21:24, Allen, David <david...@uky.edu> wrote:

> g++ --version
>
> gives
>
> 4.8.1




OK - that's kinda what I suspected; though I am not sure at all how to go about "fixing" it...

For me, if I look in config.log after running configure, then:

With mingw gcc-4.8.1 I see:

configure:5612: checking for strcasecmp
configure:5612: gcc -o conftest.exe conftest.c >&5
conftest.c:51:6: warning: conflicting types for built-in function 'strcasecmp' [enabled by default]
char strcasecmp ();
^
C:\DOCUME~1\ianuser\LOCALS~1\Temp\ccyzCt00.o:conftest.c:(.text+0xc): undefined reference to `strcasecmp'
collect2.exe: error: ld returned 1 exit status
configure:5612: $? = 1
configure: failed program was:

<snip>

configure:5612: result: no



Whereas with mingw gcc-4.7.2 I see instead:


configure:5612: checking for strcasecmp
configure:5612: gcc -o conftest.exe conftest.c >&5
conftest.c:51:6: warning: conflicting types for built-in function 'strcasecmp' [enabled by default]
char strcasecmp ();
^
configure:5612: $? = 0
configure:5612: result: yes


So... both compilers report that strcasecmp is a built-in function, but for whatever reason 4.8.1 then fails to link, whereas 4.7.2 links OK...

If I write test code that just uses strcasecmp "normally" it works fine in either case!

For comparison, here's what I see for the same test on OSX, with Apple LLVM version 5.0 (clang-500.2.79)


configure:7385: checking for strcasecmp
configure:7441: gcc -o conftest conftest.c >&5
conftest.c:54:6: warning: incompatible redeclaration of library function 'strcasecmp' [-Wincompatible-library-redeclaration]
char strcasecmp ();
^
conftest.c:54:6: note: 'strcasecmp' is a builtin with type 'int (const char *, const char *)'
1 warning generated.
configure:7447: $? = 0
configure:7465: result: yes

Which, though the wording differs slightly, is broadly the same behaviour as the gcc-4.7.2 version exhibits.

I'm inclined to think that gcc-4.8.2 is doing "something odd", I have no ideas for how to proceed next.




Reply all
Reply to author
Forward
0 new messages