Login
Username:

Password:

Remember me



Lost Password?

Register now!

Sections

Who's Online
62 user(s) are online (43 user(s) are browsing Forums)

Members: 0
Guests: 62

more...

Headlines

 
  Register To Post  

« 1 ... 45 46 47 (48) 49 50 51 ... 72 »
Re: SDL2
Just can't stay away
Just can't stay away


See User information
SDL 2.0.14 is now released:

- https://github.com/AmigaPorts/SDL/releases
- http://os4depot.net/?function=showfile&file=library/misc/sdl2.lha

+ Many bugfixes since 2.0.12.
+ New gamecontroller mappings have been added.


@IamSONIC

Thanks, I will keep an eye on that thread.

Go to top
Re: SDL2
Just popping in
Just popping in


See User information
@Capehill

Quote:
SDL 2.0.14 is now released


Outstanding! Thank you!!

Go to top
Re: SDL2
Just popping in
Just popping in


See User information
Quote:
SDL 2.0.14 is now released


Simple but funny game using 2.0.14 available here

Go to top
Re: SDL2
Just can't stay away
Just can't stay away


See User information
@Capehill

Recompiled a couple of games here with "-use-dynld" switch and no porlems, excpet on ZGlomm it compies ok, but when runnig I get a requester:

ELF.library: Unable to resolve symbol '_ZNSt7_cxx1112basic_stringSt11char_....'

Compiling without "-use-dynld" no problems.

link line is:
ppc-amigaos-g++ zgui.o hud.o script.o iffhandler.o font.o objectgraphics.o quick.o monsterlogic.o config.o zgloom.o renderer.o menuscreen.o decrunchmania.o titlescreen.o gloommap.o gloommaths.o gamelogic.o soundhandler.o binresource.o -lSDL2_mixer -lxmp -lmikmod -lmodplug -lFLAC -lsmpeg2 -lvorbisfile -lvorbis -logg -lSDL2 -athread=native -use-dynld -o ZGloom.debug


Go to top
Re: SDL2
Just can't stay away
Just can't stay away


See User information
@jabirulo

That's because you need to use the updated libstdc++.so of the gcc version you used to compile. Note that this file is not (IIRC) backwards compatible with the one currently in SOBJS: and will break existing programs if put there, so you should include it with your program in PROGDIR:SObjs instead.

If you use static linking you avoid this problem.

Go to top
Re: SDL2
Just can't stay away
Just can't stay away


See User information
@salass00
Thx I'm using gcc version 8.4.0 (adtools build 8.4.0) to compile.

So when new full SDK is out and new/updated GCC and thus stdc++.so then there should be no such requester/problem.

Ok stick to static then.

Go to top
Re: SDL2
Just can't stay away
Just can't stay away


See User information
@jabirulo

Quote:

So when new full SDK is out and new/updated GCC and thus stdc++.so then there should be no such requester/problem.


IIRC one of the solutions that was discussed was to build the new libstdc++.so with a different name so that it can be installed next to the old version without causing any conflicts.

Go to top
Re: SDL2
Home away from home
Home away from home


See User information
@salass00

Thank you for your continuous work on sdl

People are dying.
Entire ecosystems are collapsing.
We are in the beginning of a mass extinction.
And all you can talk about is money and fairytales of eternal economic growth.
How dare you!
– Greta Thunberg
Go to top
Re: SDL2
Just can't stay away
Just can't stay away


See User information
@Raziel

I think you mean Capehill. I've only done a couple of minor fixes to the SDL port and that was years ago.

Recently I've been mainly working on updating our newlib port with code from newlib 3.1.0 leading to better C++ support among other things.

Go to top
Re: SDL2
Home away from home
Home away from home


See User information
@salass00

Gah, note to self, reread your posts

Thank you for your work on newlib...if you need someone to test shared, just shout (I feel like I told you that already)

@capehill

Thank you for your continuous work on sdl

People are dying.
Entire ecosystems are collapsing.
We are in the beginning of a mass extinction.
And all you can talk about is money and fairytales of eternal economic growth.
How dare you!
– Greta Thunberg
Go to top
Re: SDL2
Just can't stay away
Just can't stay away


See User information
@Raziel

Thank you for using and testing it :)

Go to top
Re: SDL2
Not too shy to talk
Not too shy to talk


See User information
@all

I am following multi-platform SDL2 tutorials on this page. I was able to compile and run first 5 examples. However I have a difficulty with SDL2_image.

The example basically loads a PNG file and displays on the screen.

I am compiling the examples with this following command
ppc-amigaos-g++ -w -athread=native 06_extension_libraries_and_loading_other_image_formats.cpp -o 06_SDL -lSDL2_image -lSDL2

