Re: [hatari-devel] mingw-w64

[ Thread Index | Date Index | More lists.tuxfamily.org/hatari-devel Archives ]


On Fri, Sep 20, 2013 at 7:52 PM, Nicolas Pomarède
<npomarede@xxxxxxxxxxxx> wrote:
> Le 18/09/2013 14:21, Christer Solskogen a écrit :
>
>> On Wed, Sep 18, 2013 at 2:17 PM, Nicolas Pomarède
>> <npomarede@xxxxxxxxxxxx> wrote:
>>>>
>>>>
>>>
>>> before replacing ENV{SDLDIR} by SDL_INCLUDE_DIR, I'd like to test the
>>> change
>>> on another computer I have with a different distro, just to be sure.
>>>
>>> I will commit the change if it works :)
>>
>>
>> Swett! I'm not sure, but I think that you need a sysroot aware
>> compiler for it to work. Most of the cross compilers today are, but
>> you might get in trouble if not.
>>
>>
>
> Using SDL_INCLUDE_DIR still works on my other distrib, so I could make the
> change.
>
> But I don't understand why you get problem with SDLDIR ; could you have a
> look at /usr/share/cmake/Modules/FindSDL.cmake (or wherever it is for you)
> and look at those lines at the beginning :
>
> find_path(SDL_INCLUDE_DIR SDL.h
>   HINTS
>     ENV SDLDIR
>   PATH_SUFFIXES include/SDL include/SDL12 include/SDL11 include
> )
>
> # SDL-1.1 is the name used by FreeBSD ports...
> # don't confuse it for the version number.
> find_library(SDL_LIBRARY_TEMP
>   NAMES SDL SDL-1.1
>   HINTS
>     ENV SDLDIR
>   PATH_SUFFIXES lib
> )
>
>
> Do you have the same ones ? The "hints" keyword is supposed to use
> ENV{SDLDIR} to correctly find  SDL in mingw, so no use of SDL_INCLUDE_DIR
> should be required in the toolchain file.
>
> Can you check what you have in this file ?
>

The same as you.
But I see that others are having trouble as well, as long as they are
cross compiling.I can't find the link now, but that's how I found the
solution for my problem.
If I don't use SDL_INCLUDE_DIR I get this:

-- The C compiler identification is GNU 4.8.1
-- Check for working C compiler: /opt/cross-mingw-w64/bin/x86_64-w64-mingw32-gcc
-- Check for working C compiler:
/opt/cross-mingw-w64/bin/x86_64-w64-mingw32-gcc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Performing Test MUDFLAP_AVAILABLE
-- Performing Test MUDFLAP_AVAILABLE - Failed
-- Looking for include file pthread.h
-- Looking for include file pthread.h - found
-- Looking for pthread_create
-- Looking for pthread_create - not found
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - found
-- Found Threads: TRUE
CMake Error at /usr/share/cmake-2.8/Modules/FindPackageHandleStandardArgs.cmake:108
(message):
  Could NOT find SDL (missing: SDL_INCLUDE_DIR)
Call Stack (most recent call first):
  /usr/share/cmake-2.8/Modules/FindPackageHandleStandardArgs.cmake:315
(_FPHSA_FAILURE_MESSAGE)
  /usr/share/cmake-2.8/Modules/FindSDL.cmake:176
(FIND_PACKAGE_HANDLE_STANDARD_ARGS)
  CMakeLists.txt:80 (find_package)


-- 
chs,



Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/