summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornickysn <nickysn@3ad0048d-3df7-0310-abae-a5850022a9f2>2021-03-13 21:52:13 +0000
committernickysn <nickysn@3ad0048d-3df7-0310-abae-a5850022a9f2>2021-03-13 21:52:13 +0000
commit947f1fbab48fb5e268866fef99a7e53111d777ab (patch)
treef70710e93f6a849066a571d96dd1f72406be2788
parent1df4e051413aac8bcb360108ec82045b9fe3171e (diff)
downloadfpc-947f1fbab48fb5e268866fef99a7e53111d777ab.tar.gz
* regenerated makefiles after sync with trunk
git-svn-id: https://svn.freepascal.org/svn/fpc/branches/wasm@48951 3ad0048d-3df7-0310-abae-a5850022a9f2
-rw-r--r--compiler/Makefile2
-rw-r--r--compiler/utils/Makefile2
-rw-r--r--installer/Makefile2
-rw-r--r--packages/Makefile2
-rw-r--r--packages/a52/Makefile2
-rw-r--r--packages/ami-extra/Makefile2
-rw-r--r--packages/amunits/Makefile2
-rw-r--r--packages/arosunits/Makefile2
-rw-r--r--packages/aspell/Makefile2
-rw-r--r--packages/bfd/Makefile2
-rw-r--r--packages/bzip2/Makefile2
-rw-r--r--packages/cairo/Makefile2
-rw-r--r--packages/cdrom/Makefile2
-rw-r--r--packages/cdrom/examples/Makefile10
-rw-r--r--packages/chm/Makefile2
-rw-r--r--packages/cocoaint/Makefile2
-rw-r--r--packages/dblib/Makefile2
-rw-r--r--packages/dbus/Makefile2
-rw-r--r--packages/dbus/examples/Makefile10
-rw-r--r--packages/dts/Makefile2
-rw-r--r--packages/fastcgi/Makefile2
-rw-r--r--packages/fcl-async/Makefile2
-rw-r--r--packages/fcl-base/Makefile2
-rw-r--r--packages/fcl-base/examples/Makefile10
-rw-r--r--packages/fcl-db/Makefile2
-rw-r--r--packages/fcl-db/src/base/Makefile10
-rw-r--r--packages/fcl-db/src/codegen/Makefile10
-rw-r--r--packages/fcl-db/src/datadict/Makefile10
-rw-r--r--packages/fcl-db/src/dbase/Makefile10
-rw-r--r--packages/fcl-db/src/export/Makefile10
-rw-r--r--packages/fcl-db/src/json/Makefile10
-rw-r--r--packages/fcl-db/src/memds/Makefile10
-rw-r--r--packages/fcl-db/src/paradox/Makefile10
-rw-r--r--packages/fcl-db/src/sdf/Makefile10
-rw-r--r--packages/fcl-db/src/sql/Makefile10
-rw-r--r--packages/fcl-db/src/sqldb/Makefile10
-rw-r--r--packages/fcl-db/src/sqldb/interbase/Makefile10
-rw-r--r--packages/fcl-db/src/sqldb/mssql/Makefile10
-rw-r--r--packages/fcl-db/src/sqldb/mysql/Makefile14
-rw-r--r--packages/fcl-db/src/sqldb/odbc/Makefile10
-rw-r--r--packages/fcl-db/src/sqldb/oracle/Makefile10
-rw-r--r--packages/fcl-db/src/sqldb/postgres/Makefile10
-rw-r--r--packages/fcl-db/src/sqldb/sqlite/Makefile10
-rw-r--r--packages/fcl-db/src/sqlite/Makefile10
-rw-r--r--packages/fcl-db/tests/Makefile10
-rw-r--r--packages/fcl-extra/Makefile2
-rw-r--r--packages/fcl-extra/examples/Makefile10
-rw-r--r--packages/fcl-fpcunit/Makefile2
-rw-r--r--packages/fcl-fpcunit/src/exampletests/Makefile10
-rw-r--r--packages/fcl-fpcunit/src/tests/Makefile10
-rw-r--r--packages/fcl-image/Makefile2
-rw-r--r--packages/fcl-image/examples/Makefile10
-rw-r--r--packages/fcl-js/Makefile2
-rw-r--r--packages/fcl-json/Makefile2
-rw-r--r--packages/fcl-net/Makefile2
-rw-r--r--packages/fcl-net/examples/Makefile10
-rw-r--r--packages/fcl-passrc/Makefile2
-rw-r--r--packages/fcl-pdf/Makefile2
-rw-r--r--packages/fcl-process/Makefile2
-rw-r--r--packages/fcl-registry/Makefile2
-rw-r--r--packages/fcl-registry/tests/Makefile10
-rw-r--r--packages/fcl-report/Makefile2
-rw-r--r--packages/fcl-res/Makefile2
-rw-r--r--packages/fcl-sdo/Makefile2
-rw-r--r--packages/fcl-sound/Makefile2
-rw-r--r--packages/fcl-stl/Makefile2
-rw-r--r--packages/fcl-web/Makefile2
-rw-r--r--packages/fcl-web/src/base/Makefile10
-rw-r--r--packages/fcl-web/src/jsonrpc/Makefile10
-rw-r--r--packages/fcl-web/src/webdata/Makefile10
-rw-r--r--packages/fcl-xml/Makefile2
-rw-r--r--packages/fftw/Makefile2
-rw-r--r--packages/fpgtk/Makefile2
-rw-r--r--packages/fpgtk/examples/Makefile10
-rw-r--r--packages/fpindexer/Makefile2
-rw-r--r--packages/fpmkunit/Makefile2
-rw-r--r--packages/fppkg/Makefile2
-rw-r--r--packages/fuse/Makefile2
-rw-r--r--packages/fv/Makefile2
-rw-r--r--packages/fv/examples/Makefile10
-rw-r--r--packages/gdbint/Makefile2
-rw-r--r--packages/gdbm/Makefile2
-rw-r--r--packages/gdbm/examples/Makefile10
-rw-r--r--packages/ggi/Makefile2
-rw-r--r--packages/ggi/examples/Makefile10
-rw-r--r--packages/gmp/Makefile2
-rw-r--r--packages/gmp/examples/Makefile10
-rw-r--r--packages/gnome1/Makefile2
-rw-r--r--packages/gnutls/Makefile2
-rw-r--r--packages/googleapi/Makefile2
-rw-r--r--packages/graph/Makefile2
-rw-r--r--packages/gtk1/Makefile2
-rw-r--r--packages/gtk1/examples/Makefile10
-rw-r--r--packages/gtk1/examples/tutorial/Makefile10
-rw-r--r--packages/gtk1/src/gtkgl/Makefile10
-rw-r--r--packages/gtk2/Makefile2
-rw-r--r--packages/gtk2/examples/Makefile10
-rw-r--r--packages/gtk2/examples/filechooser/Makefile10
-rw-r--r--packages/gtk2/examples/gettingstarted/Makefile10
-rw-r--r--packages/gtk2/examples/gtk_demo/Makefile10
-rw-r--r--packages/gtk2/examples/gtkglext/Makefile10
-rw-r--r--packages/gtk2/examples/helloworld/Makefile10
-rw-r--r--packages/gtk2/examples/helloworld2/Makefile10
-rw-r--r--packages/gtk2/examples/plugins/Makefile10
-rw-r--r--packages/gtk2/examples/scribble_simple/Makefile10
-rw-r--r--packages/hash/Makefile2
-rw-r--r--packages/hash/examples/Makefile10
-rw-r--r--packages/hermes/Makefile2
-rw-r--r--packages/httpd13/Makefile2
-rw-r--r--packages/httpd20/Makefile2
-rw-r--r--packages/httpd20/examples/Makefile10
-rw-r--r--packages/httpd22/Makefile2
-rw-r--r--packages/httpd22/examples/Makefile10
-rw-r--r--packages/httpd24/Makefile2
-rw-r--r--packages/httpd24/examples/Makefile10
-rw-r--r--packages/ibase/Makefile2
-rw-r--r--packages/ibase/examples/Makefile10
-rw-r--r--packages/iconvenc/Makefile2
-rw-r--r--packages/iconvenc/examples/Makefile10
-rw-r--r--packages/ide/Makefile2
-rw-r--r--packages/ide/compiler/Makefile10
-rw-r--r--packages/ide/fakegdb/Makefile10
-rw-r--r--packages/imagemagick/Makefile2
-rw-r--r--packages/imlib/Makefile2
-rw-r--r--packages/iosxlocale/Makefile2
-rw-r--r--packages/jni/Makefile2
-rw-r--r--packages/ldap/Makefile2
-rw-r--r--packages/libc/Makefile2
-rw-r--r--packages/libcups/Makefile2
-rw-r--r--packages/libcurl/Makefile2
-rw-r--r--packages/libcurl/examples/Makefile10
-rw-r--r--packages/libenet/Makefile2
-rw-r--r--packages/libffi/Makefile2
-rw-r--r--packages/libfontconfig/Makefile2
-rw-r--r--packages/libgbafpc/Makefile2
-rw-r--r--packages/libgbafpc/examples/Makefile10
-rw-r--r--packages/libgbafpc/examples/audio/Makefile10
-rw-r--r--packages/libgbafpc/examples/audio/PlayBoyScout/Makefile10
-rw-r--r--packages/libgbafpc/examples/graphics/Makefile10
-rw-r--r--packages/libgbafpc/examples/graphics/PCXView/Makefile10
-rw-r--r--packages/libgbafpc/examples/graphics/SimpleBGScroll/Makefile10
-rw-r--r--packages/libgbafpc/examples/graphics/ansi_console/Makefile10
-rw-r--r--packages/libgbafpc/examples/template/Makefile10
-rw-r--r--packages/libgc/Makefile2
-rw-r--r--packages/libgd/Makefile2
-rw-r--r--packages/libgd/examples/Makefile10
-rw-r--r--packages/libmagic/Makefile2
-rw-r--r--packages/libmicrohttpd/Makefile2
-rw-r--r--packages/libndsfpc/Makefile2
-rw-r--r--packages/libndsfpc/examples/Makefile10
-rw-r--r--packages/libndsfpc/examples/audio/Makefile10
-rw-r--r--packages/libndsfpc/examples/audio/maxmod/Makefile10
-rw-r--r--packages/libndsfpc/examples/audio/maxmod/audio_modes/Makefile10
-rw-r--r--packages/libndsfpc/examples/audio/maxmod/basic_sound/Makefile10
-rw-r--r--packages/libndsfpc/examples/audio/maxmod/reverb/Makefile10
-rw-r--r--packages/libndsfpc/examples/audio/maxmod/song_events_example/Makefile10
-rw-r--r--packages/libndsfpc/examples/audio/maxmod/song_events_example2/Makefile10
-rw-r--r--packages/libndsfpc/examples/audio/maxmod/streaming/Makefile10
-rw-r--r--packages/libndsfpc/examples/audio/micrecord/Makefile10
-rw-r--r--packages/libndsfpc/examples/card/Makefile10
-rw-r--r--packages/libndsfpc/examples/card/eeprom/Makefile10
-rw-r--r--packages/libndsfpc/examples/debugging/Makefile10
-rw-r--r--packages/libndsfpc/examples/debugging/exceptionTest/Makefile10
-rw-r--r--packages/libndsfpc/examples/ds_motion/Makefile10
-rw-r--r--packages/libndsfpc/examples/dswifi/Makefile10
-rw-r--r--packages/libndsfpc/examples/dswifi/ap_search/Makefile10
-rw-r--r--packages/libndsfpc/examples/dswifi/autoconnect/Makefile10
-rw-r--r--packages/libndsfpc/examples/dswifi/httpget/Makefile10
-rw-r--r--packages/libndsfpc/examples/filesystem/Makefile10
-rw-r--r--packages/libndsfpc/examples/filesystem/embedded_gbfs/Makefile10
-rw-r--r--packages/libndsfpc/examples/filesystem/libfat/Makefile10
-rw-r--r--packages/libndsfpc/examples/filesystem/libfat/access_dir/Makefile10
-rw-r--r--packages/libndsfpc/examples/filesystem/libfat/access_file/Makefile10
-rw-r--r--packages/libndsfpc/examples/filesystem/libfat/libfatdir/Makefile10
-rw-r--r--packages/libndsfpc/examples/filesystem/nitrofs/Makefile10
-rw-r--r--packages/libndsfpc/examples/filesystem/nitrofs/nitrodir/Makefile10
-rw-r--r--packages/libndsfpc/examples/gl2d/2Dplus3D/Makefile10
-rw-r--r--packages/libndsfpc/examples/gl2d/Makefile10
-rw-r--r--packages/libndsfpc/examples/gl2d/dual_screen/Makefile10
-rw-r--r--packages/libndsfpc/examples/gl2d/fonts/Makefile10
-rw-r--r--packages/libndsfpc/examples/gl2d/primitives/Makefile10
-rw-r--r--packages/libndsfpc/examples/gl2d/scrolling/Makefile10
-rw-r--r--packages/libndsfpc/examples/gl2d/sprites/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/3D/3D_Both_Screens/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/3D/BoxTest/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/3D/Display_List/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/3D/Display_List_2/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/3D/Env_Mapping/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/3D/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/3D/Mixed_Text_3D/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/3D/Ortho/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/3D/Paletted_Cube/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/3D/Picking/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/3D/Simple_Quad/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/3D/Simple_Tri/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/3D/Textured_Cube/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/3D/Textured_Quad/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/3D/Toon_Shading/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/3D/nehe/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/3D/nehe/lesson01/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/3D/nehe/lesson02/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/3D/nehe/lesson03/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/3D/nehe/lesson04/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/3D/nehe/lesson05/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/3D/nehe/lesson06/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/3D/nehe/lesson07/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/3D/nehe/lesson08/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/3D/nehe/lesson09/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/3D/nehe/lesson10/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/3D/nehe/lesson10b/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/3D/nehe/lesson11/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/Backgrounds/16bit_color_bmp/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/Backgrounds/256_color_bmp/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/Backgrounds/Double_Buffer/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/Backgrounds/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/Backgrounds/all_in_one/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/Backgrounds/rotation/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/Effects/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/Effects/windows/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/Ext_Palettes/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/Ext_Palettes/backgrounds/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/Printing/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/Printing/ansi_console/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/Printing/console_windows/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/Printing/custom_font/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/Printing/print_both_screens/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/Printing/rotscale_text/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/Sprites/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/Sprites/allocation_test/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/Sprites/animate_simple/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/Sprites/bitmap_sprites/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/Sprites/fire_and_sprites/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/Sprites/simple/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/Sprites/sprite_extended_palettes/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/Sprites/sprite_rotate/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/grit/256colorTilemap/Makefile10
-rw-r--r--packages/libndsfpc/examples/graphics/grit/Makefile10
-rw-r--r--packages/libndsfpc/examples/hello_world/Makefile10
-rw-r--r--packages/libndsfpc/examples/input/Makefile10
-rw-r--r--packages/libndsfpc/examples/input/Touch_Pad/Makefile10
-rw-r--r--packages/libndsfpc/examples/input/Touch_Pad/touch_area/Makefile10
-rw-r--r--packages/libndsfpc/examples/input/Touch_Pad/touch_look/Makefile10
-rw-r--r--packages/libndsfpc/examples/input/Touch_Pad/touch_test/Makefile10
-rw-r--r--packages/libndsfpc/examples/input/keyboard/Makefile10
-rw-r--r--packages/libndsfpc/examples/input/keyboard/keyboard_async/Makefile10
-rw-r--r--packages/libndsfpc/examples/input/keyboard/keyboard_stdin/Makefile10
-rw-r--r--packages/libndsfpc/examples/time/Makefile10
-rw-r--r--packages/libndsfpc/examples/time/RealTimeClock/Makefile10
-rw-r--r--packages/libndsfpc/examples/time/stopwatch/Makefile10
-rw-r--r--packages/libndsfpc/examples/time/timercallback/Makefile10
-rw-r--r--packages/libogcfpc/Makefile2
-rw-r--r--packages/libogcfpc/examples/Makefile10
-rw-r--r--packages/libogcfpc/examples/audio/Makefile10
-rw-r--r--packages/libogcfpc/examples/audio/modplay/Makefile10
-rw-r--r--packages/libogcfpc/examples/audio/mp3player/Makefile10
-rw-r--r--packages/libogcfpc/examples/devices/Makefile10
-rw-r--r--packages/libogcfpc/examples/devices/network/Makefile10
-rw-r--r--packages/libogcfpc/examples/devices/network/sockettest/Makefile10
-rw-r--r--packages/libogcfpc/examples/devices/usbgecko/Makefile10
-rw-r--r--packages/libogcfpc/examples/devices/usbgecko/gdbstub/Makefile10
-rw-r--r--packages/libogcfpc/examples/devices/usbkeyboard/Makefile10
-rw-r--r--packages/libogcfpc/examples/devices/usbkeyboard/basic_stdin/Makefile10
-rw-r--r--packages/libogcfpc/examples/filesystem/Makefile10
-rw-r--r--packages/libogcfpc/examples/filesystem/directory/Makefile10
-rw-r--r--packages/libogcfpc/examples/graphics/Makefile10
-rw-r--r--packages/libogcfpc/examples/graphics/gx/Makefile10
-rw-r--r--packages/libogcfpc/examples/graphics/gx/gxSprites/Makefile10
-rw-r--r--packages/libogcfpc/examples/graphics/gx/neheGX/Makefile10
-rw-r--r--packages/libogcfpc/examples/graphics/gx/neheGX/lesson1/Makefile10
-rw-r--r--packages/libogcfpc/examples/graphics/gx/neheGX/lesson2/Makefile10
-rw-r--r--packages/libogcfpc/examples/graphics/gx/neheGX/lesson3/Makefile10
-rw-r--r--packages/libogcfpc/examples/graphics/gx/neheGX/lesson4/Makefile10
-rw-r--r--packages/libogcfpc/examples/graphics/gx/neheGX/lesson5/Makefile10
-rw-r--r--packages/libogcfpc/examples/graphics/gx/neheGX/lesson6/Makefile10
-rw-r--r--packages/libogcfpc/examples/graphics/gx/neheGX/lesson7/Makefile10
-rw-r--r--packages/libogcfpc/examples/graphics/gx/neheGX/lesson8/Makefile10
-rw-r--r--packages/libogcfpc/examples/graphics/gx/neheGX/lesson9/Makefile10
-rw-r--r--packages/libogcfpc/examples/graphics/gx/triangle/Makefile10
-rw-r--r--packages/libogcfpc/examples/template/Makefile10
-rw-r--r--packages/libpng/Makefile2
-rw-r--r--packages/librsvg/Makefile2
-rw-r--r--packages/libsee/Makefile2
-rw-r--r--packages/libsee/examples/Makefile10
-rw-r--r--packages/libtar/Makefile2
-rw-r--r--packages/libusb/Makefile2
-rw-r--r--packages/libvlc/Makefile2
-rw-r--r--packages/libxml/Makefile2
-rw-r--r--packages/libxml/examples/Makefile10
-rw-r--r--packages/lua/Makefile2
-rw-r--r--packages/mad/Makefile2
-rw-r--r--packages/matroska/Makefile2
-rw-r--r--packages/modplug/Makefile2
-rw-r--r--packages/morphunits/Makefile2
-rw-r--r--packages/mysql/Makefile2
-rw-r--r--packages/mysql/examples/Makefile10
-rw-r--r--packages/ncurses/Makefile2
-rw-r--r--packages/ncurses/examples/Makefile10
-rw-r--r--packages/newt/Makefile2
-rw-r--r--packages/newt/examples/Makefile10
-rw-r--r--packages/numlib/Makefile2
-rw-r--r--packages/numlib/examples/Makefile10
-rw-r--r--packages/nvapi/Makefile2
-rw-r--r--packages/objcrtl/Makefile2
-rw-r--r--packages/odata/Makefile2
-rw-r--r--packages/odbc/Makefile2
-rw-r--r--packages/odbc/examples/Makefile10
-rw-r--r--packages/oggvorbis/Makefile2
-rw-r--r--packages/openal/Makefile2
-rw-r--r--packages/openal/examples/Makefile10
-rw-r--r--packages/opencl/Makefile2
-rw-r--r--packages/opengl/Makefile2
-rw-r--r--packages/opengl/examples/Makefile10
-rw-r--r--packages/opengles/Makefile2
-rw-r--r--packages/opengles/examples/Makefile10
-rw-r--r--packages/openssl/Makefile2
-rw-r--r--packages/oracle/Makefile2
-rw-r--r--packages/oracle/examples/Makefile10
-rw-r--r--packages/os2units/Makefile2
-rw-r--r--packages/os2units/examples/Makefile10
-rw-r--r--packages/os4units/Makefile2
-rw-r--r--packages/palmunits/Makefile2
-rw-r--r--packages/pasjpeg/Makefile2
-rw-r--r--packages/pastojs/Makefile2
-rw-r--r--packages/paszlib/Makefile2
-rw-r--r--packages/paszlib/examples/Makefile10
-rw-r--r--packages/pcap/Makefile2
-rw-r--r--packages/postgres/Makefile2
-rw-r--r--packages/postgres/examples/Makefile10
-rw-r--r--packages/proj4/Makefile2
-rw-r--r--packages/ptc/Makefile2
-rw-r--r--packages/ptc/examples/Makefile10
-rw-r--r--packages/pthreads/Makefile2
-rw-r--r--packages/pxlib/Makefile2
-rw-r--r--packages/pxlib/examples/Makefile10
-rw-r--r--packages/qlunits/Makefile2
-rw-r--r--packages/regexpr/Makefile2
-rw-r--r--packages/regexpr/examples/Makefile10
-rw-r--r--packages/rexx/Makefile2
-rw-r--r--packages/rexx/examples/Makefile10
-rw-r--r--packages/rtl-console/Makefile2
-rw-r--r--packages/rtl-extra/Makefile2
-rw-r--r--packages/rtl-generics/Makefile2
-rw-r--r--packages/rtl-objpas/Makefile2
-rw-r--r--packages/rtl-unicode/Makefile2
-rw-r--r--packages/sdl/Makefile2
-rw-r--r--packages/sndfile/Makefile2
-rw-r--r--packages/sqlite/Makefile2
-rw-r--r--packages/svgalib/Makefile2
-rw-r--r--packages/svgalib/examples/Makefile10
-rw-r--r--packages/symbolic/Makefile2
-rw-r--r--packages/symbolic/examples/Makefile10
-rw-r--r--packages/syslog/Makefile2
-rw-r--r--packages/syslog/examples/Makefile10
-rw-r--r--packages/tcl/Makefile2
-rw-r--r--packages/tosunits/Makefile2
-rw-r--r--packages/tplylib/Makefile2
-rw-r--r--packages/univint/Makefile2
-rw-r--r--packages/univint/examples/Makefile10
-rw-r--r--packages/unixutil/Makefile2
-rw-r--r--packages/unzip/Makefile2
-rw-r--r--packages/users/Makefile2
-rw-r--r--packages/users/examples/Makefile10
-rw-r--r--packages/utmp/Makefile2
-rw-r--r--packages/utmp/examples/Makefile10
-rw-r--r--packages/uuid/Makefile2
-rw-r--r--packages/uuid/examples/Makefile10
-rw-r--r--packages/vcl-compat/Makefile2
-rw-r--r--packages/webidl/Makefile2
-rw-r--r--packages/winceunits/Makefile2
-rw-r--r--packages/winunits-base/Makefile2
-rw-r--r--packages/winunits-jedi/Makefile2
-rw-r--r--packages/x11/Makefile2
-rw-r--r--packages/xforms/Makefile2
-rw-r--r--packages/xforms/examples/Makefile10
-rw-r--r--packages/zlib/Makefile2
-rw-r--r--packages/zorba/Makefile2
-rw-r--r--rtl/aix/Makefile2
-rw-r--r--rtl/amiga/Makefile2
-rw-r--r--rtl/android/Makefile4
-rw-r--r--rtl/android/jvm/Makefile2
-rw-r--r--rtl/aros/Makefile2
-rw-r--r--rtl/atari/Makefile2
-rw-r--r--rtl/beos/Makefile2
-rw-r--r--rtl/darwin/Makefile2
-rw-r--r--rtl/dragonfly/Makefile2
-rw-r--r--rtl/embedded/Makefile2
-rw-r--r--rtl/emx/Makefile2
-rw-r--r--rtl/freebsd/Makefile2
-rw-r--r--rtl/freertos/Makefile2
-rw-r--r--rtl/gba/Makefile2
-rw-r--r--rtl/go32v2/Makefile2
-rw-r--r--rtl/haiku/Makefile2
-rw-r--r--rtl/java/Makefile2
-rw-r--r--rtl/macos/Makefile2
-rw-r--r--rtl/morphos/Makefile2
-rw-r--r--rtl/msdos/Makefile2
-rw-r--r--rtl/msxdos/Makefile2
-rw-r--r--rtl/nativent/Makefile2
-rw-r--r--rtl/nds/Makefile2
-rw-r--r--rtl/netbsd/Makefile2
-rw-r--r--rtl/netware/Makefile2
-rw-r--r--rtl/netwlibc/Makefile2
-rw-r--r--rtl/openbsd/Makefile2
-rw-r--r--rtl/os2/Makefile2
-rw-r--r--rtl/palmos/Makefile2
-rw-r--r--rtl/qnx/Makefile10
-rw-r--r--rtl/solaris/Makefile2
-rw-r--r--rtl/symbian/Makefile2
-rw-r--r--rtl/wasi/Makefile10
-rw-r--r--rtl/watcom/Makefile2
-rw-r--r--rtl/wii/Makefile2
-rw-r--r--rtl/win16/Makefile2
-rw-r--r--rtl/win32/Makefile2
-rw-r--r--rtl/win64/Makefile2
-rw-r--r--rtl/wince/Makefile2
-rw-r--r--rtl/zxspectrum/Makefile2
-rw-r--r--tests/Makefile2
-rw-r--r--tests/tstunits/Makefile2
-rw-r--r--tests/utils/Makefile2
-rw-r--r--tests/utils/testsuite/Makefile2
-rw-r--r--utils/Makefile2
-rw-r--r--utils/debugsvr/Makefile2
-rw-r--r--utils/debugsvr/console/Makefile10
-rw-r--r--utils/debugsvr/gtk/Makefile10
-rw-r--r--utils/dxegen/Makefile2
-rw-r--r--utils/fpcm/Makefile2
-rw-r--r--utils/fpcmkcfg/Makefile2
-rw-r--r--utils/fpcres/Makefile2
-rw-r--r--utils/fpcreslipo/Makefile2
-rw-r--r--utils/fpdoc/Makefile2
-rw-r--r--utils/fpdoc/fpde/Makefile10
-rw-r--r--utils/fpmc/Makefile2
-rw-r--r--utils/fppkg/Makefile2
-rw-r--r--utils/fprcp/Makefile2
-rw-r--r--utils/h2pas/Makefile2
-rw-r--r--utils/ihxutil/Makefile2
-rw-r--r--utils/importtl/Makefile2
-rw-r--r--utils/instantfpc/Makefile2
-rw-r--r--utils/json2pas/Makefile2
-rw-r--r--utils/mksymbian/Makefile2
-rw-r--r--utils/pas2fpm/Makefile2
-rw-r--r--utils/pas2jni/Makefile2
-rw-r--r--utils/pas2js/Makefile2
-rw-r--r--utils/pas2ut/Makefile2
-rw-r--r--utils/rmwait/Makefile2
-rw-r--r--utils/tply/Makefile2
-rw-r--r--utils/unicode/Makefile2
-rw-r--r--utils/wasmbin/Makefile10
449 files changed, 2284 insertions, 452 deletions
diff --git a/compiler/Makefile b/compiler/Makefile
index beec32d92e..6c0cc5293d 100644
--- a/compiler/Makefile
+++ b/compiler/Makefile
@@ -3762,7 +3762,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/compiler/utils/Makefile b/compiler/utils/Makefile
index d492dc6de8..62c1653283 100644
--- a/compiler/utils/Makefile
+++ b/compiler/utils/Makefile
@@ -2835,7 +2835,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/installer/Makefile b/installer/Makefile
index 78c5f26c3a..6b9d438e4e 100644
--- a/installer/Makefile
+++ b/installer/Makefile
@@ -3759,7 +3759,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/Makefile b/packages/Makefile
index fac2d2042b..22b843c63f 100644
--- a/packages/Makefile
+++ b/packages/Makefile
@@ -1604,7 +1604,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/a52/Makefile b/packages/a52/Makefile
index 534bf0ec55..d2f5abff69 100644
--- a/packages/a52/Makefile
+++ b/packages/a52/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/ami-extra/Makefile b/packages/ami-extra/Makefile
index 30a20d6a32..75a5fdb4d5 100644
--- a/packages/ami-extra/Makefile
+++ b/packages/ami-extra/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/amunits/Makefile b/packages/amunits/Makefile
index 701495ab16..56786b0236 100644
--- a/packages/amunits/Makefile
+++ b/packages/amunits/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/arosunits/Makefile b/packages/arosunits/Makefile
index 54af5bc84e..9eb04c2db7 100644
--- a/packages/arosunits/Makefile
+++ b/packages/arosunits/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/aspell/Makefile b/packages/aspell/Makefile
index 8ef3c6c4b0..2dca12823c 100644
--- a/packages/aspell/Makefile
+++ b/packages/aspell/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/bfd/Makefile b/packages/bfd/Makefile
index c083e2547e..69cbb0d77c 100644
--- a/packages/bfd/Makefile
+++ b/packages/bfd/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/bzip2/Makefile b/packages/bzip2/Makefile
index df940adb83..7e5a3d1848 100644
--- a/packages/bzip2/Makefile
+++ b/packages/bzip2/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/cairo/Makefile b/packages/cairo/Makefile
index d103fb15bc..33eb86aaa6 100644
--- a/packages/cairo/Makefile
+++ b/packages/cairo/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/cdrom/Makefile b/packages/cdrom/Makefile
index 5eb74fb05f..3506c13097 100644
--- a/packages/cdrom/Makefile
+++ b/packages/cdrom/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/cdrom/examples/Makefile b/packages/cdrom/examples/Makefile
index 443235f583..fab83e00e9 100644
--- a/packages/cdrom/examples/Makefile
+++ b/packages/cdrom/examples/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/chm/Makefile b/packages/chm/Makefile
index 840081c374..2dc98535a1 100644
--- a/packages/chm/Makefile
+++ b/packages/chm/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/cocoaint/Makefile b/packages/cocoaint/Makefile
index eac8e6456a..30a486e33d 100644
--- a/packages/cocoaint/Makefile
+++ b/packages/cocoaint/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/dblib/Makefile b/packages/dblib/Makefile
index fd8c781ee2..d3c2c65f7d 100644
--- a/packages/dblib/Makefile
+++ b/packages/dblib/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/dbus/Makefile b/packages/dbus/Makefile
index 659c23d3b4..74f9377a37 100644
--- a/packages/dbus/Makefile
+++ b/packages/dbus/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/dbus/examples/Makefile b/packages/dbus/examples/Makefile
index 96dc34d093..5012e49a91 100644
--- a/packages/dbus/examples/Makefile
+++ b/packages/dbus/examples/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/dts/Makefile b/packages/dts/Makefile
index 0a83fee90e..a21569ec80 100644
--- a/packages/dts/Makefile
+++ b/packages/dts/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fastcgi/Makefile b/packages/fastcgi/Makefile
index d4c25b71ef..6dcb3ce7ef 100644
--- a/packages/fastcgi/Makefile
+++ b/packages/fastcgi/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-async/Makefile b/packages/fcl-async/Makefile
index b7c16d9f4c..a7f667a244 100644
--- a/packages/fcl-async/Makefile
+++ b/packages/fcl-async/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-base/Makefile b/packages/fcl-base/Makefile
index 5268fd5201..81d11af510 100644
--- a/packages/fcl-base/Makefile
+++ b/packages/fcl-base/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-base/examples/Makefile b/packages/fcl-base/examples/Makefile
index 08b4ab0cc8..1687b6d897 100644
--- a/packages/fcl-base/examples/Makefile
+++ b/packages/fcl-base/examples/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3879,7 +3887,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-db/Makefile b/packages/fcl-db/Makefile
index a9f79cbb10..d5b94a6e43 100644
--- a/packages/fcl-db/Makefile
+++ b/packages/fcl-db/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-db/src/base/Makefile b/packages/fcl-db/src/base/Makefile
index a5ad8aa0f7..e7b7b564d2 100644
--- a/packages/fcl-db/src/base/Makefile
+++ b/packages/fcl-db/src/base/Makefile
@@ -1860,10 +1860,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3826,7 +3834,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-db/src/codegen/Makefile b/packages/fcl-db/src/codegen/Makefile
index b68ea72054..7ae67f97c1 100644
--- a/packages/fcl-db/src/codegen/Makefile
+++ b/packages/fcl-db/src/codegen/Makefile
@@ -1544,10 +1544,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3367,7 +3375,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-db/src/datadict/Makefile b/packages/fcl-db/src/datadict/Makefile
index 9dd1f935c8..3cb32586ea 100644
--- a/packages/fcl-db/src/datadict/Makefile
+++ b/packages/fcl-db/src/datadict/Makefile
@@ -1544,10 +1544,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3970,7 +3978,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-db/src/dbase/Makefile b/packages/fcl-db/src/dbase/Makefile
index 0b3b718b95..5787d4a395 100644
--- a/packages/fcl-db/src/dbase/Makefile
+++ b/packages/fcl-db/src/dbase/Makefile
@@ -2182,10 +2182,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4005,7 +4013,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-db/src/export/Makefile b/packages/fcl-db/src/export/Makefile
index 6ad554c806..2ecdfea5be 100644
--- a/packages/fcl-db/src/export/Makefile
+++ b/packages/fcl-db/src/export/Makefile
@@ -1544,10 +1544,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3510,7 +3518,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-db/src/json/Makefile b/packages/fcl-db/src/json/Makefile
index 4ca66558ec..42c2306ef7 100644
--- a/packages/fcl-db/src/json/Makefile
+++ b/packages/fcl-db/src/json/Makefile
@@ -914,10 +914,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2880,7 +2888,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-db/src/memds/Makefile b/packages/fcl-db/src/memds/Makefile
index 7d2ca7fa09..9f9ac33d34 100644
--- a/packages/fcl-db/src/memds/Makefile
+++ b/packages/fcl-db/src/memds/Makefile
@@ -1544,10 +1544,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3367,7 +3375,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-db/src/paradox/Makefile b/packages/fcl-db/src/paradox/Makefile
index bfcd8a1e74..1d44aa1ab4 100644
--- a/packages/fcl-db/src/paradox/Makefile
+++ b/packages/fcl-db/src/paradox/Makefile
@@ -1229,10 +1229,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3195,7 +3203,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-db/src/sdf/Makefile b/packages/fcl-db/src/sdf/Makefile
index e9502d0eb8..cfc053eeb1 100644
--- a/packages/fcl-db/src/sdf/Makefile
+++ b/packages/fcl-db/src/sdf/Makefile
@@ -1229,10 +1229,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3052,7 +3060,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-db/src/sql/Makefile b/packages/fcl-db/src/sql/Makefile
index f5f452262c..7a137f442f 100644
--- a/packages/fcl-db/src/sql/Makefile
+++ b/packages/fcl-db/src/sql/Makefile
@@ -1859,10 +1859,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3682,7 +3690,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-db/src/sqldb/Makefile b/packages/fcl-db/src/sqldb/Makefile
index 4ca5177deb..1f2fd09182 100644
--- a/packages/fcl-db/src/sqldb/Makefile
+++ b/packages/fcl-db/src/sqldb/Makefile
@@ -1667,10 +1667,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4028,7 +4036,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-db/src/sqldb/interbase/Makefile b/packages/fcl-db/src/sqldb/interbase/Makefile
index 112ac5aed5..5672bfd27a 100644
--- a/packages/fcl-db/src/sqldb/interbase/Makefile
+++ b/packages/fcl-db/src/sqldb/interbase/Makefile
@@ -1229,10 +1229,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3195,7 +3203,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-db/src/sqldb/mssql/Makefile b/packages/fcl-db/src/sqldb/mssql/Makefile
index 700087856c..c980a6c947 100644
--- a/packages/fcl-db/src/sqldb/mssql/Makefile
+++ b/packages/fcl-db/src/sqldb/mssql/Makefile
@@ -1229,10 +1229,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3052,7 +3060,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-db/src/sqldb/mysql/Makefile b/packages/fcl-db/src/sqldb/mysql/Makefile
index cc7667a394..b2dd57d6a1 100644
--- a/packages/fcl-db/src/sqldb/mysql/Makefile
+++ b/packages/fcl-db/src/sqldb/mysql/Makefile
@@ -626,7 +626,7 @@ ifeq ($(FULL_TARGET),wasm32-embedded)
override TARGET_UNITS+=mysql40conn mysql41conn mysql50conn mysql51conn mysql55conn mysql56conn mysql57conn mysql80conn
endif
ifeq ($(FULL_TARGET),wasm32-wasi)
-override TARGET_UNITS+=mysql40conn mysql41conn mysql50conn mysql51conn mysql55conn mysql56conn mysql57conn
+override TARGET_UNITS+=mysql40conn mysql41conn mysql50conn mysql51conn mysql55conn mysql56conn mysql57conn mysql80conn
endif
ifeq ($(FULL_TARGET),sparc64-linux)
override TARGET_UNITS+=mysql40conn mysql41conn mysql50conn mysql51conn mysql55conn mysql56conn mysql57conn mysql80conn
@@ -941,7 +941,7 @@ ifeq ($(FULL_TARGET),wasm32-embedded)
override TARGET_RSTS+=mysql40conn mysql41conn mysql50conn mysql51conn mysql55conn mysql56conn mysql57conn mysql80conn
endif
ifeq ($(FULL_TARGET),wasm32-wasi)
-override TARGET_RSTS+=mysql40conn mysql41conn mysql50conn mysql51conn mysql55conn mysql56conn mysql57conn
+override TARGET_RSTS+=mysql40conn mysql41conn mysql50conn mysql51conn mysql55conn mysql56conn mysql57conn mysql80conn
endif
ifeq ($(FULL_TARGET),sparc64-linux)
override TARGET_RSTS+=mysql40conn mysql41conn mysql50conn mysql51conn mysql55conn mysql56conn mysql57conn mysql80conn
@@ -1544,10 +1544,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3510,7 +3518,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-db/src/sqldb/odbc/Makefile b/packages/fcl-db/src/sqldb/odbc/Makefile
index 31480fe342..532aae84fc 100644
--- a/packages/fcl-db/src/sqldb/odbc/Makefile
+++ b/packages/fcl-db/src/sqldb/odbc/Makefile
@@ -1229,10 +1229,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3195,7 +3203,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-db/src/sqldb/oracle/Makefile b/packages/fcl-db/src/sqldb/oracle/Makefile
index 0a86c42143..10e6736aa4 100644
--- a/packages/fcl-db/src/sqldb/oracle/Makefile
+++ b/packages/fcl-db/src/sqldb/oracle/Makefile
@@ -1544,10 +1544,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3510,7 +3518,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-db/src/sqldb/postgres/Makefile b/packages/fcl-db/src/sqldb/postgres/Makefile
index 159477bb7c..66faafdfe1 100644
--- a/packages/fcl-db/src/sqldb/postgres/Makefile
+++ b/packages/fcl-db/src/sqldb/postgres/Makefile
@@ -1544,10 +1544,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3510,7 +3518,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-db/src/sqldb/sqlite/Makefile b/packages/fcl-db/src/sqldb/sqlite/Makefile
index aae51fe5e1..e4a4c8560b 100644
--- a/packages/fcl-db/src/sqldb/sqlite/Makefile
+++ b/packages/fcl-db/src/sqldb/sqlite/Makefile
@@ -1229,10 +1229,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3195,7 +3203,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-db/src/sqlite/Makefile b/packages/fcl-db/src/sqlite/Makefile
index 3f817f43cb..9cc37c8b86 100644
--- a/packages/fcl-db/src/sqlite/Makefile
+++ b/packages/fcl-db/src/sqlite/Makefile
@@ -914,10 +914,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2880,7 +2888,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-db/tests/Makefile b/packages/fcl-db/tests/Makefile
index f77d7deb24..eda2303ce8 100644
--- a/packages/fcl-db/tests/Makefile
+++ b/packages/fcl-db/tests/Makefile
@@ -1229,10 +1229,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3195,7 +3203,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-extra/Makefile b/packages/fcl-extra/Makefile
index b3cd0b9808..7ec80f482d 100644
--- a/packages/fcl-extra/Makefile
+++ b/packages/fcl-extra/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-extra/examples/Makefile b/packages/fcl-extra/examples/Makefile
index a494a86045..3a2b2bfa25 100644
--- a/packages/fcl-extra/examples/Makefile
+++ b/packages/fcl-extra/examples/Makefile
@@ -714,10 +714,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2680,7 +2688,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-fpcunit/Makefile b/packages/fcl-fpcunit/Makefile
index 674c4bd3a3..cc88aaf315 100644
--- a/packages/fcl-fpcunit/Makefile
+++ b/packages/fcl-fpcunit/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-fpcunit/src/exampletests/Makefile b/packages/fcl-fpcunit/src/exampletests/Makefile
index 2dc244c430..3c226f87a1 100644
--- a/packages/fcl-fpcunit/src/exampletests/Makefile
+++ b/packages/fcl-fpcunit/src/exampletests/Makefile
@@ -1229,10 +1229,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3338,7 +3346,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-fpcunit/src/tests/Makefile b/packages/fcl-fpcunit/src/tests/Makefile
index 6d431dbe3e..46f7d9fec9 100644
--- a/packages/fcl-fpcunit/src/tests/Makefile
+++ b/packages/fcl-fpcunit/src/tests/Makefile
@@ -1229,10 +1229,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3338,7 +3346,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-image/Makefile b/packages/fcl-image/Makefile
index 60e479ffd6..5bc608a38d 100644
--- a/packages/fcl-image/Makefile
+++ b/packages/fcl-image/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-image/examples/Makefile b/packages/fcl-image/examples/Makefile
index eec7aa7c92..a1ff063ca1 100644
--- a/packages/fcl-image/examples/Makefile
+++ b/packages/fcl-image/examples/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-js/Makefile b/packages/fcl-js/Makefile
index 58a2bfdc42..2fa5df134d 100644
--- a/packages/fcl-js/Makefile
+++ b/packages/fcl-js/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-json/Makefile b/packages/fcl-json/Makefile
index 315efd702f..b08403face 100644
--- a/packages/fcl-json/Makefile
+++ b/packages/fcl-json/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-net/Makefile b/packages/fcl-net/Makefile
index c4fed0e13c..81121d62f3 100644
--- a/packages/fcl-net/Makefile
+++ b/packages/fcl-net/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-net/examples/Makefile b/packages/fcl-net/examples/Makefile
index 528064e75f..34ca8bd4eb 100644
--- a/packages/fcl-net/examples/Makefile
+++ b/packages/fcl-net/examples/Makefile
@@ -1542,10 +1542,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3651,7 +3659,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-passrc/Makefile b/packages/fcl-passrc/Makefile
index ac093601bd..056e8499b0 100644
--- a/packages/fcl-passrc/Makefile
+++ b/packages/fcl-passrc/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-pdf/Makefile b/packages/fcl-pdf/Makefile
index 7a9e04531f..fcfc832ae0 100644
--- a/packages/fcl-pdf/Makefile
+++ b/packages/fcl-pdf/Makefile
@@ -2462,7 +2462,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-process/Makefile b/packages/fcl-process/Makefile
index 5e4f3aff74..4dd410cfe3 100644
--- a/packages/fcl-process/Makefile
+++ b/packages/fcl-process/Makefile
@@ -1604,7 +1604,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-registry/Makefile b/packages/fcl-registry/Makefile
index 7c10301dbf..58c14defb3 100644
--- a/packages/fcl-registry/Makefile
+++ b/packages/fcl-registry/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-registry/tests/Makefile b/packages/fcl-registry/tests/Makefile
index a1a882f782..d096f01a99 100644
--- a/packages/fcl-registry/tests/Makefile
+++ b/packages/fcl-registry/tests/Makefile
@@ -914,10 +914,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -1879,7 +1887,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-report/Makefile b/packages/fcl-report/Makefile
index aae71821dc..d1e8136b33 100644
--- a/packages/fcl-report/Makefile
+++ b/packages/fcl-report/Makefile
@@ -2724,7 +2724,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-res/Makefile b/packages/fcl-res/Makefile
index ac900bd4bb..38bf64264f 100644
--- a/packages/fcl-res/Makefile
+++ b/packages/fcl-res/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-sdo/Makefile b/packages/fcl-sdo/Makefile
index a792ac6eb7..330e5ba4c6 100644
--- a/packages/fcl-sdo/Makefile
+++ b/packages/fcl-sdo/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-sound/Makefile b/packages/fcl-sound/Makefile
index 431efe4f90..3b434b9aa0 100644
--- a/packages/fcl-sound/Makefile
+++ b/packages/fcl-sound/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-stl/Makefile b/packages/fcl-stl/Makefile
index 468d4e3037..7aa7fc04d4 100644
--- a/packages/fcl-stl/Makefile
+++ b/packages/fcl-stl/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-web/Makefile b/packages/fcl-web/Makefile
index 89f79a2866..5daab0ae03 100644
--- a/packages/fcl-web/Makefile
+++ b/packages/fcl-web/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-web/src/base/Makefile b/packages/fcl-web/src/base/Makefile
index cddbfb56e9..c92ddbccaa 100644
--- a/packages/fcl-web/src/base/Makefile
+++ b/packages/fcl-web/src/base/Makefile
@@ -1545,10 +1545,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4271,7 +4279,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-web/src/jsonrpc/Makefile b/packages/fcl-web/src/jsonrpc/Makefile
index 476602ccfc..d2accbf7d5 100644
--- a/packages/fcl-web/src/jsonrpc/Makefile
+++ b/packages/fcl-web/src/jsonrpc/Makefile
@@ -1230,10 +1230,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3339,7 +3347,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-web/src/webdata/Makefile b/packages/fcl-web/src/webdata/Makefile
index 892388062b..f7710d9e9e 100644
--- a/packages/fcl-web/src/webdata/Makefile
+++ b/packages/fcl-web/src/webdata/Makefile
@@ -1230,10 +1230,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3482,7 +3490,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fcl-xml/Makefile b/packages/fcl-xml/Makefile
index d1de1be91b..beeeff6565 100644
--- a/packages/fcl-xml/Makefile
+++ b/packages/fcl-xml/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fftw/Makefile b/packages/fftw/Makefile
index 584b6886e2..821a01e87a 100644
--- a/packages/fftw/Makefile
+++ b/packages/fftw/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fpgtk/Makefile b/packages/fpgtk/Makefile
index 37d11e00aa..f6b982496f 100644
--- a/packages/fpgtk/Makefile
+++ b/packages/fpgtk/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fpgtk/examples/Makefile b/packages/fpgtk/examples/Makefile
index 28480b8c17..0987d3a968 100644
--- a/packages/fpgtk/examples/Makefile
+++ b/packages/fpgtk/examples/Makefile
@@ -1227,10 +1227,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3050,7 +3058,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fpindexer/Makefile b/packages/fpindexer/Makefile
index 29807d49f7..faaecd569b 100644
--- a/packages/fpindexer/Makefile
+++ b/packages/fpindexer/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fpmkunit/Makefile b/packages/fpmkunit/Makefile
index 92e04c5ddf..16d76a7746 100644
--- a/packages/fpmkunit/Makefile
+++ b/packages/fpmkunit/Makefile
@@ -2192,7 +2192,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fppkg/Makefile b/packages/fppkg/Makefile
index ae9659a4c3..1a4100175d 100644
--- a/packages/fppkg/Makefile
+++ b/packages/fppkg/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fuse/Makefile b/packages/fuse/Makefile
index 3a22c3e093..66caaa2c3b 100644
--- a/packages/fuse/Makefile
+++ b/packages/fuse/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fv/Makefile b/packages/fv/Makefile
index dbe8a5e501..87180d085d 100644
--- a/packages/fv/Makefile
+++ b/packages/fv/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/fv/examples/Makefile b/packages/fv/examples/Makefile
index db1bb867ad..38234bca9e 100644
--- a/packages/fv/examples/Makefile
+++ b/packages/fv/examples/Makefile
@@ -1226,10 +1226,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3049,7 +3057,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/gdbint/Makefile b/packages/gdbint/Makefile
index f7d5ade01c..d7e38f2d52 100644
--- a/packages/gdbint/Makefile
+++ b/packages/gdbint/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/gdbm/Makefile b/packages/gdbm/Makefile
index 21d34652b2..b995d62492 100644
--- a/packages/gdbm/Makefile
+++ b/packages/gdbm/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/gdbm/examples/Makefile b/packages/gdbm/examples/Makefile
index 0151fede42..87ec47df60 100644
--- a/packages/gdbm/examples/Makefile
+++ b/packages/gdbm/examples/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/ggi/Makefile b/packages/ggi/Makefile
index b6610bccc9..37dae460ab 100644
--- a/packages/ggi/Makefile
+++ b/packages/ggi/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/ggi/examples/Makefile b/packages/ggi/examples/Makefile
index 828516746d..3da346523d 100644
--- a/packages/ggi/examples/Makefile
+++ b/packages/ggi/examples/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/gmp/Makefile b/packages/gmp/Makefile
index fd917ff2d3..46962a3c89 100644
--- a/packages/gmp/Makefile
+++ b/packages/gmp/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/gmp/examples/Makefile b/packages/gmp/examples/Makefile
index a6bec39d30..1d286aa295 100644
--- a/packages/gmp/examples/Makefile
+++ b/packages/gmp/examples/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/gnome1/Makefile b/packages/gnome1/Makefile
index 3712857342..0821dc7c0a 100644
--- a/packages/gnome1/Makefile
+++ b/packages/gnome1/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/gnutls/Makefile b/packages/gnutls/Makefile
index 013afa4ec4..782710506d 100644
--- a/packages/gnutls/Makefile
+++ b/packages/gnutls/Makefile
@@ -2438,7 +2438,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/googleapi/Makefile b/packages/googleapi/Makefile
index 29014eda29..1dae60cc5e 100644
--- a/packages/googleapi/Makefile
+++ b/packages/googleapi/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/graph/Makefile b/packages/graph/Makefile
index 91ef395187..4baa6dc502 100644
--- a/packages/graph/Makefile
+++ b/packages/graph/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/gtk1/Makefile b/packages/gtk1/Makefile
index 5e0f6d6ab1..3e5a9aff36 100644
--- a/packages/gtk1/Makefile
+++ b/packages/gtk1/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/gtk1/examples/Makefile b/packages/gtk1/examples/Makefile
index 495ff5f4c7..8fce8b5cc7 100644
--- a/packages/gtk1/examples/Makefile
+++ b/packages/gtk1/examples/Makefile
@@ -1542,10 +1542,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3365,7 +3373,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/gtk1/examples/tutorial/Makefile b/packages/gtk1/examples/tutorial/Makefile
index 3edfb12507..68f33807c0 100644
--- a/packages/gtk1/examples/tutorial/Makefile
+++ b/packages/gtk1/examples/tutorial/Makefile
@@ -597,10 +597,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2420,7 +2428,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/gtk1/src/gtkgl/Makefile b/packages/gtk1/src/gtkgl/Makefile
index c69cc1bbf7..59440bc45b 100644
--- a/packages/gtk1/src/gtkgl/Makefile
+++ b/packages/gtk1/src/gtkgl/Makefile
@@ -1231,10 +1231,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3054,7 +3062,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/gtk2/Makefile b/packages/gtk2/Makefile
index b708adce8b..71c3eeb2ea 100644
--- a/packages/gtk2/Makefile
+++ b/packages/gtk2/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/gtk2/examples/Makefile b/packages/gtk2/examples/Makefile
index 533fd91257..69953779cf 100644
--- a/packages/gtk2/examples/Makefile
+++ b/packages/gtk2/examples/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2878,7 +2886,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/gtk2/examples/filechooser/Makefile b/packages/gtk2/examples/filechooser/Makefile
index 2ba81185e9..7dd78b3b64 100644
--- a/packages/gtk2/examples/filechooser/Makefile
+++ b/packages/gtk2/examples/filechooser/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/gtk2/examples/gettingstarted/Makefile b/packages/gtk2/examples/gettingstarted/Makefile
index 44a0a6871a..d0ec0db58e 100644
--- a/packages/gtk2/examples/gettingstarted/Makefile
+++ b/packages/gtk2/examples/gettingstarted/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/gtk2/examples/gtk_demo/Makefile b/packages/gtk2/examples/gtk_demo/Makefile
index fb459479ef..16a996262f 100644
--- a/packages/gtk2/examples/gtk_demo/Makefile
+++ b/packages/gtk2/examples/gtk_demo/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/gtk2/examples/gtkglext/Makefile b/packages/gtk2/examples/gtkglext/Makefile
index 7471687e31..46ae976522 100644
--- a/packages/gtk2/examples/gtkglext/Makefile
+++ b/packages/gtk2/examples/gtkglext/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2878,7 +2886,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/gtk2/examples/helloworld/Makefile b/packages/gtk2/examples/helloworld/Makefile
index d2fafaf275..c9b0aca5b1 100644
--- a/packages/gtk2/examples/helloworld/Makefile
+++ b/packages/gtk2/examples/helloworld/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/gtk2/examples/helloworld2/Makefile b/packages/gtk2/examples/helloworld2/Makefile
index 63983826be..ce1f9fe96e 100644
--- a/packages/gtk2/examples/helloworld2/Makefile
+++ b/packages/gtk2/examples/helloworld2/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/gtk2/examples/plugins/Makefile b/packages/gtk2/examples/plugins/Makefile
index 40a0e82550..1065fe92fc 100644
--- a/packages/gtk2/examples/plugins/Makefile
+++ b/packages/gtk2/examples/plugins/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/gtk2/examples/scribble_simple/Makefile b/packages/gtk2/examples/scribble_simple/Makefile
index c58564fddb..8597f2dd44 100644
--- a/packages/gtk2/examples/scribble_simple/Makefile
+++ b/packages/gtk2/examples/scribble_simple/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/hash/Makefile b/packages/hash/Makefile
index 438da3152d..4f7c9c6a0d 100644
--- a/packages/hash/Makefile
+++ b/packages/hash/Makefile
@@ -1604,7 +1604,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/hash/examples/Makefile b/packages/hash/examples/Makefile
index bd77ea07da..03b7c8a7d6 100644
--- a/packages/hash/examples/Makefile
+++ b/packages/hash/examples/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2878,7 +2886,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/hermes/Makefile b/packages/hermes/Makefile
index f0b61ee03d..e045f4d243 100644
--- a/packages/hermes/Makefile
+++ b/packages/hermes/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/httpd13/Makefile b/packages/httpd13/Makefile
index 325ac43df4..d3899f372b 100644
--- a/packages/httpd13/Makefile
+++ b/packages/httpd13/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/httpd20/Makefile b/packages/httpd20/Makefile
index 592f7c442c..0d70e42504 100644
--- a/packages/httpd20/Makefile
+++ b/packages/httpd20/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/httpd20/examples/Makefile b/packages/httpd20/examples/Makefile
index 712dca8221..d3173ae166 100644
--- a/packages/httpd20/examples/Makefile
+++ b/packages/httpd20/examples/Makefile
@@ -1227,10 +1227,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3050,7 +3058,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/httpd22/Makefile b/packages/httpd22/Makefile
index 07e8ea8fd2..878625e0dd 100644
--- a/packages/httpd22/Makefile
+++ b/packages/httpd22/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/httpd22/examples/Makefile b/packages/httpd22/examples/Makefile
index 7d6f7376a7..0cbfc32b52 100644
--- a/packages/httpd22/examples/Makefile
+++ b/packages/httpd22/examples/Makefile
@@ -1227,10 +1227,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3050,7 +3058,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/httpd24/Makefile b/packages/httpd24/Makefile
index f87cf06397..2f5fd94725 100644
--- a/packages/httpd24/Makefile
+++ b/packages/httpd24/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/httpd24/examples/Makefile b/packages/httpd24/examples/Makefile
index ae30cf3bab..97a499469d 100644
--- a/packages/httpd24/examples/Makefile
+++ b/packages/httpd24/examples/Makefile
@@ -1227,10 +1227,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3050,7 +3058,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/ibase/Makefile b/packages/ibase/Makefile
index 80c84cefb0..a547c2c628 100644
--- a/packages/ibase/Makefile
+++ b/packages/ibase/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/ibase/examples/Makefile b/packages/ibase/examples/Makefile
index ca97f6f440..76ef53337f 100644
--- a/packages/ibase/examples/Makefile
+++ b/packages/ibase/examples/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/iconvenc/Makefile b/packages/iconvenc/Makefile
index 0d3064e9b7..151b6074e4 100644
--- a/packages/iconvenc/Makefile
+++ b/packages/iconvenc/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/iconvenc/examples/Makefile b/packages/iconvenc/examples/Makefile
index bd75c0c3a8..a1e3bdb121 100644
--- a/packages/iconvenc/examples/Makefile
+++ b/packages/iconvenc/examples/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/ide/Makefile b/packages/ide/Makefile
index 3a07fcbf58..bfe19caa63 100644
--- a/packages/ide/Makefile
+++ b/packages/ide/Makefile
@@ -2915,7 +2915,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/ide/compiler/Makefile b/packages/ide/compiler/Makefile
index b639044445..06abe87ed1 100644
--- a/packages/ide/compiler/Makefile
+++ b/packages/ide/compiler/Makefile
@@ -1896,10 +1896,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3719,7 +3727,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/ide/fakegdb/Makefile b/packages/ide/fakegdb/Makefile
index 2c0ae32a8e..8b8655962b 100644
--- a/packages/ide/fakegdb/Makefile
+++ b/packages/ide/fakegdb/Makefile
@@ -914,10 +914,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -1879,7 +1887,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/imagemagick/Makefile b/packages/imagemagick/Makefile
index 3ed273089e..09eaeff7ed 100644
--- a/packages/imagemagick/Makefile
+++ b/packages/imagemagick/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/imlib/Makefile b/packages/imlib/Makefile
index be8c616904..a1909e34fa 100644
--- a/packages/imlib/Makefile
+++ b/packages/imlib/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/iosxlocale/Makefile b/packages/iosxlocale/Makefile
index f4f15b84aa..8803b7fd8c 100644
--- a/packages/iosxlocale/Makefile
+++ b/packages/iosxlocale/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/jni/Makefile b/packages/jni/Makefile
index 42d02da46e..b4aba60ea8 100644
--- a/packages/jni/Makefile
+++ b/packages/jni/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/ldap/Makefile b/packages/ldap/Makefile
index 0e15797b9f..eb4805b9a8 100644
--- a/packages/ldap/Makefile
+++ b/packages/ldap/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libc/Makefile b/packages/libc/Makefile
index 1a92afdea8..9491583bf8 100644
--- a/packages/libc/Makefile
+++ b/packages/libc/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libcups/Makefile b/packages/libcups/Makefile
index 7ce4fe6c12..5b602c5d22 100644
--- a/packages/libcups/Makefile
+++ b/packages/libcups/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libcurl/Makefile b/packages/libcurl/Makefile
index 0343dd1f6d..1f890948ee 100644
--- a/packages/libcurl/Makefile
+++ b/packages/libcurl/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libcurl/examples/Makefile b/packages/libcurl/examples/Makefile
index 71967857bb..f2fd51c8c8 100644
--- a/packages/libcurl/examples/Makefile
+++ b/packages/libcurl/examples/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libenet/Makefile b/packages/libenet/Makefile
index b0213906aa..403466dab6 100644
--- a/packages/libenet/Makefile
+++ b/packages/libenet/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libffi/Makefile b/packages/libffi/Makefile
index 00d0a73bee..151cdaee48 100644
--- a/packages/libffi/Makefile
+++ b/packages/libffi/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libfontconfig/Makefile b/packages/libfontconfig/Makefile
index a93361098f..c65b6dd9d6 100644
--- a/packages/libfontconfig/Makefile
+++ b/packages/libfontconfig/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libgbafpc/Makefile b/packages/libgbafpc/Makefile
index 351d9fff43..ffd1d6cec8 100644
--- a/packages/libgbafpc/Makefile
+++ b/packages/libgbafpc/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libgbafpc/examples/Makefile b/packages/libgbafpc/examples/Makefile
index 582f0813ac..aa7d142250 100644
--- a/packages/libgbafpc/examples/Makefile
+++ b/packages/libgbafpc/examples/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libgbafpc/examples/audio/Makefile b/packages/libgbafpc/examples/audio/Makefile
index 1850f6cb09..0e3bd08d82 100644
--- a/packages/libgbafpc/examples/audio/Makefile
+++ b/packages/libgbafpc/examples/audio/Makefile
@@ -914,10 +914,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2737,7 +2745,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libgbafpc/examples/audio/PlayBoyScout/Makefile b/packages/libgbafpc/examples/audio/PlayBoyScout/Makefile
index 7938a3bc47..1e925e201f 100644
--- a/packages/libgbafpc/examples/audio/PlayBoyScout/Makefile
+++ b/packages/libgbafpc/examples/audio/PlayBoyScout/Makefile
@@ -1549,10 +1549,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3372,7 +3380,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libgbafpc/examples/graphics/Makefile b/packages/libgbafpc/examples/graphics/Makefile
index 553947f1b8..0d3664302a 100644
--- a/packages/libgbafpc/examples/graphics/Makefile
+++ b/packages/libgbafpc/examples/graphics/Makefile
@@ -914,10 +914,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2737,7 +2745,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libgbafpc/examples/graphics/PCXView/Makefile b/packages/libgbafpc/examples/graphics/PCXView/Makefile
index bb5e889ae3..7238f17143 100644
--- a/packages/libgbafpc/examples/graphics/PCXView/Makefile
+++ b/packages/libgbafpc/examples/graphics/PCXView/Makefile
@@ -1549,10 +1549,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3372,7 +3380,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libgbafpc/examples/graphics/SimpleBGScroll/Makefile b/packages/libgbafpc/examples/graphics/SimpleBGScroll/Makefile
index 672a8b9f16..d69263430f 100644
--- a/packages/libgbafpc/examples/graphics/SimpleBGScroll/Makefile
+++ b/packages/libgbafpc/examples/graphics/SimpleBGScroll/Makefile
@@ -1549,10 +1549,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3372,7 +3380,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libgbafpc/examples/graphics/ansi_console/Makefile b/packages/libgbafpc/examples/graphics/ansi_console/Makefile
index fc33f0a176..87c9d3f1e6 100644
--- a/packages/libgbafpc/examples/graphics/ansi_console/Makefile
+++ b/packages/libgbafpc/examples/graphics/ansi_console/Makefile
@@ -1549,10 +1549,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3372,7 +3380,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libgbafpc/examples/template/Makefile b/packages/libgbafpc/examples/template/Makefile
index edf4fc7e88..056a91d800 100644
--- a/packages/libgbafpc/examples/template/Makefile
+++ b/packages/libgbafpc/examples/template/Makefile
@@ -1551,10 +1551,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3374,7 +3382,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libgc/Makefile b/packages/libgc/Makefile
index 6728171c7c..9216b2a1e1 100644
--- a/packages/libgc/Makefile
+++ b/packages/libgc/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libgd/Makefile b/packages/libgd/Makefile
index edae3630d8..2b82f9cfe2 100644
--- a/packages/libgd/Makefile
+++ b/packages/libgd/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libgd/examples/Makefile b/packages/libgd/examples/Makefile
index 8d6b470cd4..cb3156aa04 100644
--- a/packages/libgd/examples/Makefile
+++ b/packages/libgd/examples/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libmagic/Makefile b/packages/libmagic/Makefile
index 15f1722e47..51bd88db14 100644
--- a/packages/libmagic/Makefile
+++ b/packages/libmagic/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libmicrohttpd/Makefile b/packages/libmicrohttpd/Makefile
index 5e624a252c..047ca3beed 100644
--- a/packages/libmicrohttpd/Makefile
+++ b/packages/libmicrohttpd/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/Makefile b/packages/libndsfpc/Makefile
index beba65335b..29273b9087 100644
--- a/packages/libndsfpc/Makefile
+++ b/packages/libndsfpc/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/Makefile b/packages/libndsfpc/examples/Makefile
index 11301bb62b..be3568a109 100644
--- a/packages/libndsfpc/examples/Makefile
+++ b/packages/libndsfpc/examples/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/audio/Makefile b/packages/libndsfpc/examples/audio/Makefile
index 98dc2ab236..d6707c7d59 100644
--- a/packages/libndsfpc/examples/audio/Makefile
+++ b/packages/libndsfpc/examples/audio/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/audio/maxmod/Makefile b/packages/libndsfpc/examples/audio/maxmod/Makefile
index 8cf419aef3..faaf5cef7d 100644
--- a/packages/libndsfpc/examples/audio/maxmod/Makefile
+++ b/packages/libndsfpc/examples/audio/maxmod/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/audio/maxmod/audio_modes/Makefile b/packages/libndsfpc/examples/audio/maxmod/audio_modes/Makefile
index a38f901995..8b6d189022 100644
--- a/packages/libndsfpc/examples/audio/maxmod/audio_modes/Makefile
+++ b/packages/libndsfpc/examples/audio/maxmod/audio_modes/Makefile
@@ -2814,10 +2814,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4637,7 +4645,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/audio/maxmod/basic_sound/Makefile b/packages/libndsfpc/examples/audio/maxmod/basic_sound/Makefile
index 70edd1a653..f8d1b8b32b 100644
--- a/packages/libndsfpc/examples/audio/maxmod/basic_sound/Makefile
+++ b/packages/libndsfpc/examples/audio/maxmod/basic_sound/Makefile
@@ -2814,10 +2814,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4637,7 +4645,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/audio/maxmod/reverb/Makefile b/packages/libndsfpc/examples/audio/maxmod/reverb/Makefile
index f011aaf37e..6e4c8d30d2 100644
--- a/packages/libndsfpc/examples/audio/maxmod/reverb/Makefile
+++ b/packages/libndsfpc/examples/audio/maxmod/reverb/Makefile
@@ -2814,10 +2814,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4637,7 +4645,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/audio/maxmod/song_events_example/Makefile b/packages/libndsfpc/examples/audio/maxmod/song_events_example/Makefile
index 980d78b434..891b43056d 100644
--- a/packages/libndsfpc/examples/audio/maxmod/song_events_example/Makefile
+++ b/packages/libndsfpc/examples/audio/maxmod/song_events_example/Makefile
@@ -2814,10 +2814,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4637,7 +4645,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/audio/maxmod/song_events_example2/Makefile b/packages/libndsfpc/examples/audio/maxmod/song_events_example2/Makefile
index a27f4b08d2..b2a5d60b29 100644
--- a/packages/libndsfpc/examples/audio/maxmod/song_events_example2/Makefile
+++ b/packages/libndsfpc/examples/audio/maxmod/song_events_example2/Makefile
@@ -2814,10 +2814,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4637,7 +4645,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/audio/maxmod/streaming/Makefile b/packages/libndsfpc/examples/audio/maxmod/streaming/Makefile
index fa64d379e2..b00ca5be71 100644
--- a/packages/libndsfpc/examples/audio/maxmod/streaming/Makefile
+++ b/packages/libndsfpc/examples/audio/maxmod/streaming/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/audio/micrecord/Makefile b/packages/libndsfpc/examples/audio/micrecord/Makefile
index 8c030370d2..c44d121d67 100644
--- a/packages/libndsfpc/examples/audio/micrecord/Makefile
+++ b/packages/libndsfpc/examples/audio/micrecord/Makefile
@@ -2497,10 +2497,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4320,7 +4328,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/card/Makefile b/packages/libndsfpc/examples/card/Makefile
index 1a7db4f366..3fd86494ff 100644
--- a/packages/libndsfpc/examples/card/Makefile
+++ b/packages/libndsfpc/examples/card/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/card/eeprom/Makefile b/packages/libndsfpc/examples/card/eeprom/Makefile
index cf87ed6f32..c707b3d8ef 100644
--- a/packages/libndsfpc/examples/card/eeprom/Makefile
+++ b/packages/libndsfpc/examples/card/eeprom/Makefile
@@ -2497,10 +2497,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4320,7 +4328,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/debugging/Makefile b/packages/libndsfpc/examples/debugging/Makefile
index f019b3f110..4679954187 100644
--- a/packages/libndsfpc/examples/debugging/Makefile
+++ b/packages/libndsfpc/examples/debugging/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/debugging/exceptionTest/Makefile b/packages/libndsfpc/examples/debugging/exceptionTest/Makefile
index 8c89d4d666..a516655163 100644
--- a/packages/libndsfpc/examples/debugging/exceptionTest/Makefile
+++ b/packages/libndsfpc/examples/debugging/exceptionTest/Makefile
@@ -2497,10 +2497,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4320,7 +4328,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/ds_motion/Makefile b/packages/libndsfpc/examples/ds_motion/Makefile
index 366ec6fac0..f4894fed15 100644
--- a/packages/libndsfpc/examples/ds_motion/Makefile
+++ b/packages/libndsfpc/examples/ds_motion/Makefile
@@ -2497,10 +2497,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4320,7 +4328,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/dswifi/Makefile b/packages/libndsfpc/examples/dswifi/Makefile
index 6b61ca7133..41eaf00cc5 100644
--- a/packages/libndsfpc/examples/dswifi/Makefile
+++ b/packages/libndsfpc/examples/dswifi/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/dswifi/ap_search/Makefile b/packages/libndsfpc/examples/dswifi/ap_search/Makefile
index 100845b216..b9651b38ae 100644
--- a/packages/libndsfpc/examples/dswifi/ap_search/Makefile
+++ b/packages/libndsfpc/examples/dswifi/ap_search/Makefile
@@ -2497,10 +2497,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4320,7 +4328,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/dswifi/autoconnect/Makefile b/packages/libndsfpc/examples/dswifi/autoconnect/Makefile
index 515c4af666..7713112801 100644
--- a/packages/libndsfpc/examples/dswifi/autoconnect/Makefile
+++ b/packages/libndsfpc/examples/dswifi/autoconnect/Makefile
@@ -2497,10 +2497,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4320,7 +4328,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/dswifi/httpget/Makefile b/packages/libndsfpc/examples/dswifi/httpget/Makefile
index b2c851e34f..4a9f216534 100644
--- a/packages/libndsfpc/examples/dswifi/httpget/Makefile
+++ b/packages/libndsfpc/examples/dswifi/httpget/Makefile
@@ -2497,10 +2497,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4320,7 +4328,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/filesystem/Makefile b/packages/libndsfpc/examples/filesystem/Makefile
index 79f591095e..81bc476e97 100644
--- a/packages/libndsfpc/examples/filesystem/Makefile
+++ b/packages/libndsfpc/examples/filesystem/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/filesystem/embedded_gbfs/Makefile b/packages/libndsfpc/examples/filesystem/embedded_gbfs/Makefile
index 9e4b848f9c..55c8e6e9dc 100644
--- a/packages/libndsfpc/examples/filesystem/embedded_gbfs/Makefile
+++ b/packages/libndsfpc/examples/filesystem/embedded_gbfs/Makefile
@@ -2813,10 +2813,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4636,7 +4644,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/filesystem/libfat/Makefile b/packages/libndsfpc/examples/filesystem/libfat/Makefile
index d24e307ae8..9746dbb729 100644
--- a/packages/libndsfpc/examples/filesystem/libfat/Makefile
+++ b/packages/libndsfpc/examples/filesystem/libfat/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/filesystem/libfat/access_dir/Makefile b/packages/libndsfpc/examples/filesystem/libfat/access_dir/Makefile
index ee44560b11..a7c410155f 100644
--- a/packages/libndsfpc/examples/filesystem/libfat/access_dir/Makefile
+++ b/packages/libndsfpc/examples/filesystem/libfat/access_dir/Makefile
@@ -2497,10 +2497,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4320,7 +4328,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/filesystem/libfat/access_file/Makefile b/packages/libndsfpc/examples/filesystem/libfat/access_file/Makefile
index ab6f86a123..c4eb773e9f 100644
--- a/packages/libndsfpc/examples/filesystem/libfat/access_file/Makefile
+++ b/packages/libndsfpc/examples/filesystem/libfat/access_file/Makefile
@@ -2497,10 +2497,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4320,7 +4328,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/filesystem/libfat/libfatdir/Makefile b/packages/libndsfpc/examples/filesystem/libfat/libfatdir/Makefile
index d5e93dcaea..59d8061efa 100644
--- a/packages/libndsfpc/examples/filesystem/libfat/libfatdir/Makefile
+++ b/packages/libndsfpc/examples/filesystem/libfat/libfatdir/Makefile
@@ -2497,10 +2497,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4320,7 +4328,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/filesystem/nitrofs/Makefile b/packages/libndsfpc/examples/filesystem/nitrofs/Makefile
index 62bd57edc3..8742425c0f 100644
--- a/packages/libndsfpc/examples/filesystem/nitrofs/Makefile
+++ b/packages/libndsfpc/examples/filesystem/nitrofs/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/filesystem/nitrofs/nitrodir/Makefile b/packages/libndsfpc/examples/filesystem/nitrofs/nitrodir/Makefile
index 2824f8fa9b..2df43a4698 100644
--- a/packages/libndsfpc/examples/filesystem/nitrofs/nitrodir/Makefile
+++ b/packages/libndsfpc/examples/filesystem/nitrofs/nitrodir/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/gl2d/2Dplus3D/Makefile b/packages/libndsfpc/examples/gl2d/2Dplus3D/Makefile
index 6b7c09d68e..da58415366 100644
--- a/packages/libndsfpc/examples/gl2d/2Dplus3D/Makefile
+++ b/packages/libndsfpc/examples/gl2d/2Dplus3D/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/gl2d/Makefile b/packages/libndsfpc/examples/gl2d/Makefile
index 123f019cb6..9fd0e5adaf 100644
--- a/packages/libndsfpc/examples/gl2d/Makefile
+++ b/packages/libndsfpc/examples/gl2d/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/gl2d/dual_screen/Makefile b/packages/libndsfpc/examples/gl2d/dual_screen/Makefile
index e3f4abc1b9..127357f6d5 100644
--- a/packages/libndsfpc/examples/gl2d/dual_screen/Makefile
+++ b/packages/libndsfpc/examples/gl2d/dual_screen/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/gl2d/fonts/Makefile b/packages/libndsfpc/examples/gl2d/fonts/Makefile
index 04e6dd23d9..b1f7b84f0f 100644
--- a/packages/libndsfpc/examples/gl2d/fonts/Makefile
+++ b/packages/libndsfpc/examples/gl2d/fonts/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/gl2d/primitives/Makefile b/packages/libndsfpc/examples/gl2d/primitives/Makefile
index d5497063a9..e61ef3b679 100644
--- a/packages/libndsfpc/examples/gl2d/primitives/Makefile
+++ b/packages/libndsfpc/examples/gl2d/primitives/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/gl2d/scrolling/Makefile b/packages/libndsfpc/examples/gl2d/scrolling/Makefile
index c84a2abd5b..ab2482da21 100644
--- a/packages/libndsfpc/examples/gl2d/scrolling/Makefile
+++ b/packages/libndsfpc/examples/gl2d/scrolling/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/gl2d/sprites/Makefile b/packages/libndsfpc/examples/gl2d/sprites/Makefile
index 23b9610c39..100198065b 100644
--- a/packages/libndsfpc/examples/gl2d/sprites/Makefile
+++ b/packages/libndsfpc/examples/gl2d/sprites/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/3D/3D_Both_Screens/Makefile b/packages/libndsfpc/examples/graphics/3D/3D_Both_Screens/Makefile
index b8abd6fe1f..88a4cbc8eb 100644
--- a/packages/libndsfpc/examples/graphics/3D/3D_Both_Screens/Makefile
+++ b/packages/libndsfpc/examples/graphics/3D/3D_Both_Screens/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/3D/BoxTest/Makefile b/packages/libndsfpc/examples/graphics/3D/BoxTest/Makefile
index 968d6537e1..19cf4a6c12 100644
--- a/packages/libndsfpc/examples/graphics/3D/BoxTest/Makefile
+++ b/packages/libndsfpc/examples/graphics/3D/BoxTest/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/3D/Display_List/Makefile b/packages/libndsfpc/examples/graphics/3D/Display_List/Makefile
index 24bc8adbd1..1f5f0d5d21 100644
--- a/packages/libndsfpc/examples/graphics/3D/Display_List/Makefile
+++ b/packages/libndsfpc/examples/graphics/3D/Display_List/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/3D/Display_List_2/Makefile b/packages/libndsfpc/examples/graphics/3D/Display_List_2/Makefile
index 5cd34c6361..dd891bf9c6 100644
--- a/packages/libndsfpc/examples/graphics/3D/Display_List_2/Makefile
+++ b/packages/libndsfpc/examples/graphics/3D/Display_List_2/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/3D/Env_Mapping/Makefile b/packages/libndsfpc/examples/graphics/3D/Env_Mapping/Makefile
index 63d256cb15..ab4a67d836 100644
--- a/packages/libndsfpc/examples/graphics/3D/Env_Mapping/Makefile
+++ b/packages/libndsfpc/examples/graphics/3D/Env_Mapping/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/3D/Makefile b/packages/libndsfpc/examples/graphics/3D/Makefile
index be4dc10743..f95d5e8c6e 100644
--- a/packages/libndsfpc/examples/graphics/3D/Makefile
+++ b/packages/libndsfpc/examples/graphics/3D/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/3D/Mixed_Text_3D/Makefile b/packages/libndsfpc/examples/graphics/3D/Mixed_Text_3D/Makefile
index 2d9f9dee5d..072d391bfd 100644
--- a/packages/libndsfpc/examples/graphics/3D/Mixed_Text_3D/Makefile
+++ b/packages/libndsfpc/examples/graphics/3D/Mixed_Text_3D/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/3D/Ortho/Makefile b/packages/libndsfpc/examples/graphics/3D/Ortho/Makefile
index dcdd7bf6d8..24fad8830e 100644
--- a/packages/libndsfpc/examples/graphics/3D/Ortho/Makefile
+++ b/packages/libndsfpc/examples/graphics/3D/Ortho/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/3D/Paletted_Cube/Makefile b/packages/libndsfpc/examples/graphics/3D/Paletted_Cube/Makefile
index ca473bea42..0d4a62df00 100644
--- a/packages/libndsfpc/examples/graphics/3D/Paletted_Cube/Makefile
+++ b/packages/libndsfpc/examples/graphics/3D/Paletted_Cube/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/3D/Picking/Makefile b/packages/libndsfpc/examples/graphics/3D/Picking/Makefile
index 0832e6c39d..7bd0cde4b9 100644
--- a/packages/libndsfpc/examples/graphics/3D/Picking/Makefile
+++ b/packages/libndsfpc/examples/graphics/3D/Picking/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/3D/Simple_Quad/Makefile b/packages/libndsfpc/examples/graphics/3D/Simple_Quad/Makefile
index d544851cdc..ac2a4e2788 100644
--- a/packages/libndsfpc/examples/graphics/3D/Simple_Quad/Makefile
+++ b/packages/libndsfpc/examples/graphics/3D/Simple_Quad/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/3D/Simple_Tri/Makefile b/packages/libndsfpc/examples/graphics/3D/Simple_Tri/Makefile
index 2296fbf882..5544fe91c8 100644
--- a/packages/libndsfpc/examples/graphics/3D/Simple_Tri/Makefile
+++ b/packages/libndsfpc/examples/graphics/3D/Simple_Tri/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/3D/Textured_Cube/Makefile b/packages/libndsfpc/examples/graphics/3D/Textured_Cube/Makefile
index f162780391..08ac9b2503 100644
--- a/packages/libndsfpc/examples/graphics/3D/Textured_Cube/Makefile
+++ b/packages/libndsfpc/examples/graphics/3D/Textured_Cube/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/3D/Textured_Quad/Makefile b/packages/libndsfpc/examples/graphics/3D/Textured_Quad/Makefile
index 292468287f..0438df282e 100644
--- a/packages/libndsfpc/examples/graphics/3D/Textured_Quad/Makefile
+++ b/packages/libndsfpc/examples/graphics/3D/Textured_Quad/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/3D/Toon_Shading/Makefile b/packages/libndsfpc/examples/graphics/3D/Toon_Shading/Makefile
index e11149d1e1..644f5510e5 100644
--- a/packages/libndsfpc/examples/graphics/3D/Toon_Shading/Makefile
+++ b/packages/libndsfpc/examples/graphics/3D/Toon_Shading/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/3D/nehe/Makefile b/packages/libndsfpc/examples/graphics/3D/nehe/Makefile
index 7f564d2fb6..9d2c9ed96a 100644
--- a/packages/libndsfpc/examples/graphics/3D/nehe/Makefile
+++ b/packages/libndsfpc/examples/graphics/3D/nehe/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/3D/nehe/lesson01/Makefile b/packages/libndsfpc/examples/graphics/3D/nehe/lesson01/Makefile
index e86e60cb9a..48dcdfbed1 100644
--- a/packages/libndsfpc/examples/graphics/3D/nehe/lesson01/Makefile
+++ b/packages/libndsfpc/examples/graphics/3D/nehe/lesson01/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/3D/nehe/lesson02/Makefile b/packages/libndsfpc/examples/graphics/3D/nehe/lesson02/Makefile
index 0f3457ff09..1285a72927 100644
--- a/packages/libndsfpc/examples/graphics/3D/nehe/lesson02/Makefile
+++ b/packages/libndsfpc/examples/graphics/3D/nehe/lesson02/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/3D/nehe/lesson03/Makefile b/packages/libndsfpc/examples/graphics/3D/nehe/lesson03/Makefile
index b03e8a1ab9..1d766681a9 100644
--- a/packages/libndsfpc/examples/graphics/3D/nehe/lesson03/Makefile
+++ b/packages/libndsfpc/examples/graphics/3D/nehe/lesson03/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/3D/nehe/lesson04/Makefile b/packages/libndsfpc/examples/graphics/3D/nehe/lesson04/Makefile
index c8c06a3c1b..ff7d90a3db 100644
--- a/packages/libndsfpc/examples/graphics/3D/nehe/lesson04/Makefile
+++ b/packages/libndsfpc/examples/graphics/3D/nehe/lesson04/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/3D/nehe/lesson05/Makefile b/packages/libndsfpc/examples/graphics/3D/nehe/lesson05/Makefile
index fcfeae06fe..a11376a570 100644
--- a/packages/libndsfpc/examples/graphics/3D/nehe/lesson05/Makefile
+++ b/packages/libndsfpc/examples/graphics/3D/nehe/lesson05/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/3D/nehe/lesson06/Makefile b/packages/libndsfpc/examples/graphics/3D/nehe/lesson06/Makefile
index 0d46c13be6..0a5e70011e 100644
--- a/packages/libndsfpc/examples/graphics/3D/nehe/lesson06/Makefile
+++ b/packages/libndsfpc/examples/graphics/3D/nehe/lesson06/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/3D/nehe/lesson07/Makefile b/packages/libndsfpc/examples/graphics/3D/nehe/lesson07/Makefile
index 071aee0c3c..d1c634aaf6 100644
--- a/packages/libndsfpc/examples/graphics/3D/nehe/lesson07/Makefile
+++ b/packages/libndsfpc/examples/graphics/3D/nehe/lesson07/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/3D/nehe/lesson08/Makefile b/packages/libndsfpc/examples/graphics/3D/nehe/lesson08/Makefile
index 33c5d71c1f..f0885ef983 100644
--- a/packages/libndsfpc/examples/graphics/3D/nehe/lesson08/Makefile
+++ b/packages/libndsfpc/examples/graphics/3D/nehe/lesson08/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/3D/nehe/lesson09/Makefile b/packages/libndsfpc/examples/graphics/3D/nehe/lesson09/Makefile
index 65be5f6c70..2b8c4a8944 100644
--- a/packages/libndsfpc/examples/graphics/3D/nehe/lesson09/Makefile
+++ b/packages/libndsfpc/examples/graphics/3D/nehe/lesson09/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/3D/nehe/lesson10/Makefile b/packages/libndsfpc/examples/graphics/3D/nehe/lesson10/Makefile
index bb3b7f65bd..e1d5bf5b16 100644
--- a/packages/libndsfpc/examples/graphics/3D/nehe/lesson10/Makefile
+++ b/packages/libndsfpc/examples/graphics/3D/nehe/lesson10/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/3D/nehe/lesson10b/Makefile b/packages/libndsfpc/examples/graphics/3D/nehe/lesson10b/Makefile
index 5859503352..c550154887 100644
--- a/packages/libndsfpc/examples/graphics/3D/nehe/lesson10b/Makefile
+++ b/packages/libndsfpc/examples/graphics/3D/nehe/lesson10b/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/3D/nehe/lesson11/Makefile b/packages/libndsfpc/examples/graphics/3D/nehe/lesson11/Makefile
index f1905051cc..5dfafb45fe 100644
--- a/packages/libndsfpc/examples/graphics/3D/nehe/lesson11/Makefile
+++ b/packages/libndsfpc/examples/graphics/3D/nehe/lesson11/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/Backgrounds/16bit_color_bmp/Makefile b/packages/libndsfpc/examples/graphics/Backgrounds/16bit_color_bmp/Makefile
index 23ec5b1ed1..b203cc635f 100644
--- a/packages/libndsfpc/examples/graphics/Backgrounds/16bit_color_bmp/Makefile
+++ b/packages/libndsfpc/examples/graphics/Backgrounds/16bit_color_bmp/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/Backgrounds/256_color_bmp/Makefile b/packages/libndsfpc/examples/graphics/Backgrounds/256_color_bmp/Makefile
index a15ccd43cb..ce90f4fe53 100644
--- a/packages/libndsfpc/examples/graphics/Backgrounds/256_color_bmp/Makefile
+++ b/packages/libndsfpc/examples/graphics/Backgrounds/256_color_bmp/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/Backgrounds/Double_Buffer/Makefile b/packages/libndsfpc/examples/graphics/Backgrounds/Double_Buffer/Makefile
index 0626506474..c76181f5c2 100644
--- a/packages/libndsfpc/examples/graphics/Backgrounds/Double_Buffer/Makefile
+++ b/packages/libndsfpc/examples/graphics/Backgrounds/Double_Buffer/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/Backgrounds/Makefile b/packages/libndsfpc/examples/graphics/Backgrounds/Makefile
index 1b2430a37d..1f77c191e0 100644
--- a/packages/libndsfpc/examples/graphics/Backgrounds/Makefile
+++ b/packages/libndsfpc/examples/graphics/Backgrounds/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/Backgrounds/all_in_one/Makefile b/packages/libndsfpc/examples/graphics/Backgrounds/all_in_one/Makefile
index 1073e2c849..bd2f8e4f74 100644
--- a/packages/libndsfpc/examples/graphics/Backgrounds/all_in_one/Makefile
+++ b/packages/libndsfpc/examples/graphics/Backgrounds/all_in_one/Makefile
@@ -2500,10 +2500,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4323,7 +4331,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/Backgrounds/rotation/Makefile b/packages/libndsfpc/examples/graphics/Backgrounds/rotation/Makefile
index e6c44e9361..894574066b 100644
--- a/packages/libndsfpc/examples/graphics/Backgrounds/rotation/Makefile
+++ b/packages/libndsfpc/examples/graphics/Backgrounds/rotation/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/Effects/Makefile b/packages/libndsfpc/examples/graphics/Effects/Makefile
index bf234177df..e3c0b867b6 100644
--- a/packages/libndsfpc/examples/graphics/Effects/Makefile
+++ b/packages/libndsfpc/examples/graphics/Effects/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/Effects/windows/Makefile b/packages/libndsfpc/examples/graphics/Effects/windows/Makefile
index 67dca39485..518e3bd5fe 100644
--- a/packages/libndsfpc/examples/graphics/Effects/windows/Makefile
+++ b/packages/libndsfpc/examples/graphics/Effects/windows/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/Ext_Palettes/Makefile b/packages/libndsfpc/examples/graphics/Ext_Palettes/Makefile
index dd5258bc98..abf7484753 100644
--- a/packages/libndsfpc/examples/graphics/Ext_Palettes/Makefile
+++ b/packages/libndsfpc/examples/graphics/Ext_Palettes/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/Ext_Palettes/backgrounds/Makefile b/packages/libndsfpc/examples/graphics/Ext_Palettes/backgrounds/Makefile
index d51d24f0cc..ec9129eddd 100644
--- a/packages/libndsfpc/examples/graphics/Ext_Palettes/backgrounds/Makefile
+++ b/packages/libndsfpc/examples/graphics/Ext_Palettes/backgrounds/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/Makefile b/packages/libndsfpc/examples/graphics/Makefile
index bda992862d..b418d32722 100644
--- a/packages/libndsfpc/examples/graphics/Makefile
+++ b/packages/libndsfpc/examples/graphics/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/Printing/Makefile b/packages/libndsfpc/examples/graphics/Printing/Makefile
index 2132bb2446..679b6f7e62 100644
--- a/packages/libndsfpc/examples/graphics/Printing/Makefile
+++ b/packages/libndsfpc/examples/graphics/Printing/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/Printing/ansi_console/Makefile b/packages/libndsfpc/examples/graphics/Printing/ansi_console/Makefile
index 402a35a1d2..320b73cc50 100644
--- a/packages/libndsfpc/examples/graphics/Printing/ansi_console/Makefile
+++ b/packages/libndsfpc/examples/graphics/Printing/ansi_console/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/Printing/console_windows/Makefile b/packages/libndsfpc/examples/graphics/Printing/console_windows/Makefile
index 8b7407c24e..3daee34108 100644
--- a/packages/libndsfpc/examples/graphics/Printing/console_windows/Makefile
+++ b/packages/libndsfpc/examples/graphics/Printing/console_windows/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/Printing/custom_font/Makefile b/packages/libndsfpc/examples/graphics/Printing/custom_font/Makefile
index 4196f35ac5..4b8b60d667 100644
--- a/packages/libndsfpc/examples/graphics/Printing/custom_font/Makefile
+++ b/packages/libndsfpc/examples/graphics/Printing/custom_font/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/Printing/print_both_screens/Makefile b/packages/libndsfpc/examples/graphics/Printing/print_both_screens/Makefile
index 4a8811ba6c..61f33fdc06 100644
--- a/packages/libndsfpc/examples/graphics/Printing/print_both_screens/Makefile
+++ b/packages/libndsfpc/examples/graphics/Printing/print_both_screens/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/Printing/rotscale_text/Makefile b/packages/libndsfpc/examples/graphics/Printing/rotscale_text/Makefile
index cfa9d44b08..d22c2e69fe 100644
--- a/packages/libndsfpc/examples/graphics/Printing/rotscale_text/Makefile
+++ b/packages/libndsfpc/examples/graphics/Printing/rotscale_text/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/Sprites/Makefile b/packages/libndsfpc/examples/graphics/Sprites/Makefile
index 14941c0ed2..80a91f5e2c 100644
--- a/packages/libndsfpc/examples/graphics/Sprites/Makefile
+++ b/packages/libndsfpc/examples/graphics/Sprites/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/Sprites/allocation_test/Makefile b/packages/libndsfpc/examples/graphics/Sprites/allocation_test/Makefile
index dfcb4f865c..15ccb0042f 100644
--- a/packages/libndsfpc/examples/graphics/Sprites/allocation_test/Makefile
+++ b/packages/libndsfpc/examples/graphics/Sprites/allocation_test/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/Sprites/animate_simple/Makefile b/packages/libndsfpc/examples/graphics/Sprites/animate_simple/Makefile
index d1604e20b0..f882bcb6c0 100644
--- a/packages/libndsfpc/examples/graphics/Sprites/animate_simple/Makefile
+++ b/packages/libndsfpc/examples/graphics/Sprites/animate_simple/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/Sprites/bitmap_sprites/Makefile b/packages/libndsfpc/examples/graphics/Sprites/bitmap_sprites/Makefile
index e04ce02025..b69a067723 100644
--- a/packages/libndsfpc/examples/graphics/Sprites/bitmap_sprites/Makefile
+++ b/packages/libndsfpc/examples/graphics/Sprites/bitmap_sprites/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/Sprites/fire_and_sprites/Makefile b/packages/libndsfpc/examples/graphics/Sprites/fire_and_sprites/Makefile
index 7d43345af1..ff04ce87f3 100644
--- a/packages/libndsfpc/examples/graphics/Sprites/fire_and_sprites/Makefile
+++ b/packages/libndsfpc/examples/graphics/Sprites/fire_and_sprites/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/Sprites/simple/Makefile b/packages/libndsfpc/examples/graphics/Sprites/simple/Makefile
index 31e78746c0..a423dd86b0 100644
--- a/packages/libndsfpc/examples/graphics/Sprites/simple/Makefile
+++ b/packages/libndsfpc/examples/graphics/Sprites/simple/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/Sprites/sprite_extended_palettes/Makefile b/packages/libndsfpc/examples/graphics/Sprites/sprite_extended_palettes/Makefile
index 6d44ea1b45..dae39eac43 100644
--- a/packages/libndsfpc/examples/graphics/Sprites/sprite_extended_palettes/Makefile
+++ b/packages/libndsfpc/examples/graphics/Sprites/sprite_extended_palettes/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/Sprites/sprite_rotate/Makefile b/packages/libndsfpc/examples/graphics/Sprites/sprite_rotate/Makefile
index eb022bfa3f..c6fee40d8b 100644
--- a/packages/libndsfpc/examples/graphics/Sprites/sprite_rotate/Makefile
+++ b/packages/libndsfpc/examples/graphics/Sprites/sprite_rotate/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/grit/256colorTilemap/Makefile b/packages/libndsfpc/examples/graphics/grit/256colorTilemap/Makefile
index 8c53e07dcc..00a3bcfd6d 100644
--- a/packages/libndsfpc/examples/graphics/grit/256colorTilemap/Makefile
+++ b/packages/libndsfpc/examples/graphics/grit/256colorTilemap/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/graphics/grit/Makefile b/packages/libndsfpc/examples/graphics/grit/Makefile
index 93504c2b20..f1ed57ac3e 100644
--- a/packages/libndsfpc/examples/graphics/grit/Makefile
+++ b/packages/libndsfpc/examples/graphics/grit/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/hello_world/Makefile b/packages/libndsfpc/examples/hello_world/Makefile
index 2c8f4728fd..e6f5178edd 100644
--- a/packages/libndsfpc/examples/hello_world/Makefile
+++ b/packages/libndsfpc/examples/hello_world/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/input/Makefile b/packages/libndsfpc/examples/input/Makefile
index 914d519a04..bd9d55f5c0 100644
--- a/packages/libndsfpc/examples/input/Makefile
+++ b/packages/libndsfpc/examples/input/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/input/Touch_Pad/Makefile b/packages/libndsfpc/examples/input/Touch_Pad/Makefile
index 0213f28259..cc3ae3a0e7 100644
--- a/packages/libndsfpc/examples/input/Touch_Pad/Makefile
+++ b/packages/libndsfpc/examples/input/Touch_Pad/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/input/Touch_Pad/touch_area/Makefile b/packages/libndsfpc/examples/input/Touch_Pad/touch_area/Makefile
index 8405fb3bf4..4d3fe1d699 100644
--- a/packages/libndsfpc/examples/input/Touch_Pad/touch_area/Makefile
+++ b/packages/libndsfpc/examples/input/Touch_Pad/touch_area/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/input/Touch_Pad/touch_look/Makefile b/packages/libndsfpc/examples/input/Touch_Pad/touch_look/Makefile
index cc31163de7..7e2adeee5f 100644
--- a/packages/libndsfpc/examples/input/Touch_Pad/touch_look/Makefile
+++ b/packages/libndsfpc/examples/input/Touch_Pad/touch_look/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/input/Touch_Pad/touch_test/Makefile b/packages/libndsfpc/examples/input/Touch_Pad/touch_test/Makefile
index 224a5de917..4179aceb5b 100644
--- a/packages/libndsfpc/examples/input/Touch_Pad/touch_test/Makefile
+++ b/packages/libndsfpc/examples/input/Touch_Pad/touch_test/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/input/keyboard/Makefile b/packages/libndsfpc/examples/input/keyboard/Makefile
index e356d3ce89..985b030495 100644
--- a/packages/libndsfpc/examples/input/keyboard/Makefile
+++ b/packages/libndsfpc/examples/input/keyboard/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/input/keyboard/keyboard_async/Makefile b/packages/libndsfpc/examples/input/keyboard/keyboard_async/Makefile
index 39bd3110e0..577f97470b 100644
--- a/packages/libndsfpc/examples/input/keyboard/keyboard_async/Makefile
+++ b/packages/libndsfpc/examples/input/keyboard/keyboard_async/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/input/keyboard/keyboard_stdin/Makefile b/packages/libndsfpc/examples/input/keyboard/keyboard_stdin/Makefile
index 4c55313574..d5c0ee4c87 100644
--- a/packages/libndsfpc/examples/input/keyboard/keyboard_stdin/Makefile
+++ b/packages/libndsfpc/examples/input/keyboard/keyboard_stdin/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/time/Makefile b/packages/libndsfpc/examples/time/Makefile
index e5e4edfabf..2e2f78464f 100644
--- a/packages/libndsfpc/examples/time/Makefile
+++ b/packages/libndsfpc/examples/time/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/time/RealTimeClock/Makefile b/packages/libndsfpc/examples/time/RealTimeClock/Makefile
index 5ad4bb7efe..7f049d743d 100644
--- a/packages/libndsfpc/examples/time/RealTimeClock/Makefile
+++ b/packages/libndsfpc/examples/time/RealTimeClock/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/time/stopwatch/Makefile b/packages/libndsfpc/examples/time/stopwatch/Makefile
index 07594edafd..18df8173e1 100644
--- a/packages/libndsfpc/examples/time/stopwatch/Makefile
+++ b/packages/libndsfpc/examples/time/stopwatch/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libndsfpc/examples/time/timercallback/Makefile b/packages/libndsfpc/examples/time/timercallback/Makefile
index ec87f0d5b1..7e529514e5 100644
--- a/packages/libndsfpc/examples/time/timercallback/Makefile
+++ b/packages/libndsfpc/examples/time/timercallback/Makefile
@@ -2499,10 +2499,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -4322,7 +4330,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libogcfpc/Makefile b/packages/libogcfpc/Makefile
index e317ed8dd0..378d0791ff 100644
--- a/packages/libogcfpc/Makefile
+++ b/packages/libogcfpc/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libogcfpc/examples/Makefile b/packages/libogcfpc/examples/Makefile
index a1dabaca5b..bd48c18458 100644
--- a/packages/libogcfpc/examples/Makefile
+++ b/packages/libogcfpc/examples/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2878,7 +2886,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libogcfpc/examples/audio/Makefile b/packages/libogcfpc/examples/audio/Makefile
index 78e0f482be..161fdaa72a 100644
--- a/packages/libogcfpc/examples/audio/Makefile
+++ b/packages/libogcfpc/examples/audio/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2878,7 +2886,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libogcfpc/examples/audio/modplay/Makefile b/packages/libogcfpc/examples/audio/modplay/Makefile
index 0cfc4d9855..647bcb635b 100644
--- a/packages/libogcfpc/examples/audio/modplay/Makefile
+++ b/packages/libogcfpc/examples/audio/modplay/Makefile
@@ -1865,10 +1865,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3688,7 +3696,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libogcfpc/examples/audio/mp3player/Makefile b/packages/libogcfpc/examples/audio/mp3player/Makefile
index 2c2c8e9f56..1c44e22ee6 100644
--- a/packages/libogcfpc/examples/audio/mp3player/Makefile
+++ b/packages/libogcfpc/examples/audio/mp3player/Makefile
@@ -1865,10 +1865,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3831,7 +3839,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libogcfpc/examples/devices/Makefile b/packages/libogcfpc/examples/devices/Makefile
index b42b332355..405fa9394d 100644
--- a/packages/libogcfpc/examples/devices/Makefile
+++ b/packages/libogcfpc/examples/devices/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libogcfpc/examples/devices/network/Makefile b/packages/libogcfpc/examples/devices/network/Makefile
index 1a784c98d5..e671d18251 100644
--- a/packages/libogcfpc/examples/devices/network/Makefile
+++ b/packages/libogcfpc/examples/devices/network/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libogcfpc/examples/devices/network/sockettest/Makefile b/packages/libogcfpc/examples/devices/network/sockettest/Makefile
index 80e5ce50d8..54873a9fa6 100644
--- a/packages/libogcfpc/examples/devices/network/sockettest/Makefile
+++ b/packages/libogcfpc/examples/devices/network/sockettest/Makefile
@@ -1865,10 +1865,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3688,7 +3696,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libogcfpc/examples/devices/usbgecko/Makefile b/packages/libogcfpc/examples/devices/usbgecko/Makefile
index 637c54344e..4052443c41 100644
--- a/packages/libogcfpc/examples/devices/usbgecko/Makefile
+++ b/packages/libogcfpc/examples/devices/usbgecko/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libogcfpc/examples/devices/usbgecko/gdbstub/Makefile b/packages/libogcfpc/examples/devices/usbgecko/gdbstub/Makefile
index f5ae7343ab..4dc77f8b5c 100644
--- a/packages/libogcfpc/examples/devices/usbgecko/gdbstub/Makefile
+++ b/packages/libogcfpc/examples/devices/usbgecko/gdbstub/Makefile
@@ -1865,10 +1865,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3688,7 +3696,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libogcfpc/examples/devices/usbkeyboard/Makefile b/packages/libogcfpc/examples/devices/usbkeyboard/Makefile
index 6f407e1918..55f0aac397 100644
--- a/packages/libogcfpc/examples/devices/usbkeyboard/Makefile
+++ b/packages/libogcfpc/examples/devices/usbkeyboard/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libogcfpc/examples/devices/usbkeyboard/basic_stdin/Makefile b/packages/libogcfpc/examples/devices/usbkeyboard/basic_stdin/Makefile
index a2ab538d62..ba36958324 100644
--- a/packages/libogcfpc/examples/devices/usbkeyboard/basic_stdin/Makefile
+++ b/packages/libogcfpc/examples/devices/usbkeyboard/basic_stdin/Makefile
@@ -1865,10 +1865,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3688,7 +3696,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libogcfpc/examples/filesystem/Makefile b/packages/libogcfpc/examples/filesystem/Makefile
index c621213193..7f984dfc18 100644
--- a/packages/libogcfpc/examples/filesystem/Makefile
+++ b/packages/libogcfpc/examples/filesystem/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libogcfpc/examples/filesystem/directory/Makefile b/packages/libogcfpc/examples/filesystem/directory/Makefile
index 0e08f02c57..3bd60dc5f1 100644
--- a/packages/libogcfpc/examples/filesystem/directory/Makefile
+++ b/packages/libogcfpc/examples/filesystem/directory/Makefile
@@ -1865,10 +1865,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3688,7 +3696,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libogcfpc/examples/graphics/Makefile b/packages/libogcfpc/examples/graphics/Makefile
index 24c5b821f3..f372089eb8 100644
--- a/packages/libogcfpc/examples/graphics/Makefile
+++ b/packages/libogcfpc/examples/graphics/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libogcfpc/examples/graphics/gx/Makefile b/packages/libogcfpc/examples/graphics/gx/Makefile
index 284b73aa5f..91e87b114a 100644
--- a/packages/libogcfpc/examples/graphics/gx/Makefile
+++ b/packages/libogcfpc/examples/graphics/gx/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libogcfpc/examples/graphics/gx/gxSprites/Makefile b/packages/libogcfpc/examples/graphics/gx/gxSprites/Makefile
index e592ca8983..fc511f164c 100644
--- a/packages/libogcfpc/examples/graphics/gx/gxSprites/Makefile
+++ b/packages/libogcfpc/examples/graphics/gx/gxSprites/Makefile
@@ -1865,10 +1865,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3688,7 +3696,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libogcfpc/examples/graphics/gx/neheGX/Makefile b/packages/libogcfpc/examples/graphics/gx/neheGX/Makefile
index fcb3139666..f25651f0cd 100644
--- a/packages/libogcfpc/examples/graphics/gx/neheGX/Makefile
+++ b/packages/libogcfpc/examples/graphics/gx/neheGX/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libogcfpc/examples/graphics/gx/neheGX/lesson1/Makefile b/packages/libogcfpc/examples/graphics/gx/neheGX/lesson1/Makefile
index 9427d56276..99bf206615 100644
--- a/packages/libogcfpc/examples/graphics/gx/neheGX/lesson1/Makefile
+++ b/packages/libogcfpc/examples/graphics/gx/neheGX/lesson1/Makefile
@@ -1865,10 +1865,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3688,7 +3696,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libogcfpc/examples/graphics/gx/neheGX/lesson2/Makefile b/packages/libogcfpc/examples/graphics/gx/neheGX/lesson2/Makefile
index d2abe3dd72..5ecbddee1d 100644
--- a/packages/libogcfpc/examples/graphics/gx/neheGX/lesson2/Makefile
+++ b/packages/libogcfpc/examples/graphics/gx/neheGX/lesson2/Makefile
@@ -1865,10 +1865,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3688,7 +3696,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libogcfpc/examples/graphics/gx/neheGX/lesson3/Makefile b/packages/libogcfpc/examples/graphics/gx/neheGX/lesson3/Makefile
index c94ab138cc..d270f6ee5a 100644
--- a/packages/libogcfpc/examples/graphics/gx/neheGX/lesson3/Makefile
+++ b/packages/libogcfpc/examples/graphics/gx/neheGX/lesson3/Makefile
@@ -1865,10 +1865,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3688,7 +3696,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libogcfpc/examples/graphics/gx/neheGX/lesson4/Makefile b/packages/libogcfpc/examples/graphics/gx/neheGX/lesson4/Makefile
index 96fa5760a2..63c99a6c5a 100644
--- a/packages/libogcfpc/examples/graphics/gx/neheGX/lesson4/Makefile
+++ b/packages/libogcfpc/examples/graphics/gx/neheGX/lesson4/Makefile
@@ -1865,10 +1865,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3688,7 +3696,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libogcfpc/examples/graphics/gx/neheGX/lesson5/Makefile b/packages/libogcfpc/examples/graphics/gx/neheGX/lesson5/Makefile
index bc1c5a03c6..ca00e2ceb0 100644
--- a/packages/libogcfpc/examples/graphics/gx/neheGX/lesson5/Makefile
+++ b/packages/libogcfpc/examples/graphics/gx/neheGX/lesson5/Makefile
@@ -1865,10 +1865,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3688,7 +3696,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libogcfpc/examples/graphics/gx/neheGX/lesson6/Makefile b/packages/libogcfpc/examples/graphics/gx/neheGX/lesson6/Makefile
index 2615a7fda7..8d93f2edd7 100644
--- a/packages/libogcfpc/examples/graphics/gx/neheGX/lesson6/Makefile
+++ b/packages/libogcfpc/examples/graphics/gx/neheGX/lesson6/Makefile
@@ -1865,10 +1865,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3688,7 +3696,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libogcfpc/examples/graphics/gx/neheGX/lesson7/Makefile b/packages/libogcfpc/examples/graphics/gx/neheGX/lesson7/Makefile
index abf6e57983..81dda5fd6c 100644
--- a/packages/libogcfpc/examples/graphics/gx/neheGX/lesson7/Makefile
+++ b/packages/libogcfpc/examples/graphics/gx/neheGX/lesson7/Makefile
@@ -1865,10 +1865,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3688,7 +3696,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libogcfpc/examples/graphics/gx/neheGX/lesson8/Makefile b/packages/libogcfpc/examples/graphics/gx/neheGX/lesson8/Makefile
index 28942e08a0..58c305dc24 100644
--- a/packages/libogcfpc/examples/graphics/gx/neheGX/lesson8/Makefile
+++ b/packages/libogcfpc/examples/graphics/gx/neheGX/lesson8/Makefile
@@ -1865,10 +1865,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3688,7 +3696,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libogcfpc/examples/graphics/gx/neheGX/lesson9/Makefile b/packages/libogcfpc/examples/graphics/gx/neheGX/lesson9/Makefile
index 6400b6db4c..9d688c2d4b 100644
--- a/packages/libogcfpc/examples/graphics/gx/neheGX/lesson9/Makefile
+++ b/packages/libogcfpc/examples/graphics/gx/neheGX/lesson9/Makefile
@@ -1865,10 +1865,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3688,7 +3696,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libogcfpc/examples/graphics/gx/triangle/Makefile b/packages/libogcfpc/examples/graphics/gx/triangle/Makefile
index f115784296..56f059d0fd 100644
--- a/packages/libogcfpc/examples/graphics/gx/triangle/Makefile
+++ b/packages/libogcfpc/examples/graphics/gx/triangle/Makefile
@@ -1865,10 +1865,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3688,7 +3696,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libogcfpc/examples/template/Makefile b/packages/libogcfpc/examples/template/Makefile
index c21d3258ac..100a01b3fb 100644
--- a/packages/libogcfpc/examples/template/Makefile
+++ b/packages/libogcfpc/examples/template/Makefile
@@ -1865,10 +1865,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3688,7 +3696,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libpng/Makefile b/packages/libpng/Makefile
index 56158c368b..2f2ca0546a 100644
--- a/packages/libpng/Makefile
+++ b/packages/libpng/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/librsvg/Makefile b/packages/librsvg/Makefile
index 6ef485f230..7a00fca76a 100644
--- a/packages/librsvg/Makefile
+++ b/packages/librsvg/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libsee/Makefile b/packages/libsee/Makefile
index 9d2928a717..10c11aac1e 100644
--- a/packages/libsee/Makefile
+++ b/packages/libsee/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libsee/examples/Makefile b/packages/libsee/examples/Makefile
index 40fb2046f3..585a824584 100644
--- a/packages/libsee/examples/Makefile
+++ b/packages/libsee/examples/Makefile
@@ -1227,10 +1227,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3050,7 +3058,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libtar/Makefile b/packages/libtar/Makefile
index 832ae22219..5f05522b33 100644
--- a/packages/libtar/Makefile
+++ b/packages/libtar/Makefile
@@ -1604,7 +1604,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libusb/Makefile b/packages/libusb/Makefile
index 8a7d559147..0d949c7384 100644
--- a/packages/libusb/Makefile
+++ b/packages/libusb/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libvlc/Makefile b/packages/libvlc/Makefile
index c4076e5e7e..b289a41222 100644
--- a/packages/libvlc/Makefile
+++ b/packages/libvlc/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libxml/Makefile b/packages/libxml/Makefile
index 1cf86913b1..0e6e32548e 100644
--- a/packages/libxml/Makefile
+++ b/packages/libxml/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/libxml/examples/Makefile b/packages/libxml/examples/Makefile
index 75d4d346ee..12d7c4cbf5 100644
--- a/packages/libxml/examples/Makefile
+++ b/packages/libxml/examples/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -1877,7 +1885,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/lua/Makefile b/packages/lua/Makefile
index 5cb0294592..0ea50e92ce 100644
--- a/packages/lua/Makefile
+++ b/packages/lua/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/mad/Makefile b/packages/mad/Makefile
index c50f10955c..6d570b1130 100644
--- a/packages/mad/Makefile
+++ b/packages/mad/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/matroska/Makefile b/packages/matroska/Makefile
index fc49da4cf7..6d2de4268b 100644
--- a/packages/matroska/Makefile
+++ b/packages/matroska/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/modplug/Makefile b/packages/modplug/Makefile
index 54ebdc7bbc..08cc09c1ee 100644
--- a/packages/modplug/Makefile
+++ b/packages/modplug/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/morphunits/Makefile b/packages/morphunits/Makefile
index 91fc69f0fe..068ee1be74 100644
--- a/packages/morphunits/Makefile
+++ b/packages/morphunits/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/mysql/Makefile b/packages/mysql/Makefile
index 5f947104b9..c606826c8c 100644
--- a/packages/mysql/Makefile
+++ b/packages/mysql/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/mysql/examples/Makefile b/packages/mysql/examples/Makefile
index bc03287eea..1a06403e28 100644
--- a/packages/mysql/examples/Makefile
+++ b/packages/mysql/examples/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/ncurses/Makefile b/packages/ncurses/Makefile
index 33853fbde2..8f9ea1b573 100644
--- a/packages/ncurses/Makefile
+++ b/packages/ncurses/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/ncurses/examples/Makefile b/packages/ncurses/examples/Makefile
index f465145b85..b885773f5c 100644
--- a/packages/ncurses/examples/Makefile
+++ b/packages/ncurses/examples/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/newt/Makefile b/packages/newt/Makefile
index 3e9037bc67..1898d7bc87 100644
--- a/packages/newt/Makefile
+++ b/packages/newt/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/newt/examples/Makefile b/packages/newt/examples/Makefile
index 87d0e2e2a1..c7c3f4c210 100644
--- a/packages/newt/examples/Makefile
+++ b/packages/newt/examples/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/numlib/Makefile b/packages/numlib/Makefile
index 89a8ff1638..6a1796ee78 100644
--- a/packages/numlib/Makefile
+++ b/packages/numlib/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/numlib/examples/Makefile b/packages/numlib/examples/Makefile
index 709ad6b927..dc0fc21a0d 100644
--- a/packages/numlib/examples/Makefile
+++ b/packages/numlib/examples/Makefile
@@ -2488,10 +2488,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3453,7 +3461,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/nvapi/Makefile b/packages/nvapi/Makefile
index 109d58f8bf..5eb3f34bf3 100644
--- a/packages/nvapi/Makefile
+++ b/packages/nvapi/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/objcrtl/Makefile b/packages/objcrtl/Makefile
index bdcf0a0127..b8493e11c0 100644
--- a/packages/objcrtl/Makefile
+++ b/packages/objcrtl/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/odata/Makefile b/packages/odata/Makefile
index a8f3f61a78..c4d0977b11 100644
--- a/packages/odata/Makefile
+++ b/packages/odata/Makefile
@@ -2581,7 +2581,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/odbc/Makefile b/packages/odbc/Makefile
index 47a97e54f8..a973abc7dc 100644
--- a/packages/odbc/Makefile
+++ b/packages/odbc/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/odbc/examples/Makefile b/packages/odbc/examples/Makefile
index ec87ceb27d..7300aa619c 100644
--- a/packages/odbc/examples/Makefile
+++ b/packages/odbc/examples/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/oggvorbis/Makefile b/packages/oggvorbis/Makefile
index 0398174795..48b7173007 100644
--- a/packages/oggvorbis/Makefile
+++ b/packages/oggvorbis/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/openal/Makefile b/packages/openal/Makefile
index cc997fe4d6..e8f0a98db7 100644
--- a/packages/openal/Makefile
+++ b/packages/openal/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/openal/examples/Makefile b/packages/openal/examples/Makefile
index 59a013ea43..a629745c53 100644
--- a/packages/openal/examples/Makefile
+++ b/packages/openal/examples/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3505,7 +3513,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/opencl/Makefile b/packages/opencl/Makefile
index 32ed837453..eac21e31bb 100644
--- a/packages/opencl/Makefile
+++ b/packages/opencl/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/opengl/Makefile b/packages/opengl/Makefile
index 6cc1b87097..98349c7c70 100644
--- a/packages/opengl/Makefile
+++ b/packages/opengl/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/opengl/examples/Makefile b/packages/opengl/examples/Makefile
index cc4e14cda5..77139c091a 100644
--- a/packages/opengl/examples/Makefile
+++ b/packages/opengl/examples/Makefile
@@ -1227,10 +1227,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3050,7 +3058,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/opengles/Makefile b/packages/opengles/Makefile
index 042675618b..cb7c3e1a7f 100644
--- a/packages/opengles/Makefile
+++ b/packages/opengles/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/opengles/examples/Makefile b/packages/opengles/examples/Makefile
index 89c1d82691..c60e259ced 100644
--- a/packages/opengles/examples/Makefile
+++ b/packages/opengles/examples/Makefile
@@ -1227,10 +1227,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3050,7 +3058,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/openssl/Makefile b/packages/openssl/Makefile
index db15c5c340..da50397ade 100644
--- a/packages/openssl/Makefile
+++ b/packages/openssl/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/oracle/Makefile b/packages/oracle/Makefile
index 5ccb190772..12d2040098 100644
--- a/packages/oracle/Makefile
+++ b/packages/oracle/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/oracle/examples/Makefile b/packages/oracle/examples/Makefile
index ac5baf5c1d..99024ffabe 100644
--- a/packages/oracle/examples/Makefile
+++ b/packages/oracle/examples/Makefile
@@ -1227,10 +1227,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3479,7 +3487,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/os2units/Makefile b/packages/os2units/Makefile
index bb5b6c0756..ea3a97c8ad 100644
--- a/packages/os2units/Makefile
+++ b/packages/os2units/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/os2units/examples/Makefile b/packages/os2units/examples/Makefile
index d00a48cf4c..4e2109fb03 100644
--- a/packages/os2units/examples/Makefile
+++ b/packages/os2units/examples/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/os4units/Makefile b/packages/os4units/Makefile
index ee70199133..a9dbdeb62d 100644
--- a/packages/os4units/Makefile
+++ b/packages/os4units/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/palmunits/Makefile b/packages/palmunits/Makefile
index b71c08fcd7..552a863b8e 100644
--- a/packages/palmunits/Makefile
+++ b/packages/palmunits/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/pasjpeg/Makefile b/packages/pasjpeg/Makefile
index 203a6d263b..d0b7cf3d26 100644
--- a/packages/pasjpeg/Makefile
+++ b/packages/pasjpeg/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/pastojs/Makefile b/packages/pastojs/Makefile
index 694900d742..6852377591 100644
--- a/packages/pastojs/Makefile
+++ b/packages/pastojs/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/paszlib/Makefile b/packages/paszlib/Makefile
index 30df0dc4ce..2902000117 100644
--- a/packages/paszlib/Makefile
+++ b/packages/paszlib/Makefile
@@ -1604,7 +1604,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/paszlib/examples/Makefile b/packages/paszlib/examples/Makefile
index 46aecacae1..f4d4d78c3f 100644
--- a/packages/paszlib/examples/Makefile
+++ b/packages/paszlib/examples/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2020,7 +2028,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/pcap/Makefile b/packages/pcap/Makefile
index 9121b2fbeb..6485a5f605 100644
--- a/packages/pcap/Makefile
+++ b/packages/pcap/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/postgres/Makefile b/packages/postgres/Makefile
index 8a69dd66b4..24091eb2ae 100644
--- a/packages/postgres/Makefile
+++ b/packages/postgres/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/postgres/examples/Makefile b/packages/postgres/examples/Makefile
index 1cb9b9219c..cbf8c6641d 100644
--- a/packages/postgres/examples/Makefile
+++ b/packages/postgres/examples/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/proj4/Makefile b/packages/proj4/Makefile
index 5fc3723f82..10a7c8a3ec 100644
--- a/packages/proj4/Makefile
+++ b/packages/proj4/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/ptc/Makefile b/packages/ptc/Makefile
index cdfca54111..cbe4dd0a12 100644
--- a/packages/ptc/Makefile
+++ b/packages/ptc/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/ptc/examples/Makefile b/packages/ptc/examples/Makefile
index 0f4fa9341c..a008a3e294 100644
--- a/packages/ptc/examples/Makefile
+++ b/packages/ptc/examples/Makefile
@@ -1228,10 +1228,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3250,7 +3258,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/pthreads/Makefile b/packages/pthreads/Makefile
index cb7a2b1bac..24087bdd88 100644
--- a/packages/pthreads/Makefile
+++ b/packages/pthreads/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/pxlib/Makefile b/packages/pxlib/Makefile
index aa7c14cc30..3779d99f5a 100644
--- a/packages/pxlib/Makefile
+++ b/packages/pxlib/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/pxlib/examples/Makefile b/packages/pxlib/examples/Makefile
index 62f00ea6ae..31921cd1fe 100644
--- a/packages/pxlib/examples/Makefile
+++ b/packages/pxlib/examples/Makefile
@@ -702,10 +702,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2525,7 +2533,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/qlunits/Makefile b/packages/qlunits/Makefile
index 7f682468c2..5e8df01c28 100644
--- a/packages/qlunits/Makefile
+++ b/packages/qlunits/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/regexpr/Makefile b/packages/regexpr/Makefile
index 8e7041fcb8..e2681dfe5e 100644
--- a/packages/regexpr/Makefile
+++ b/packages/regexpr/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/regexpr/examples/Makefile b/packages/regexpr/examples/Makefile
index c9bc1b9e50..9c431c1a3e 100644
--- a/packages/regexpr/examples/Makefile
+++ b/packages/regexpr/examples/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/rexx/Makefile b/packages/rexx/Makefile
index e60072c0e6..d42456dff0 100644
--- a/packages/rexx/Makefile
+++ b/packages/rexx/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/rexx/examples/Makefile b/packages/rexx/examples/Makefile
index b73528e9ed..9fafddd253 100644
--- a/packages/rexx/examples/Makefile
+++ b/packages/rexx/examples/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/rtl-console/Makefile b/packages/rtl-console/Makefile
index 9a5920e264..6cc717029c 100644
--- a/packages/rtl-console/Makefile
+++ b/packages/rtl-console/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/rtl-extra/Makefile b/packages/rtl-extra/Makefile
index 372e84b0f3..fab708cef2 100644
--- a/packages/rtl-extra/Makefile
+++ b/packages/rtl-extra/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/rtl-generics/Makefile b/packages/rtl-generics/Makefile
index 29014eda29..1dae60cc5e 100644
--- a/packages/rtl-generics/Makefile
+++ b/packages/rtl-generics/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/rtl-objpas/Makefile b/packages/rtl-objpas/Makefile
index 38a5270d0e..51e1b6c703 100644
--- a/packages/rtl-objpas/Makefile
+++ b/packages/rtl-objpas/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/rtl-unicode/Makefile b/packages/rtl-unicode/Makefile
index d98499a80f..1aca2d5e24 100644
--- a/packages/rtl-unicode/Makefile
+++ b/packages/rtl-unicode/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/sdl/Makefile b/packages/sdl/Makefile
index b950c30d0a..f0dd6c21e9 100644
--- a/packages/sdl/Makefile
+++ b/packages/sdl/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/sndfile/Makefile b/packages/sndfile/Makefile
index 15747ffed4..e1b40edca5 100644
--- a/packages/sndfile/Makefile
+++ b/packages/sndfile/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/sqlite/Makefile b/packages/sqlite/Makefile
index 2ed9f7125f..5ef40cec88 100644
--- a/packages/sqlite/Makefile
+++ b/packages/sqlite/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/svgalib/Makefile b/packages/svgalib/Makefile
index 1b971c14ae..09cfcc89a6 100644
--- a/packages/svgalib/Makefile
+++ b/packages/svgalib/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/svgalib/examples/Makefile b/packages/svgalib/examples/Makefile
index 8644a724e7..2b85934b3a 100644
--- a/packages/svgalib/examples/Makefile
+++ b/packages/svgalib/examples/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/symbolic/Makefile b/packages/symbolic/Makefile
index 21a657084d..a9e1c0be62 100644
--- a/packages/symbolic/Makefile
+++ b/packages/symbolic/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/symbolic/examples/Makefile b/packages/symbolic/examples/Makefile
index 56eac4b237..00a00213ef 100644
--- a/packages/symbolic/examples/Makefile
+++ b/packages/symbolic/examples/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/syslog/Makefile b/packages/syslog/Makefile
index fd4f100240..b4025e986a 100644
--- a/packages/syslog/Makefile
+++ b/packages/syslog/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/syslog/examples/Makefile b/packages/syslog/examples/Makefile
index a30003e3e1..8ccc5cadee 100644
--- a/packages/syslog/examples/Makefile
+++ b/packages/syslog/examples/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/tcl/Makefile b/packages/tcl/Makefile
index db068bcc99..5c53005976 100644
--- a/packages/tcl/Makefile
+++ b/packages/tcl/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/tosunits/Makefile b/packages/tosunits/Makefile
index a6e9d0e52d..9d54b8754a 100644
--- a/packages/tosunits/Makefile
+++ b/packages/tosunits/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/tplylib/Makefile b/packages/tplylib/Makefile
index 41775fee7f..8eea61d5ce 100644
--- a/packages/tplylib/Makefile
+++ b/packages/tplylib/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/univint/Makefile b/packages/univint/Makefile
index be21d2cb8b..0671af33e0 100644
--- a/packages/univint/Makefile
+++ b/packages/univint/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/univint/examples/Makefile b/packages/univint/examples/Makefile
index 2416fdafd5..022dd61769 100644
--- a/packages/univint/examples/Makefile
+++ b/packages/univint/examples/Makefile
@@ -1227,10 +1227,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3050,7 +3058,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/unixutil/Makefile b/packages/unixutil/Makefile
index a4c34046d8..23075eadbb 100644
--- a/packages/unixutil/Makefile
+++ b/packages/unixutil/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/unzip/Makefile b/packages/unzip/Makefile
index 2085302393..e3f6ff2967 100644
--- a/packages/unzip/Makefile
+++ b/packages/unzip/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/users/Makefile b/packages/users/Makefile
index 437987fd50..4161050e58 100644
--- a/packages/users/Makefile
+++ b/packages/users/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/users/examples/Makefile b/packages/users/examples/Makefile
index 67494383e2..7d12720926 100644
--- a/packages/users/examples/Makefile
+++ b/packages/users/examples/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/utmp/Makefile b/packages/utmp/Makefile
index 630b346429..558d4eb77d 100644
--- a/packages/utmp/Makefile
+++ b/packages/utmp/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/utmp/examples/Makefile b/packages/utmp/examples/Makefile
index f5fbf0da5b..d3729dec65 100644
--- a/packages/utmp/examples/Makefile
+++ b/packages/utmp/examples/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/uuid/Makefile b/packages/uuid/Makefile
index 2793702e87..7e840cd3b2 100644
--- a/packages/uuid/Makefile
+++ b/packages/uuid/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/uuid/examples/Makefile b/packages/uuid/examples/Makefile
index 1c6409ba1e..231b373db4 100644
--- a/packages/uuid/examples/Makefile
+++ b/packages/uuid/examples/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/vcl-compat/Makefile b/packages/vcl-compat/Makefile
index d8866f64d3..930c698360 100644
--- a/packages/vcl-compat/Makefile
+++ b/packages/vcl-compat/Makefile
@@ -2724,7 +2724,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/webidl/Makefile b/packages/webidl/Makefile
index 4a7b74a6d3..82c8fe4322 100644
--- a/packages/webidl/Makefile
+++ b/packages/webidl/Makefile
@@ -2581,7 +2581,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/winceunits/Makefile b/packages/winceunits/Makefile
index 0084a2bab6..5cf22fad6e 100644
--- a/packages/winceunits/Makefile
+++ b/packages/winceunits/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/winunits-base/Makefile b/packages/winunits-base/Makefile
index 9fb3105ada..675c9c7d0c 100644
--- a/packages/winunits-base/Makefile
+++ b/packages/winunits-base/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/winunits-jedi/Makefile b/packages/winunits-jedi/Makefile
index 6db40dc287..ab46b25e69 100644
--- a/packages/winunits-jedi/Makefile
+++ b/packages/winunits-jedi/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/x11/Makefile b/packages/x11/Makefile
index 729041b03b..2048f52e89 100644
--- a/packages/x11/Makefile
+++ b/packages/x11/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/xforms/Makefile b/packages/xforms/Makefile
index d1357939ce..71a473cdde 100644
--- a/packages/xforms/Makefile
+++ b/packages/xforms/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/xforms/examples/Makefile b/packages/xforms/examples/Makefile
index 232d1580b5..391c3d8e94 100644
--- a/packages/xforms/examples/Makefile
+++ b/packages/xforms/examples/Makefile
@@ -912,10 +912,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2735,7 +2743,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/zlib/Makefile b/packages/zlib/Makefile
index 48ea001ad5..82890d1408 100644
--- a/packages/zlib/Makefile
+++ b/packages/zlib/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/packages/zorba/Makefile b/packages/zorba/Makefile
index a57ad58bf1..7233d07982 100644
--- a/packages/zorba/Makefile
+++ b/packages/zorba/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/aix/Makefile b/rtl/aix/Makefile
index fcf9c0b289..916149ed7d 100644
--- a/rtl/aix/Makefile
+++ b/rtl/aix/Makefile
@@ -2819,7 +2819,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/amiga/Makefile b/rtl/amiga/Makefile
index abefef6e2e..67e7517c68 100644
--- a/rtl/amiga/Makefile
+++ b/rtl/amiga/Makefile
@@ -3133,7 +3133,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/android/Makefile b/rtl/android/Makefile
index 588279ec22..0bb9e34d3f 100644
--- a/rtl/android/Makefile
+++ b/rtl/android/Makefile
@@ -2893,7 +2893,7 @@ endif
ifeq ($(FULL_TARGET),z80-amstradcpc)
override COMPILER_TARGETDIR+=.
endif
-override SHARED_LIBUNITS=$(SYSTEMUNIT) objpas strings dos unix baseunix unixtype unixutil sysutils typinfo math $(CPU_UNITS) getopts errors sockets sortbase classes fgl sysconst rtlconsts
+override SHARED_LIBUNITS=$(SYSTEMUNIT) objpas strings dos unix baseunix unixtype unixutil sysutils typinfo math $(CPU_UNITS) getopts errors sockets sortbase classes fgl sysconst rtlconsts
ifdef REQUIRE_UNITSDIR
override UNITSDIR+=$(REQUIRE_UNITSDIR)
endif
@@ -3762,7 +3762,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/android/jvm/Makefile b/rtl/android/jvm/Makefile
index 6a42f30a57..96f1dc2d20 100644
--- a/rtl/android/jvm/Makefile
+++ b/rtl/android/jvm/Makefile
@@ -2175,7 +2175,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/aros/Makefile b/rtl/aros/Makefile
index 0c0b595b58..8de8f12bce 100644
--- a/rtl/aros/Makefile
+++ b/rtl/aros/Makefile
@@ -3127,7 +3127,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/atari/Makefile b/rtl/atari/Makefile
index 1ba07a7167..c5b0188e26 100644
--- a/rtl/atari/Makefile
+++ b/rtl/atari/Makefile
@@ -3121,7 +3121,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/beos/Makefile b/rtl/beos/Makefile
index a3a36ff2e2..d9e105fd7f 100644
--- a/rtl/beos/Makefile
+++ b/rtl/beos/Makefile
@@ -3436,7 +3436,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/darwin/Makefile b/rtl/darwin/Makefile
index 5240dfc177..0863225bba 100644
--- a/rtl/darwin/Makefile
+++ b/rtl/darwin/Makefile
@@ -2823,7 +2823,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/dragonfly/Makefile b/rtl/dragonfly/Makefile
index 7f56af4881..bf663c6cd1 100644
--- a/rtl/dragonfly/Makefile
+++ b/rtl/dragonfly/Makefile
@@ -3133,7 +3133,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/embedded/Makefile b/rtl/embedded/Makefile
index a27dfb032d..fa52768431 100644
--- a/rtl/embedded/Makefile
+++ b/rtl/embedded/Makefile
@@ -2660,7 +2660,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/emx/Makefile b/rtl/emx/Makefile
index 95420fcce3..207d725bf2 100644
--- a/rtl/emx/Makefile
+++ b/rtl/emx/Makefile
@@ -3125,7 +3125,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/freebsd/Makefile b/rtl/freebsd/Makefile
index 471da7dbb1..f2c11745c9 100644
--- a/rtl/freebsd/Makefile
+++ b/rtl/freebsd/Makefile
@@ -3138,7 +3138,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/freertos/Makefile b/rtl/freertos/Makefile
index 3d2eb2c559..1193cda7a9 100644
--- a/rtl/freertos/Makefile
+++ b/rtl/freertos/Makefile
@@ -2974,7 +2974,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/gba/Makefile b/rtl/gba/Makefile
index 1dd205578d..83670896de 100644
--- a/rtl/gba/Makefile
+++ b/rtl/gba/Makefile
@@ -2807,7 +2807,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/go32v2/Makefile b/rtl/go32v2/Makefile
index a728761e3a..a5a04b0921 100644
--- a/rtl/go32v2/Makefile
+++ b/rtl/go32v2/Makefile
@@ -3126,7 +3126,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/haiku/Makefile b/rtl/haiku/Makefile
index 435bb6e89b..9b636b7a07 100644
--- a/rtl/haiku/Makefile
+++ b/rtl/haiku/Makefile
@@ -3444,7 +3444,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/java/Makefile b/rtl/java/Makefile
index 97299656c6..de62408813 100644
--- a/rtl/java/Makefile
+++ b/rtl/java/Makefile
@@ -2179,7 +2179,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/macos/Makefile b/rtl/macos/Makefile
index 6634aa920d..77b05a0ef6 100644
--- a/rtl/macos/Makefile
+++ b/rtl/macos/Makefile
@@ -2810,7 +2810,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/morphos/Makefile b/rtl/morphos/Makefile
index 2c21fb610e..2e05b3947d 100644
--- a/rtl/morphos/Makefile
+++ b/rtl/morphos/Makefile
@@ -2808,7 +2808,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/msdos/Makefile b/rtl/msdos/Makefile
index b644658c6f..a6c87b8378 100644
--- a/rtl/msdos/Makefile
+++ b/rtl/msdos/Makefile
@@ -2808,7 +2808,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/msxdos/Makefile b/rtl/msxdos/Makefile
index c462acc711..95161d65c2 100644
--- a/rtl/msxdos/Makefile
+++ b/rtl/msxdos/Makefile
@@ -2493,7 +2493,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/nativent/Makefile b/rtl/nativent/Makefile
index 8f7148bed8..8b599b3f07 100644
--- a/rtl/nativent/Makefile
+++ b/rtl/nativent/Makefile
@@ -2816,7 +2816,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/nds/Makefile b/rtl/nds/Makefile
index c215edb37d..bca87ff4af 100644
--- a/rtl/nds/Makefile
+++ b/rtl/nds/Makefile
@@ -2807,7 +2807,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/netbsd/Makefile b/rtl/netbsd/Makefile
index b6d37d8b65..67389eec4b 100644
--- a/rtl/netbsd/Makefile
+++ b/rtl/netbsd/Makefile
@@ -3135,7 +3135,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/netware/Makefile b/rtl/netware/Makefile
index 98de96a64b..03f5e8b756 100644
--- a/rtl/netware/Makefile
+++ b/rtl/netware/Makefile
@@ -3129,7 +3129,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/netwlibc/Makefile b/rtl/netwlibc/Makefile
index 981ba89934..e704c5f7c1 100644
--- a/rtl/netwlibc/Makefile
+++ b/rtl/netwlibc/Makefile
@@ -3122,7 +3122,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/openbsd/Makefile b/rtl/openbsd/Makefile
index ff9a8e5bf5..2e36ac322c 100644
--- a/rtl/openbsd/Makefile
+++ b/rtl/openbsd/Makefile
@@ -3140,7 +3140,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/os2/Makefile b/rtl/os2/Makefile
index 1abba18e7a..5b71b6e25a 100644
--- a/rtl/os2/Makefile
+++ b/rtl/os2/Makefile
@@ -3125,7 +3125,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/palmos/Makefile b/rtl/palmos/Makefile
index 24dc3ab881..ec010b5b81 100644
--- a/rtl/palmos/Makefile
+++ b/rtl/palmos/Makefile
@@ -2806,7 +2806,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/qnx/Makefile b/rtl/qnx/Makefile
index cbd3cbb93a..bfdcaed2f3 100644
--- a/rtl/qnx/Makefile
+++ b/rtl/qnx/Makefile
@@ -2507,10 +2507,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3118,7 +3126,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/solaris/Makefile b/rtl/solaris/Makefile
index 159a83f1d2..868e2fd428 100644
--- a/rtl/solaris/Makefile
+++ b/rtl/solaris/Makefile
@@ -2819,7 +2819,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/symbian/Makefile b/rtl/symbian/Makefile
index 9c0a7643ab..7176b6d94c 100644
--- a/rtl/symbian/Makefile
+++ b/rtl/symbian/Makefile
@@ -2489,7 +2489,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/wasi/Makefile b/rtl/wasi/Makefile
index bbff73fd0f..1d7452d1e0 100644
--- a/rtl/wasi/Makefile
+++ b/rtl/wasi/Makefile
@@ -1560,10 +1560,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2171,7 +2179,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/watcom/Makefile b/rtl/watcom/Makefile
index 0d6bf3300f..770f214398 100644
--- a/rtl/watcom/Makefile
+++ b/rtl/watcom/Makefile
@@ -3124,7 +3124,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/wii/Makefile b/rtl/wii/Makefile
index 25f8f2713d..05e4b9329d 100644
--- a/rtl/wii/Makefile
+++ b/rtl/wii/Makefile
@@ -2492,7 +2492,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/win16/Makefile b/rtl/win16/Makefile
index 53c74158fd..a249731ab5 100644
--- a/rtl/win16/Makefile
+++ b/rtl/win16/Makefile
@@ -2493,7 +2493,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/win32/Makefile b/rtl/win32/Makefile
index 78237537b0..3e34c574cd 100644
--- a/rtl/win32/Makefile
+++ b/rtl/win32/Makefile
@@ -3122,7 +3122,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/win64/Makefile b/rtl/win64/Makefile
index 809855dc2d..8909aa6b2f 100644
--- a/rtl/win64/Makefile
+++ b/rtl/win64/Makefile
@@ -3126,7 +3126,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/wince/Makefile b/rtl/wince/Makefile
index 0555280094..f0d1132c50 100644
--- a/rtl/wince/Makefile
+++ b/rtl/wince/Makefile
@@ -2495,7 +2495,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/rtl/zxspectrum/Makefile b/rtl/zxspectrum/Makefile
index 98c64fb8bc..2466669d10 100644
--- a/rtl/zxspectrum/Makefile
+++ b/rtl/zxspectrum/Makefile
@@ -2178,7 +2178,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/tests/Makefile b/tests/Makefile
index a0debfe836..c796c490d4 100644
--- a/tests/Makefile
+++ b/tests/Makefile
@@ -1885,7 +1885,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/tests/tstunits/Makefile b/tests/tstunits/Makefile
index 93523e6836..e5ac83b8be 100644
--- a/tests/tstunits/Makefile
+++ b/tests/tstunits/Makefile
@@ -1846,7 +1846,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/tests/utils/Makefile b/tests/utils/Makefile
index fdf149bee4..ae8efc3a5f 100644
--- a/tests/utils/Makefile
+++ b/tests/utils/Makefile
@@ -1851,7 +1851,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/tests/utils/testsuite/Makefile b/tests/utils/testsuite/Makefile
index 75924e7d76..f390667c63 100644
--- a/tests/utils/testsuite/Makefile
+++ b/tests/utils/testsuite/Makefile
@@ -3202,7 +3202,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/utils/Makefile b/utils/Makefile
index 66663047f9..a92d85e03c 100644
--- a/utils/Makefile
+++ b/utils/Makefile
@@ -2447,7 +2447,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/utils/debugsvr/Makefile b/utils/debugsvr/Makefile
index f85a359aa9..2198f80572 100644
--- a/utils/debugsvr/Makefile
+++ b/utils/debugsvr/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/utils/debugsvr/console/Makefile b/utils/debugsvr/console/Makefile
index e3379c592d..adc2da12a5 100644
--- a/utils/debugsvr/console/Makefile
+++ b/utils/debugsvr/console/Makefile
@@ -1542,10 +1542,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2507,7 +2515,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/utils/debugsvr/gtk/Makefile b/utils/debugsvr/gtk/Makefile
index 51e7ebf058..d89c730c29 100644
--- a/utils/debugsvr/gtk/Makefile
+++ b/utils/debugsvr/gtk/Makefile
@@ -1857,10 +1857,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2822,7 +2830,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/utils/dxegen/Makefile b/utils/dxegen/Makefile
index 030a2afe97..538eaf610d 100644
--- a/utils/dxegen/Makefile
+++ b/utils/dxegen/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/utils/fpcm/Makefile b/utils/fpcm/Makefile
index 51a11b8d4a..462c017682 100644
--- a/utils/fpcm/Makefile
+++ b/utils/fpcm/Makefile
@@ -2296,7 +2296,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/utils/fpcmkcfg/Makefile b/utils/fpcmkcfg/Makefile
index 18a20eba1e..d3659f697b 100644
--- a/utils/fpcmkcfg/Makefile
+++ b/utils/fpcmkcfg/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/utils/fpcres/Makefile b/utils/fpcres/Makefile
index 0f72608c6c..2512776d2d 100644
--- a/utils/fpcres/Makefile
+++ b/utils/fpcres/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/utils/fpcreslipo/Makefile b/utils/fpcreslipo/Makefile
index ce5a2fddc0..a5ef272b51 100644
--- a/utils/fpcreslipo/Makefile
+++ b/utils/fpcreslipo/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/utils/fpdoc/Makefile b/utils/fpdoc/Makefile
index 21b676c8f2..28fffa384a 100644
--- a/utils/fpdoc/Makefile
+++ b/utils/fpdoc/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/utils/fpdoc/fpde/Makefile b/utils/fpdoc/fpde/Makefile
index feaf42739c..a02672ba82 100644
--- a/utils/fpdoc/fpde/Makefile
+++ b/utils/fpdoc/fpde/Makefile
@@ -1544,10 +1544,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -3796,7 +3804,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/utils/fpmc/Makefile b/utils/fpmc/Makefile
index a557db1cca..a93cfe89fe 100644
--- a/utils/fpmc/Makefile
+++ b/utils/fpmc/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/utils/fppkg/Makefile b/utils/fppkg/Makefile
index 31ebc6905c..8b952fc5ff 100644
--- a/utils/fppkg/Makefile
+++ b/utils/fppkg/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/utils/fprcp/Makefile b/utils/fprcp/Makefile
index 958dc19021..fb50633e88 100644
--- a/utils/fprcp/Makefile
+++ b/utils/fprcp/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/utils/h2pas/Makefile b/utils/h2pas/Makefile
index 192aecc114..6fd6e44f71 100644
--- a/utils/h2pas/Makefile
+++ b/utils/h2pas/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/utils/ihxutil/Makefile b/utils/ihxutil/Makefile
index 6a2d4f52ea..09150401a1 100644
--- a/utils/ihxutil/Makefile
+++ b/utils/ihxutil/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/utils/importtl/Makefile b/utils/importtl/Makefile
index 02b6368191..e3052f7d68 100644
--- a/utils/importtl/Makefile
+++ b/utils/importtl/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/utils/instantfpc/Makefile b/utils/instantfpc/Makefile
index 1b3e0c6bd8..62fb3556c7 100644
--- a/utils/instantfpc/Makefile
+++ b/utils/instantfpc/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/utils/json2pas/Makefile b/utils/json2pas/Makefile
index e9fb7c3fa9..d91d0b30f1 100644
--- a/utils/json2pas/Makefile
+++ b/utils/json2pas/Makefile
@@ -2438,7 +2438,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/utils/mksymbian/Makefile b/utils/mksymbian/Makefile
index 3d1ea44503..2a1cd4f848 100644
--- a/utils/mksymbian/Makefile
+++ b/utils/mksymbian/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/utils/pas2fpm/Makefile b/utils/pas2fpm/Makefile
index c82e0769ee..43d1204eb0 100644
--- a/utils/pas2fpm/Makefile
+++ b/utils/pas2fpm/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/utils/pas2jni/Makefile b/utils/pas2jni/Makefile
index 4afc9d107e..3443c9c4c1 100644
--- a/utils/pas2jni/Makefile
+++ b/utils/pas2jni/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/utils/pas2js/Makefile b/utils/pas2js/Makefile
index 14ba173fa0..499adef8ef 100644
--- a/utils/pas2js/Makefile
+++ b/utils/pas2js/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/utils/pas2ut/Makefile b/utils/pas2ut/Makefile
index 3ce10ece7e..60fdb3efbe 100644
--- a/utils/pas2ut/Makefile
+++ b/utils/pas2ut/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/utils/rmwait/Makefile b/utils/rmwait/Makefile
index 125f783870..a6d82919c1 100644
--- a/utils/rmwait/Makefile
+++ b/utils/rmwait/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/utils/tply/Makefile b/utils/tply/Makefile
index eda5dd4074..6fac454a0c 100644
--- a/utils/tply/Makefile
+++ b/utils/tply/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/utils/unicode/Makefile b/utils/unicode/Makefile
index 845490910a..9f800f5fe3 100644
--- a/utils/unicode/Makefile
+++ b/utils/unicode/Makefile
@@ -2295,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif
diff --git a/utils/wasmbin/Makefile b/utils/wasmbin/Makefile
index 02a4c73ba5..839de91f0e 100644
--- a/utils/wasmbin/Makefile
+++ b/utils/wasmbin/Makefile
@@ -607,10 +607,18 @@ else
ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),mips mipsel),)
FPCMAKE_CROSSGCCOPT=-mabi=32
else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv64),)
+FPCMAKE_CROSSGCCOPT=-mabi=lp64
+else
+ifneq ($(findstring $(FPCFPMAKE_CPU_OPT),riscv32),)
+FPCMAKE_CROSSGCCOPT=-mabi=ilp32
+else
FPCMAKE_CROSSGCCOPT=-m32
endif
endif
endif
+endif
+endif
FPCMAKEGCCLIBDIR:=$(shell dirname `gcc $(FPCMAKE_CROSSGCCOPT) -print-libgcc-file-name`)
endif
endif
@@ -2287,7 +2295,7 @@ ifdef CREATESHARED
override FPCOPT+=-Cg
endif
ifneq ($(findstring $(OS_TARGET),dragonfly freebsd openbsd netbsd linux solaris),)
-ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel),)
+ifneq ($(findstring $(CPU_TARGET),x86_64 mips mipsel riscv64),)
override FPCOPT+=-Cg
endif
endif