However I get following errors:
$ ppc-amigaos-g++ -w -athread=native 06_extension_libraries_and_loading_other_image_formats.cpp -o 06_SDL -lSDL2_image -lSDL2
/usr/local/amiga/ppc-amigaos/SDK/local/newlib/lib/libSDL2_image.a(IMG_jpg.o): In function `IMG_SaveJPG_RW_jpeglib':
/home/Michael/SDL2_image-2.0.5/IMG_jpg.c:499: undefined reference to `jpeg_std_error'
/home/Michael/SDL2_image-2.0.5/IMG_jpg.c:503: undefined reference to `jpeg_CreateCompress'
/home/Michael/SDL2_image-2.0.5/IMG_jpg.c:511: undefined reference to `jpeg_set_defaults'
/home/Michael/SDL2_image-2.0.5/IMG_jpg.c:512: undefined reference to `jpeg_set_quality'
/home/Michael/SDL2_image-2.0.5/IMG_jpg.c:513: undefined reference to `jpeg_start_compress'
/home/Michael/SDL2_image-2.0.5/IMG_jpg.c:518: undefined reference to `jpeg_write_scanlines'
/home/Michael/SDL2_image-2.0.5/IMG_jpg.c:521: undefined reference to `jpeg_finish_compress'
/home/Michael/SDL2_image-2.0.5/IMG_jpg.c:522: undefined reference to `jpeg_destroy_compress'
/home/Michael/SDL2_image-2.0.5/IMG_jpg.c:499: undefined reference to `jpeg_std_error'
/home/Michael/SDL2_image-2.0.5/IMG_jpg.c:503: undefined reference to `jpeg_CreateCompress'
/usr/local/amiga/ppc-amigaos/SDK/local/newlib/lib/libSDL2_image.a(IMG_jpg.o): In function `IMG_LoadJPG_RW':
/home/Michael/SDL2_image-2.0.5/IMG_jpg.c:339: undefined reference to `jpeg_std_error'
/home/Michael/SDL2_image-2.0.5/IMG_jpg.c:353: undefined reference to `jpeg_CreateDecompress'
/usr/local/amiga/ppc-amigaos/SDK/local/newlib/lib/libSDL2_image.a(IMG_jpg.o): In function `jpeg_SDL_RW_src':
/home/Michael/SDL2_image-2.0.5/IMG_jpg.c:296: undefined reference to `jpeg_resync_to_restart'
/home/Michael/SDL2_image-2.0.5/IMG_jpg.c:296: undefined reference to `jpeg_resync_to_restart'
/usr/local/amiga/ppc-amigaos/SDK/local/newlib/lib/libSDL2_image.a(IMG_jpg.o): In function `IMG_LoadJPG_RW':
/home/Michael/SDL2_image-2.0.5/IMG_jpg.c:355: undefined reference to `jpeg_read_header'
/home/Michael/SDL2_image-2.0.5/IMG_jpg.c:381: undefined reference to `jpeg_calc_output_dimensions'
/home/Michael/SDL2_image-2.0.5/IMG_jpg.c:402: undefined reference to `jpeg_start_decompress'
/home/Michael/SDL2_image-2.0.5/IMG_jpg.c:406: undefined reference to `jpeg_read_scanlines'
/home/Michael/SDL2_image-2.0.5/IMG_jpg.c:408: undefined reference to `jpeg_finish_decompress'
/home/Michael/SDL2_image-2.0.5/IMG_jpg.c:409: undefined reference to `jpeg_destroy_decompress'
/home/Michael/SDL2_image-2.0.5/IMG_jpg.c:344: undefined reference to `jpeg_destroy_decompress'
/home/Michael/SDL2_image-2.0.5/IMG_jpg.c:361: undefined reference to `jpeg_calc_output_dimensions'
/home/Michael/SDL2_image-2.0.5/IMG_jpg.c:395: undefined reference to `jpeg_destroy_decompress'
/usr/local/amiga/ppc-amigaos/SDK/local/newlib/lib/libSDL2_image.a(IMG_png.o): In function `png_read_data':
/home/Michael/SDL2_image-2.0.5/IMG_png.c:246: undefined reference to `png_get_io_ptr'
/usr/local/amiga/ppc-amigaos/SDK/local/newlib/lib/libSDL2_image.a(IMG_png.o): In function `png_write_data':
/home/Michael/SDL2_image-2.0.5/IMG_png.c:526: undefined reference to `png_get_io_ptr'
/usr/local/amiga/ppc-amigaos/SDK/local/newlib/lib/libSDL2_image.a(IMG_png.o): In function `IMG_SavePNG_RW_libpng':
/home/Michael/SDL2_image-2.0.5/IMG_png.c:544: undefined reference to `png_create_write_struct'
/home/Michael/SDL2_image-2.0.5/IMG_png.c:550: undefined reference to `png_create_info_struct'
/home/Michael/SDL2_image-2.0.5/IMG_png.c:558: undefined reference to `png_set_longjmp_fn'
/home/Michael/SDL2_image-2.0.5/IMG_png.c:586: undefined reference to `png_set_PLTE'
/home/Michael/SDL2_image-2.0.5/IMG_png.c:593: undefined reference to `png_set_write_fn'
/home/Michael/SDL2_image-2.0.5/IMG_png.c:595: undefined reference to `png_set_IHDR'
/home/Michael/SDL2_image-2.0.5/IMG_png.c:613: undefined reference to `png_set_rows'
/home/Michael/SDL2_image-2.0.5/IMG_png.c:614: undefined reference to `png_write_png'
/home/Michael/SDL2_image-2.0.5/IMG_png.c:621: undefined reference to `png_destroy_write_struct'
/home/Michael/SDL2_image-2.0.5/IMG_png.c:552: undefined reference to `png_destroy_write_struct'
/home/Michael/SDL2_image-2.0.5/IMG_png.c:564: undefined reference to `png_destroy_write_struct'
/home/Michael/SDL2_image-2.0.5/IMG_png.c:605: undefined reference to `png_destroy_write_struct'
/home/Michael/SDL2_image-2.0.5/IMG_png.c:577: undefined reference to `png_destroy_write_struct'
/usr/local/amiga/ppc-amigaos/SDK/local/newlib/lib/libSDL2_image.a(IMG_png.o): In function `IMG_LoadPNG_RW':
/home/Michael/SDL2_image-2.0.5/IMG_png.c:283: undefined reference to `png_create_read_struct'
/home/Michael/SDL2_image-2.0.5/IMG_png.c:291: undefined reference to `png_create_info_struct'
/home/Michael/SDL2_image-2.0.5/IMG_png.c:304: undefined reference to `png_set_longjmp_fn'
/home/Michael/SDL2_image-2.0.5/IMG_png.c:458: undefined reference to `png_destroy_read_struct'
/home/Michael/SDL2_image-2.0.5/IMG_png.c:314: undefined reference to `png_set_read_fn'
/home/Michael/SDL2_image-2.0.5/IMG_png.c:317: undefined reference to `png_read_info'
/home/Michael/SDL2_image-2.0.5/IMG_png.c:318: undefined reference to `png_get_IHDR'
/home/Michael/SDL2_image-2.0.5/IMG_png.c:322: undefined reference to `png_set_strip_16'
/home/Michael/SDL2_image-2.0.5/IMG_png.c:325: undefined reference to `png_set_interlace_handling'
/home/Michael/SDL2_image-2.0.5/IMG_png.c:330: undefined reference to `png_set_packing'
/home/Michael/SDL2_image-2.0.5/IMG_png.c:334: undefined reference to `png_set_expand'
/home/Michael/SDL2_image-2.0.5/IMG_png.c:339: undefined reference to `png_get_valid'
/home/Michael/SDL2_image-2.0.5/IMG_png.c:369: undefined reference to `png_set_gray_to_rgb'
/home/Michael/SDL2_image-2.0.5/IMG_png.c:371: undefined reference to `png_read_update_info'
/home/Michael/SDL2_image-2.0.5/IMG_png.c:373: undefined reference to `png_get_IHDR'
/home/Michael/SDL2_image-2.0.5/IMG_png.c:378: undefined reference to `png_get_channels'
/home/Michael/SDL2_image-2.0.5/IMG_png.c:423: undefined reference to `png_read_image'
/home/Michael/SDL2_image-2.0.5/IMG_png.c:438: undefined reference to `png_get_PLTE'
/home/Michael/SDL2_image-2.0.5/IMG_png.c:342: undefined reference to `png_get_tRNS'
/home/Michael/SDL2_image-2.0.5/IMG_png.c:361: undefined reference to `png_set_expand'
/usr/local/amiga/ppc-amigaos/SDK/local/newlib/lib/libSDL2_image.a(IMG_tif.o): In function `IMG_LoadTIF_RW':
/home/Michael/SDL2_image-2.0.5/IMG_tif.c:179: undefined reference to `TIFFClientOpen'
/home/Michael/SDL2_image-2.0.5/IMG_tif.c:185: undefined reference to `TIFFGetField'
/home/Michael/SDL2_image-2.0.5/IMG_tif.c:186: undefined reference to `TIFFGetField'
/home/Michael/SDL2_image-2.0.5/IMG_tif.c:197: undefined reference to `TIFFReadRGBAImageOriented'
/home/Michael/SDL2_image-2.0.5/IMG_tif.c:210: undefined reference to `TIFFClose'
/home/Michael/SDL2_image-2.0.5/IMG_tif.c:200: undefined reference to `TIFFClose'
/usr/local/amiga/ppc-amigaos/SDK/local/newlib/lib/libSDL2_image.a(IMG_webp.o): In function `IMG_LoadWEBP_RW':
/home/Michael/SDL2_image-2.0.5/IMG_webp.c:201: undefined reference to `WebPGetFeaturesInternal'
/home/Michael/SDL2_image-2.0.5/IMG_webp.c:232: undefined reference to `WebPDecodeRGBAInto'
/home/Michael/SDL2_image-2.0.5/IMG_webp.c:234: undefined reference to `WebPDecodeRGBInto'
collect2: error: ld returned 1 exit status


Sinan - AmigaOS4 Beta-Tester
- AmigaOne X5000
- AmigaOne A1222
- Sam460ex
Go to top
Re: SDL2
Just can't stay away
Just can't stay away


See User information
@SinanSam460

You need to add at least -ljpeg -lpng -lTIFF -lWebP -lz. SDL2_image has lots of dependencies.

Go to top
Re: SDL2
Not too shy to talk
Not too shy to talk


See User information
@Capehill

Thanks. I have found all other dependecies on OS4Depot and copied to SDK directory on gcc10 (CygWin64 cross compiler)

ppc-amigaos-g++ -athread=native 06_extension_libraries_and_loading_other_image_formats.cpp -o 06_SDL -ljpeg -lpng -ltiff -lwebp -lz -lSDL2 -lSDL2_image

But I still get the same errors...



Sinan - AmigaOS4 Beta-Tester
- AmigaOne X5000
- AmigaOne A1222
- Sam460ex
Go to top
Re: SDL2
Just can't stay away
Just can't stay away


See User information
@SinanSam460

You should add the dependencies after -lSDL2_image, not before.

Go to top
Re: SDL2
Not too shy to talk
Not too shy to talk


See User information
@salass00

Thanks..adding -lpthreads and installing the SDK solved the problem.

ppc-amigaos-g++ -athread=native 06_extension_libraries_and_loading_other_image_formats.cpp -o 06_SDL -lSDL2 -lSDL2_image -ljpeg -lpng -ltiff -lwebp -lz -lpthread

Sinan - AmigaOS4 Beta-Tester
- AmigaOne X5000
- AmigaOne A1222
- Sam460ex
Go to top
Re: SDL2
Just can't stay away
Just can't stay away


See User information
@SinanSam460

SDL 2.0.14 is not using pthreads. Was there a reason you needed to add -ltphreads?

Go to top
Re: SDL2
Home away from home
Home away from home


See User information
@Capehill
When using -athread=native for big enough projects, -lpthreads usually need it. At least for c++ code for sure (i.e. not SDL2 related, but compiler itself)

Join us to improve dopus5!
AmigaOS4 on youtube
Go to top
Re: SDL2
Just can't stay away
Just can't stay away


See User information
@kas1e

Wasn't there a separate threading model -athread=pthreads or similar for using posix threads? (single, native and pthreads?)

There was nothing about pthreads in Sinan's linking errors, hence I don't understand why to link with pthreads?

Go to top
Re: SDL2
Home away from home
Home away from home


See User information
@Capehill
Quote:

Wasn't there a separate threading model -athread=pthreads or similar for using posix threads? (single, native and pthreads?)


Yeah, there "single" and "native" for now. Also it has "pthread", but by default that file not compiled in (need gthr-amigaos-pthread.o, which can be build separately from adtools repo, but this one luck important functions implementations, so of no real use now, see: https://github.com/sba1/adtools/issues/95)

Quote:

There was nothing about pthreads in Sinan's linking errors, hence I don't understand why to link with pthreads?


Maybe he just copy+paste, or maybe some of those 3d party libs need pthreads, and errors he has only arisen after he link with them :)

Join us to improve dopus5!
AmigaOS4 on youtube
Go to top

  Register To Post
« 1 ... 45 46 47 (48) 49 50 51 ... 72 »

 




Currently Active Users Viewing This Thread: 1 ( 0 members and 1 Anonymous Users )




Powered by XOOPS 2.0 © 2001-2023 The XOOPS Project