mingw-cross-env-list
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Fwd: [Mingw-cross-env-list] Error compiling source file including <stri


From: Pierre-Henri Trivier
Subject: Fwd: [Mingw-cross-env-list] Error compiling source file including <string.h>
Date: Tue, 12 Jan 2010 13:35:59 +0100

I'm forwading this to the mailing list as Volker suggested (I missed the reply-all, bad me, sorry)

The project is available on github ( git://github.com/phtrivier/ube.git ), but I'll try and reduce things if possible...

Thanks again ! 

Here are the info : 

* I'm not builing a package, I'm trying to cross-compile my own project. I managed to cross-compile fine with version 2-8, but it was a few weeks ago. I think I was already using <string.h> at the time.

* My project use automake. Here is my configure.ac

AC_INIT([ube],[0.1],[address@hidden])
AM_INIT_AUTOMAKE([foreign -Wall -Werror])
AM_GNU_GETTEXT([external])
AM_GNU_GETTEXT_VERSION([0.17])
AC_PROG_CXX
AC_PROG_RANLIB

SDL_VERSION=1.2.13
AM_PATH_SDL($SDL_VERSION, :,
            AC_MSG_ERROR([*** SDL version $SDL_VERSION not found!]))

# Check for SDL_image library
AC_SEARCH_LIBS(IMG_LoadPNG_RW, SDL_image, , 
      AC_MSG_WARN([*** Unable to find SDL_image libary with PNG support
         Are you cross compiling ?
          (http://www.libsdl.org/projects/SDL_image/)]))

AC_SEARCH_LIBS(TTF_OpenFontRW, SDL_ttf, , 
      AC_MSG_WARN([*** Unable to find SDL_ttf library.
         Are you cross compiling ?]))

AC_SEARCH_LIBS(Mix_LoadMUS, SDL_mixer, , 
             AC_MSG_WARN([*** Unable to find SDL_mixer library.
                              Are you cross compiling ? ]))    


# You might need to define --with-lua-prefix and --with-lua-suffix to use this
AX_LUA_HEADERS
AX_LUA_LIBS

AX_BOOST_BASE([1.34])

AC_CONFIG_HEADERS([config.h])
AC_CONFIG_FILES([ 
Makefile
   src/Makefile
src/common/Makefile
   src/engine/Makefile
   src/client/Makefile
po/Makefile.in
data/Makefile
data/images/Makefile
data/fonts/Makefile
data/ogg/Makefile
data/lua/Makefile
data/lua/puzzles/Makefile
])
AC_OUTPUT

* I tried getting rid of the -I/usr/include, or at least try and pass ..i686-pc-mingw32-g++/usr/include instead, but adding it to CXXFLAGS when calling 'configure' did not help because the -I/usr/include always appear first. Any idea which tool might be putting it here ? 

* I am compiling with autotools, configuring with :  

configure --prefix --host=i686-pc-mingw32 --build=i686-pc-linux-gnu 

By the way, don't be afraid to remark if you see anything really stupid, my C++ / buildings skills are very rusty (I spent the weekend fighting over linking issues because I did not remember library order matters, stuff like that ...)

Thanks for the help
PH

2010/1/12 Volker Grabsch <address@hidden>

Pierre-Henri Trivier <address@hidden> schrieb:
>  I'm getting a very strange error with both the latest sources and the 2-10
> release. When I compile a file that includes <string>, I get this error :

You might want to share more information with us. For instance,
which package do you try to build? Does it use autoconf/automake?
What's your configure.in/ac? What operating system do you use?

> i686-pc-mingw32-g++ -DHAVE_CONFIG_H -I. -I../../../../../src/common -I../..
>  -DSRCDIR=\"../../../../../src/common\" -DLUADIR=\"\" -Wall -Werror
> -I../../../../../src/common/../../include  -I/usr/include   -g -O2 -MT
> logging.o -MD -MP -MF .deps/logging.Tpo -c -o logging.o
> ../../../../../src/common/logging.cpp

 From the little information you provided, all I can say is that
 the option "-I/usr/include" should definitely not appear there.


Greets,

   Volker

--
Volker Grabsch
---<<(())>>---
Administrator
NotJustHosting GbR





--
"Message ludique et non scientifique"
"Pour votre santé, réflechissez au moins cinq fois par jour"
"L'abus de connerie est dangereux pour la santé : soyez cons avec modération"
(Ceci était un message de l'Institut National de Prévention Contre la Connerie et de Soutien aux Cons et Non-Comprenants)



--
"Message ludique et non scientifique"
"Pour votre santé, réflechissez au moins cinq fois par jour"
"L'abus de connerie est dangereux pour la santé : soyez cons avec modération"
(Ceci était un message de l'Institut National de Prévention Contre la Connerie et de Soutien aux Cons et Non-Comprenants)

reply via email to

[Prev in Thread] Current Thread [Next in Thread]