[SDL] contribute to wince
Stefan Klug
klug.stefan at gmx.de
Thu Jan 29 00:15:22 PST 2009
Jonathan Dearborn schrieb:
> I'm almost there, I think :)
> I just grabbed the 1.2 branch from SVN, and have some linking errors.
> Again, this looks like missing libs...
Sorry forgot patches.
One more note, the cegcc patch was applied to the cegcc headers, but
you'll have to apply it to the mingw32ce headers.
Stefan
> $ make
> /bin/sh ./libtool --mode=link /opt/mingw32ce/bin/arm-wince-mingw32ce-gcc
> -o build/libSDL.la [Lots of objects] -O2 -g -L/opt/mingw32ce/lib -lm
> -lcoredll -lmmtimer -lcoredll -lcommctrl -no-undefined -rpath
> /usr/local/lib -release 1.2 -version-info 11:2:11
> rm -fr build/.libs/libSDL.dll.a
> /opt/mingw32ce/bin/arm-wince-mingw32ce-gcc -shared [Lots of objects]
> -L/opt/mingw32ce/lib -lmmtimer -lcoredll -lcommctrl -o
> build/.libs/SDL.dll -Wl,--enable-auto-image-base -Xlinker --out-implib
> -Xlinker build/.libs/libSDL.dll.a
> Creating library file: build/.libs/libSDL.dll.a
> build/.libs/SDL_sysevents.o: In function `WinMessage':
> /home/jonny/jon/.SDL/SDL-1.2.13/SDL-1.2/./src/video/wincommon/SDL_sysevents.c:656:
> undefined reference to `AdjustWindowRect'
> /home/jonny/jon/.SDL/SDL-1.2.13/SDL-1.2/./src/video/wincommon/SDL_sysevents.c:656:
> relocation truncated to fit: ARM_26 against undefined symbol
> `AdjustWindowRect'
> /home/jonny/jon/.SDL/SDL-1.2.13/SDL-1.2/./src/video/wincommon/SDL_sysevents.c:656:
> undefined reference to `GetMenu'
> /home/jonny/jon/.SDL/SDL-1.2.13/SDL-1.2/./src/video/wincommon/SDL_sysevents.c:656:
> relocation truncated to fit: ARM_26 against undefined symbol `GetMenu'
> build/.libs/SDL_dibvideo.o: In function `DIB_ReleaseStaticColors':
> /home/jonny/jon/.SDL/SDL-1.2.13/SDL-1.2/./src/video/windib/SDL_dibvideo.c:1247:
> undefined reference to `SetSystemPaletteUse'
> /home/jonny/jon/.SDL/SDL-1.2.13/SDL-1.2/./src/video/windib/SDL_dibvideo.c:1247:
> relocation truncated to fit: ARM_26 against undefined symbol
> `SetSystemPaletteUse'
> build/.libs/SDL_dibvideo.o: In function `DIB_GrabStaticColors':
> /home/jonny/jon/.SDL/SDL-1.2.13/SDL-1.2/./src/video/windib/SDL_dibvideo.c:1234:
> undefined reference to `SetSystemPaletteUse'
> /home/jonny/jon/.SDL/SDL-1.2.13/SDL-1.2/./src/video/windib/SDL_dibvideo.c:1234:
> relocation truncated to fit: ARM_26 against undefined symbol
> `SetSystemPaletteUse'
> /home/jonny/jon/.SDL/SDL-1.2.13/SDL-1.2/./src/video/windib/SDL_dibvideo.c:1235:
> undefined reference to `GetSystemPaletteUse'
> /home/jonny/jon/.SDL/SDL-1.2.13/SDL-1.2/./src/video/windib/SDL_dibvideo.c:1235:
> relocation truncated to fit: ARM_26 against undefined symbol
> `GetSystemPaletteUse'
> /home/jonny/jon/.SDL/SDL-1.2.13/SDL-1.2/./src/video/windib/SDL_dibvideo.c:1236:
> undefined reference to `SetSystemPaletteUse'
> /home/jonny/jon/.SDL/SDL-1.2.13/SDL-1.2/./src/video/windib/SDL_dibvideo.c:1236:
> relocation truncated to fit: ARM_26 against undefined symbol
> `SetSystemPaletteUse'
> build/.libs/SDL_dibvideo.o: In function `DIB_VideoQuit':
> /home/jonny/jon/.SDL/SDL-1.2.13/SDL-1.2/./src/video/windib/SDL_dibvideo.c:1173:
> undefined reference to `ChangeDisplaySettingsExW'
> /home/jonny/jon/.SDL/SDL-1.2.13/SDL-1.2/./src/video/windib/SDL_dibvideo.c:1173:
> relocation truncated to fit: ARM_26 against undefined symbol
> `ChangeDisplaySettingsExW'
> build/.libs/SDL_dibvideo.o: In function `DIB_SetColors':
> /home/jonny/jon/.SDL/SDL-1.2.13/SDL-1.2/./src/video/windib/SDL_dibvideo.c:1011:
> undefined reference to `GetSystemPaletteUse'
> /home/jonny/jon/.SDL/SDL-1.2.13/SDL-1.2/./src/video/windib/SDL_dibvideo.c:1011:
> relocation truncated to fit: ARM_26 against undefined symbol
> `GetSystemPaletteUse'
> build/.libs/SDL_dibvideo.o: In function `DIB_VideoInit':
> /home/jonny/jon/.SDL/SDL-1.2.13/SDL-1.2/./src/video/windib/SDL_dibvideo.c:347:
> undefined reference to `ChangeDisplaySettingsExW'
> /home/jonny/jon/.SDL/SDL-1.2.13/SDL-1.2/./src/video/windib/SDL_dibvideo.c:347:
> relocation truncated to fit: ARM_26 against undefined symbol
> `ChangeDisplaySettingsExW'
> /home/jonny/jon/.SDL/SDL-1.2.13/SDL-1.2/./src/video/windib/SDL_dibvideo.c:350:
> undefined reference to `EnumDisplaySettingsW'
> /home/jonny/jon/.SDL/SDL-1.2.13/SDL-1.2/./src/video/windib/SDL_dibvideo.c:350:
> relocation truncated to fit: ARM_26 against undefined symbol
> `EnumDisplaySettingsW'
> /home/jonny/jon/.SDL/SDL-1.2.13/SDL-1.2/./src/video/windib/SDL_dibvideo.c:355:
> undefined reference to `EnumDisplaySettingsW'
> /home/jonny/jon/.SDL/SDL-1.2.13/SDL-1.2/./src/video/windib/SDL_dibvideo.c:355:
> additional relocation overflows omitted from the output
> /home/jonny/jon/.SDL/SDL-1.2.13/SDL-1.2/./src/video/windib/SDL_dibvideo.c:355:
> undefined reference to `EnumDisplaySettingsW'
> build/.libs/SDL_dibvideo.o: In function `DIB_SetVideoMode':
> /home/jonny/jon/.SDL/SDL-1.2.13/SDL-1.2/./src/video/windib/SDL_dibvideo.c:748:
> undefined reference to `IsZoomed'
> /home/jonny/jon/.SDL/SDL-1.2.13/SDL-1.2/./src/video/windib/SDL_dibvideo.c:732:
> undefined reference to `ChangeDisplaySettingsExW'
> /home/jonny/jon/.SDL/SDL-1.2.13/SDL-1.2/./src/video/windib/SDL_dibvideo.c:630:
> undefined reference to `ChangeDisplaySettingsExW'
> /home/jonny/jon/.SDL/SDL-1.2.13/SDL-1.2/./src/video/windib/SDL_dibvideo.c:668:
> undefined reference to `ChangeDisplaySettingsExW'
> /home/jonny/jon/.SDL/SDL-1.2.13/SDL-1.2/./src/video/windib/SDL_dibvideo.c:649:
> undefined reference to `ChangeDisplaySettingsExW'
> collect2: ld returned 1 exit status
> make: *** [build/libSDL.la] Error 1
>
>
> Jonny D
>
>
>
> On Wed, Jan 28, 2009 at 5:03 PM, Jonathan Dearborn <grimfang4 at gmail.com
> <mailto:grimfang4 at gmail.com>> wrote:
>
> Yep. Thanks for the patch, I'll try it right away. I was trying to
> get this all working with SDL 1.3, so I'm glad to hear that you're
> working on 1.2. I feel much better using that. Maybe once I get on
> my feet I can help with testing or something on 1.3.
>
> I would be fine with eMVC, but I've been sticking to my Linux
> computer lately. A combination of having a virus with having
> Windows' natural registry slowdown and losing the install CD helps a
> lot.
>
> Jonny D
>
>
>
> On Wed, Jan 28, 2009 at 4:52 PM, Stefan Klug <klug.stefan at gmx.de
> <mailto:klug.stefan at gmx.de>> wrote:
>
> Ilya Kasnacheev schrieb:
>
> I didn't use neither configure nor mingw.
> I'm doing PDA development on my Windows box and thus I'm
> using eMVC.
>
> libSDL have a very very good buildfile for eMVC: It actually
> just works.
>
> It is located in VisualCE.zip
>
> You can download eMVC for free from M$ website.
>
> I understand that sometimes you just want some intercourse
> with tools,
> but eMVC is good if you just want to get it going.
>
>
> I thank thats mostly personal preference.
> If SDL would be the only library I need, I would happily go that
> track.
> But keeping several open source libraries up to date turned out
> to be really hard under a MS only environment.
> I always have a virtual box with Visual Studio 2005 running for
> some legacy work, but I really like the gnu way of doing things...
>
> Stefan
>
>
>
> 2009/1/28, Jonathan Dearborn <grimfang4 at gmail.com
> <mailto:grimfang4 at gmail.com>>:
>
> My configure.in <http://configure.in> (yesterday's SVN)
> doesn't have a "wince" block... I'll try
> messing around with it. Could you post the wince block
> that you use?
>
> Jonny D
>
>
> On Wed, Jan 28, 2009 at 12:09 PM, Ilya Kasnacheev
> <ilya.kasnacheev at gmail.com
> <mailto:ilya.kasnacheev at gmail.com>
>
> wrote:
> Why don't you just use a spare windows box and
> install eMVC on it?
>
> 2009/1/28, Stefan Klug <klug.stefan at gmx.de
> <mailto:klug.stefan at gmx.de>>:
>
> Hi,
> I did not yet have the time to look at the
> patches Ilya sent, so I can't
> comment on that but here are some quick notes on
> the results you are
> getting...
>
> Hmm, I don't know what I'm doing wrong,
> exactly... I would think that
> I
> could use your libs with mingw32ce, but
> maybe not. This is where I'm
>
> at:
>
> $ /opt/mingw32ce/bin/arm-wince-mingw32ce-g++
> -o testSDL.exe testSDL.cpp
> -lSDLmain -lSDL
> Warning: .drectve `/DEFAULTLIB:"coredll.lib"
> /DEFAULTLIB:"corelibc.lib"
> ' unrecognized
>
> I don't know where these commands are coming
> from. They are commands for
> the MS linker, propably inside SDLmain.lib, to
> get autolinking with
>
> MSVC.
>
> I had lots of problems linking with import libs
> created by MSVC. My
> current way is to create as much as possible
> using the gcc based
> toolchain. If I absolutely have to link with a
> MSVC created dll, I
> create a .def file using pexports.exe and then
> creating the import lib.a
> using arm-mingw32ce-dlltool.
> Something like:
> Under Windows:
> pexports.exe SDL.dll > SDL.def
>
> under linux:
> arm-mingw32ce-dlltool -l SDL.dll.a -d SDL.def -D
> SDL.dll
>
> The resulting executable runs, but hangs
> after creating the display
> surface. Trying to fill a rect causes it to
> complain of illegal
> operations.
>
> So I should probably build my own SDL libs,
> but I'm having trouble
> there, too. I'm building with mingw32ce as
> the host:
>
> Thats the most reliable way...
>
> $ make
> /bin/sh ./build-scripts/updaterev.sh
> /bin/sh ./libtool --mode=link
> /opt/mingw32ce/bin/arm-wince-mingw32ce-gcc
> -o build/libSDL.la [Lots of object files
> here] -O2 -g
> -L/opt/mingw32ce/local/lib -lm -lunicows
> -luser32 -lgdi32 -lmsimg32
> -lwinmm -no-undefined -rpath
> /usr/local/cross-tools/i386-mingw32/lib
> -release 1.3 -version-info 0:0:0
>
> *** Warning: Linking the shared library
> build/libSDL.la against the
> non-libtool
> *** objects build/version.o is not portable!
> rm -fr build/.libs/libSDL.dll.a
> /opt/mingw32ce/bin/arm-wince-mingw32ce-gcc
> -shared [Lots of object
> files here] -L/opt/mingw32ce/local/lib
> -lunicows -luser32 -lgdi32
> -lmsimg32 -lwinmm -o build/.libs/SDL.dll
> -Wl,--enable-auto-image-base
> -Xlinker --out-implib -Xlinker
> build/.libs/libSDL.dll.a
>
> /opt/mingw32ce/lib/gcc/arm-wince-mingw32ce/4.1.0/../../../../arm-wince-mingw32ce/bin/ld:
>
> cannot find -lunicows
> collect2: ld returned 1 exit status
> make: *** [build/libSDL.la] Error 1
>
> It appears that I don't have any of the
> libs: -lunicows -luser32
> -lgdi32
> -lmsimg32 -lwinmm
> I wouldn't expect that I'd need to get more
> libs. Is there something
> I'm missing here?
>
> configure picks up the mingw section in
> configure.in <http://configure.in> so you are
> compiling for WIN32 not WinCE.
> I had that problem also (See my mail "wince/gapi
> fixes")
> You have to move the wince block before the
> mingw32 block and let it
> match *-mingw32ce. Then rerun autogen...
>
> Stefan
>
>
> On Tue, Jan 27, 2009 at 5:28 PM, Ilya Kasnacheev
> <ilya.kasnacheev at gmail.com
> <mailto:ilya.kasnacheev at gmail.com>
> <mailto:ilya.kasnacheev at gmail.com
> <mailto:ilya.kasnacheev at gmail.com>>> wrote:
>
> Okay, so I've uploaded the "epic success"
> sdl.dll to
> http://folk.poesie.ru/powder/SDL.dll
>
> Keep in mind that you'll also need
> http://folk.poesie.ru/powder/SDL.lib and
> http://folk.poesie.ru/powder/SDLMain.lib
> to make it build.
>
> I can't guarantee that that's a finalest
> version of my SDL, but if
>
> you
>
> have any troubles with it just drop their
> to the maillist.
>
> 2009/1/28, Jonathan Dearborn
> <grimfang4 at gmail.com
> <mailto:grimfang4 at gmail.com>
> <mailto:grimfang4 at gmail.com
> <mailto:grimfang4 at gmail.com>>>:
> > Ooh, I'd like SDL.dll, too, if you
> don't mind :)
> > I'm right at the point of trying to
> build SDL for WinCE.
> >
> > Jonny D
> >
> >
> > On Tue, Jan 27, 2009 at 3:51 PM, Ilya
> Kasnacheev
> > <ilya.kasnacheev at gmail.com
> <mailto:ilya.kasnacheev at gmail.com>
> <mailto:ilya.kasnacheev at gmail.com
> <mailto:ilya.kasnacheev at gmail.com>>>wrote:
> >
> >> 2009/1/22, Stefan Klug
> <klug.stefan at gmx.de <mailto:klug.stefan at gmx.de>
> <mailto:klug.stefan at gmx.de
> <mailto:klug.stefan at gmx.de>>>:
> >> > As noted in my last mail, I'd like
> to contribute to the WinCe
> Part of
> >> > SDL. I've still got some questions
> though.
> >> >
> >> > - How extreme are the changes from
> 1.2 to TRUNK? Will TRUNK
> remain
> >> > mostly stable? If the interface
> wouldn't change radically I
> would
> >> > consider switching to TRUNK as it
> seems to make more sense
> contributing
> >> > there.
> >> >
> >> > - I'm currently working on some
> fixes regarding screen
> orientation under
> >> > wince. Is there already some
> proposal for a public SDL api to
> get/set
> >> > the screen orientation? I know this
> doesn't make any sense on
> desktop
> >> > apps, but in the growing mobile
> world I think it definitely
> would make
> >> > sense...
> >> >
> >> > If there are any other things I
> should respect before posting
> patches
> >> > please tell me ;-)
> >>
> >> I think I've fixed most if not all
> screen orientation issues in
>
> my
>
> >> patches.
> >>
> >> I can mail a SDL.dll to you so you
> check if it fixes your
> problems.
> >>
> >> I have half of my patches already in
> svn and hope to bring
>
> another
>
> >> half really soon.
> >>
> _______________________________________________
> >> SDL mailing list
> >> SDL at lists.libsdl.org
> <mailto:SDL at lists.libsdl.org>
> <mailto:SDL at lists.libsdl.org
> <mailto:SDL at lists.libsdl.org>>
> >>
> http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org
> >>
> >
>
> _______________________________________________
> SDL mailing list
> SDL at lists.libsdl.org
> <mailto:SDL at lists.libsdl.org>
> <mailto:SDL at lists.libsdl.org
> <mailto:SDL at lists.libsdl.org>>
>
> http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org
>
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> SDL mailing list
> SDL at lists.libsdl.org
> <mailto:SDL at lists.libsdl.org>
> http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org
>
> _______________________________________________
> SDL mailing list
> SDL at lists.libsdl.org <mailto:SDL at lists.libsdl.org>
> http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org
>
> _______________________________________________
> SDL mailing list
> SDL at lists.libsdl.org <mailto:SDL at lists.libsdl.org>
> http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org
>
>
> _______________________________________________
> SDL mailing list
> SDL at lists.libsdl.org <mailto:SDL at lists.libsdl.org>
> http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org
>
>
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> SDL mailing list
> SDL at lists.libsdl.org
> http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: SDL_dibvideo.patch
Type: text/x-patch
Size: 1196 bytes
Desc: not available
URL: <http://lists.libsdl.org/pipermail/sdl-libsdl.org/attachments/20090129/00a878fc/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: cegcc-0.51.patch
Type: text/x-patch
Size: 2669 bytes
Desc: not available
URL: <http://lists.libsdl.org/pipermail/sdl-libsdl.org/attachments/20090129/00a878fc/attachment-0001.bin>
More information about the SDL
mailing list