diff --git a/.gitignore b/.gitignore index 62884e602a..1a100e9fea 100644 --- a/.gitignore +++ b/.gitignore @@ -63,6 +63,11 @@ menu/driverspzarch.c /media/shaders_glsl/ /obj-w32/ +# Wii U +*.depend +*.rpx +wiiu/wut/elf2rpl/elf2rpl + # Ctags /tags @@ -105,3 +110,5 @@ obj-unix/ /pkg/msvc/msvc-2010/Release Cg/*.obj /pkg/msvc/msvc-2010/Release Cg/*.res /pkg/msvc/msvc-2010/Release Cg/*.pdb + +retroarch.cfg diff --git a/.travis.yml b/.travis.yml index 32591afa84..73b48fb889 100644 --- a/.travis.yml +++ b/.travis.yml @@ -3,6 +3,22 @@ language: generic matrix: include: + - compiler: mingw-x86 + addons: + apt: + packages: + - g++-mingw-w64-i686 + - mingw-w64-i686-dev + script: + - CROSS_COMPILE=i686-w64-mingw32- ./configure --disable-d3d9 && make HAVE_ZLIB=1 HAVE_BUILTINZLIB=1 HAVE_RPNG=1 + - compiler: mingw-x64 + addons: + apt: + packages: + - g++-mingw-w64-x86-64 + - mingw-w64-x86-64-dev + script: + - CROSS_COMPILE=x86_64-w64-mingw32- ./configure --disable-d3d9 && make HAVE_ZLIB=1 HAVE_BUILTINZLIB=1 HAVE_RPNG=1 - compiler: gcc - compiler: clang addons: @@ -25,6 +41,7 @@ script: env: global: + - MAKEFLAGS="-j2" - secure: "qc91ReC3OlzSh2gFaSH6TYzC2qIQvgA2AZff6J13eaH8xijAhuMzttZ0rMQJ0DWCIhPeUb0kIzVyaGoe4MwPALzpw1C1AznIWiZJ53HN+hWCOcS/af7YVPk6HPySnwqrS+Wv3AIIvIKFV2mxv21F/JbT/N+pArlRrp904Xj+KPo=" addons: apt: diff --git a/CHANGES.md b/CHANGES.md index bd0623acbc..f32ebc6119 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -1,46 +1,203 @@ -# 1.5.1 (future) -- NET: Fix bug #4703 (https://github.com/libretro/RetroArch/issues/4703) +# 1.6.8 (future) +- Audio: Fix the Audio DSP picker +- GUI: (MaterialUI) Fix crash that happened on context reset with Vulkan. +- GUI: (MaterialUI) Skip querying and drawing items that are not visible; Cache content height and bbox calculation. +- GUI: (MaterialUI) Fix entry box highlight calculation. +- GUI: (XMB) Skip drawing the fading list when it is already transparent. Optimization. +- GUI: (XMB) Comment out visible item calculation in xmb_draw_items(). +- GUI: (RGUI) Prevent crashes when using a non-English language reliant on UTF8. +- GUI: Add menu option for OSD background color. +- GUI: Add menu option for OSD text color. +- GUI: Add menu option to remove frame count from OSD. +- GUI: Allow wraparound of int/float settings when pressing the left key +- INPUT: Always show the controls menu even if descriptors are not set +- INPUT: Fix input descriptors not being set on cores that don't implement the controllers interface +- INPUT: Apply descriptors only for the amount of cores the core supports +- INPUT: Implement keyboard to gamepad input remapping (limited to one gamepad device for now) +- INPUT: Fix absolute mouse move handling on the winraw driver +- INPUT: Ignore keyboard input if window is not active on udev driver +- INPUT: Sanitize the filenames of autoconfig profiles before saving +- LOBBIES: Fix crash on navigating left / right from the lobby menu +- LOCALIZATION: Update Dutch translation +- LOCALIZATION: Update Italian translation. +- LOCALIZATION: Update Japanese translation. +- LOCALIZATION: Update Portuguese-Brazilian translation. +- LOCALIZATION: Update Russian translation. +- LINUX/ARMHF: Set buildbot updater URL to armhf location instead of blank string +- LINUX/PI: Broadcom VC4: Add Videocore config option +- LINUX/UDEV: Fix - RetroArch reads keyboard input when not focused with the udev input driver. +- NETPLAY: Fix disconnection not fully deinitializing Netplay. +- COMMON: Fix clear/free loop conditionals in playlists. +- WINDOWS/GDI: Fix flickering of text. +- WINDOWS/GDI: Fix graphics corruption on Windows 98 +- WINDOWS/GDI: Allow compiling without DirectInput8 for NT support +- WINDOWS/WGL: Try to use wglSwapLayerBuffers instead of SwapBuffers if possible (for more optimal performance). +- WINDOWS: Fix menubar text corruption on Japanese locale systems +- WINDOWS: Support Unicode file I/O (can now display CJK characters in file browser for example). +- WINDOWS: Support Windows 95, NT3.51, NT4 +- WINDOWS: add Makefile.griffin targets for msvc6,2003,2005,2010,2012,2013 +- WII: Use custom, embedded libogc SDK. +- WIIU: Initial touchscreen support for WiiU gamepad. +- WIIU: Add Cheevos support. +- SCANNER: Fix archive scanning. +- SCANNER: Support CHD files. +- SCANNER: Support Gamecube ISO scanning. +- SCANNER: Use primary data track of disc images for CRC lookups rather than cue files. This is slower but finds matches more reliably, and is necessary for CHD files to work at all. Update your databases! + +# 1.6.7 +- SCANNER: Fix directory scanning. +- SCANNER: Fix file scanning. +- COMMON: Fix 'Disk Image Append' option. +- FREEBSD: Compatibility fixes for Video4Linux2 camera driver. +- GUI: (MaterialUI) Add disk image append icons. +- GUI: (MaterialUI) Improve word wrapping when menu icons are enabled. +- GUI: (MaterialUI) Add User Interface -> Appearance -> Menu Icons Enable. You can turn on/off the icons on the lefthand side of the menu entries. +- GUI: Performance optimizations for XMB menu driver - only calculates visible items. +- LOCALIZATION: Update Italian translation. + +# 1.6.6 +- 3DS: Fixes serious performance regression that affected every core; rewind was always implicitly enabled. +- AUDIO: MOD/S3M/XM sound should now be properly mixed in with the core's sound. +- GUI: Visual makeover of MaterialUI. +- GUI: Added 'Music', 'Images' and 'Video' collection options to RGUI/MaterialUI. +- GUI: Allow the user to add 'Favorites'. +- GUI: Allow the user to rename entries. +- GUI: Performance optimizations for XMB menu driver. +- LOCALIZATION: Update Italian translation +- INPUT: Overlay controller response - when we press buttons on the gamepad or keyboard, the corresponding buttons on the overlay will be highlighted as well. +- NETBSD: Silence some compilation warnings. +- COMMON: Fixed bug 'Deleting an entry from a playlist would not update the list view inside XMB'. +- COMMON: Fix inet_ntop_compat on Unix +- LOBBY: Add skeleton to add help descriptions to lobbies + +# 1.6.5 +Skipped this one. + +# 1.6.4 + +- ANDROID: Fire Stick & Fire TV remote overrides gamepad port 0 on button press and viceversa like SHIELD devices +- ANDROID: Provide default save / system / state / screenshot locations +- AUDIO: Audio mixer supports MOD/S3M/XM file types now! +- INPUT: input swap override flag (for remotes) is cleared correctly +- INPUT: allow specifying libretro device in remap files +- INPUT: allow specifying analog dpad mode in remap files +- INPUT: allow saving libretro device to remap files +- INPUT: allow saving analog dpad mode to remap files +- INPUT: allow removing core and game remap files from the menu +- COMMON: Cores can now request to set a 'shared context'. You no longer need to explicitly enable 'Shared Hardware Context' for Citra/OpenLara/Dolphin. +- COMMON: Add 'Delete Core' option to Core Information menu. +- COMMON: Allow Max Timing Skew to be set to 0. +- COMMON: Change the "content dir" behavior so it works on either a flag or an empty directory setting, now platform drivers can provide defaults for save / system / state / screenshot dirs and still allow the content dir functionality, these settings are under settings / saving and flagged as advanced +- GUI: You can turn on/off 'Horizontal Animation' now for the XMB menu. Turning animations off can result in a performance boost. +- GUI: Fix sublabel word-wrapping in XMB where multi-byte languages were cut off too soon +- LOCALIZATION: Update Dutch translation +- LOCALIZATION: Update Traditional Chinese translation +- LOCALIZATION: Update Italian translation +- LOCALIZATION: Update Russian translation +- WINDOWS: Provide default save / system / state / screenshot locations +- LOBBIES: Show what country the host is in +- MENU: Enable OSD text rendering for gdi and libcaca drivers +- WINDOWS 98/ME/2K: Set default directory for MSVC 2005 RetroArch version. +- WII: Better V-Sync handling, backported from SuperrSonic. +- WIIU: Exception handler rewritten. + +# 1.6.3 +- IOS: Fix GL regression - 32bit color format cores were no longer rendering +- CHEEVOS: Add support for N64 cheevos and other small fixes. +- CHEEVOS: Add 'Achievements -> Achievements Verbose Mode'. Ability to display cheevos related messages in OSD, useful for RetroAchievements users. +- AUDIO: Audio mixer's volume can now be independently increased/decreased, and muted. +- AUDIO: Mute now no longer disables/enables audio but instead properly mutes the audio volume. Mute is also independent from the audio mixer volume. +- INPUT: Add mouse index selection; ability now to select between different mice +- INPUT: Fix 'All Users Control Menu' setting +- LINUX: Add a tinyalsa audio driver. Doesn't require asoundlib, should be self-contained and lower-level. +- LOBBIES: Announce the RetroArch version too +- LOCALIZATION: Add Traditional Chinese translation +- LOCALIZATION: Update French translation +- LOCALIZATION: Update Italian translation +- LOCALIZATION: Update Japanese translation +- LOCALIZATION: Update Russian translation +- MENU: Add 'User Interface -> Views'. Ability to display/hide online updater and core updater options. +- NETPLAY: Disconnecting one client shouldn't cause everyone to disconnect anymore +- NETWORK: SSL/TLS support, disabled by default +- SCANNER: Fix PS1 game scanning +- SCANNER: Move content list builder into scanner task with progress, fixes menu freeze with large playlists +- SDL2: Fix 'SDL2 driver does not see the hat on wired Xbox 360 controller" +- SETTINGS: Fix regression 'Custom Viewport is no longer overridable per-core or per-game' +- VITA: Add cheevos support +- VITA: Add support for external USB if mounted +- WAYLAND: Fix menu mouse input +- WII: Add support for single-port 'PS1/PS2 to USB controller adapter + +# 1.6.0 +- ANDROID: Allow remotes to retain OK/Cancel position when menu_swap_ok_cancel is enabled +- ANDROID: Improve autoconf fallback +- ANDROID: Improve shield portable/gamepad device grouping workaround - ANDROID: Runtime permission checking -- LOCALIZATION: Update/finish French translation +- AUDIO: Audio mixer support. Mix up to 8 streams with the game's audio. +- AUTOSAVE/SRAM - Fix bug #3829 / #4820 (https://github.com/libretro/RetroArch/issues/3829) +- ENDIANNESS: Fixed database scanning. Should fix scanning on PS3/WiiU/Wii, etc. +- LOBBIES: Fallback to filename based matching if no CRC matches are found (for people making playlists by hand) +- LOBBIES: GUI refinement, show stop hosting when a host has been started, show disconnect when playing as client +- LOBBIES: if the game is already loaded it will try to connect directly instead of re-loading content (non-fullpath cores only) +- LOBBIES: unify both netplay menus +- LOCALIZATION/GUI: Korean font should display properly now with XMB/MaterialUI's default font - LOCALIZATION: Update German translation - LOCALIZATION: Update Japanese translation -- LOCALIZATION/GUI: Korean font should display properly now with XMB/MaterialUI's -default font +- LOCALIZATION: Update Russian translation +- LOCALIZATION: Update/finish French translation +- MENU: Improved rendering for XMB ribbon; using additive blending (Vulkan/GL) +- MISC: Various frontend optimizations. +- NET: Fix bug #4703 (https://github.com/libretro/RetroArch/issues/4703) +- OSX/MACOS: Fixes serious memory leak +- THUMBNAILS: Thumbnails show up now in Load Content -> Collection, Information -> Database +- VIDEO: Fix threaded video regression; tickering of menu entries would no longer work. +- VITA: Fix 30fps menu (poke into input now instead of reading the entire input buffer which apparently is slow) +- VITA: Fix frame throttle +- VITA: Fix slow I/O +- VULKAN: Fix some crashes on loading some thumbnails +- VULKAN: Unicode font rendering support. Should fix bad character encoding for French characters, etc. +- WII: Fix crashing issues which could occur with the dummy core +- WIIU: HID Controller support +- WIIU: Initial network/netplay support +- WIIU: XMB/MaterialUI menu driver support +- WINDOWS: Added RawInput input driver for low-latency, low-level input. +- WINDOWS: Added WASAPI audio driver for low-latency audio. Both shared and exclusive mode. +- WINDOWS: Core mouse input should be relative again in cores # 1.5.0 -- MOBILE: Single-tap for menu entry selection -- MOBILE: Long-tap a setting to reset to default - ANDROID: Autoconf fallback - ANDROID: Mouse support / Emulated mouse support - AUTOCONF: Fix partial matches for pad name - CHEEVOS: Fix crashes in the cheevos description menu - CHEEVOS: WIP leaderboards support -- COMMON: Threading fixes - COMMON: 9-slice texture drawing support +- COMMON: Threading fixes - CORETEXT/APPLE: Ability to load menu display font drivers and loading of custom font. - DOS: Add keyboard driver - DOS: Improve color accuracy and scaling -- GUI: Various settings are now only visible when advanced settings is enabled -- GUI: Allow changing icon theme on the fly - GUI: Add a symbol page in the OSK +- GUI: Allow changing icon theme on the fly - GUI: Better dialogs for XMB +- GUI: Various settings are now only visible when advanced settings is enabled - LOCALIZATION: Add/update Korean translation - LOCALIZATION: Rewrite German translation - LOCALIZATION: Update several English sublabels - LOCALIZATION: Update several Japanese labels +- MOBILE: Long-tap a setting to reset to default +- MOBILE: Single-tap for menu entry selection - NET: Allow manual netplay content loading - NET: Announcing network games to the public lobby is optional now - NET: Bake in miniupnpc - NET: Fix netplay join for contentless cores +- NET: Fix netplay rooms being pushed on the wrong tab - NET: Lan games show next to lobbies with (lan) and connect via the private IP address - NET: Use new lobby system with MITM support -- NET: Fix netplay rooms being pushed on the wrong tab - NUKLEAR: Update to current version - SCANNER: Always add 7z & zip to supported extensions -- VULKAN: Find supported composite alpha in swapchain - VULKAN: Add snow/bokeh shader pipeline effects - at parity with GL now +- VULKAN: Find supported composite alpha in swapchain - WIIU: Keyboard support -- WINDOWS: Logging to file no longer spawns an empty window - WINDOWS: Fix loading of core/content via file menu +- WINDOWS: Logging to file no longer spawns an empty window # 1.4.1 diff --git a/Makefile b/Makefile index db58e9059c..2a5e3c7676 100644 --- a/Makefile +++ b/Makefile @@ -13,10 +13,6 @@ TARGET = retroarch OBJDIR := obj-unix -ifeq ($(GLOBAL_CONFIG_DIR),) - GLOBAL_CONFIG_DIR = /etc -endif - OBJ := LIBS := DEFINES := -DHAVE_CONFIG_H -DRARCH_INTERNAL -DHAVE_OVERLAY @@ -78,7 +74,7 @@ ifneq ($(findstring Win32,$(OS)),) LDFLAGS += -mwindows endif -CFLAGS += -Wall $(OPTIMIZE_FLAG) $(INCLUDE_DIRS) $(DEBUG_FLAG) -I. +CFLAGS += -Wall $(OPTIMIZE_FLAG) $(INCLUDE_DIRS) $(DEBUG_FLAG) -I. -Ideps -Ideps/stb APPEND_CFLAGS := $(CFLAGS) CXXFLAGS += $(APPEND_CFLAGS) -std=c++11 -D__STDC_CONSTANT_MACROS diff --git a/Makefile.common b/Makefile.common index 56c2297c65..95012320df 100644 --- a/Makefile.common +++ b/Makefile.common @@ -1,6 +1,11 @@ ROOT_DIR := . DEPS_DIR := $(ROOT_DIR)/deps LIBRETRO_COMM_DIR := $(ROOT_DIR)/libretro-common +WANT_WGL = 0 + +ifeq ($(HAVE_STACK_USAGE), 1) +CFLAGS += -fstack-usage +endif ifeq ($(HAVE_GL_CONTEXT),) HAVE_GL_CONTEXT=0 @@ -47,10 +52,6 @@ ifeq ($(HAVE_VITA2D), 1) DEFINES += -DHAVE_VITA2D endif -ifeq ($(HAVE_FBO), 1) - DEFINES += -DHAVE_FBO -endif - ifeq ($(HAVE_DYLIB), 1) DEFINES += -DHAVE_DYLIB endif @@ -90,7 +91,7 @@ ifeq ($(HAVE_SHADERPIPELINE), 1) CFLAGS += -DHAVE_SHADERPIPELINE endif -CFLAGS += -I$(LIBRETRO_COMM_DIR)/include +CFLAGS += -I$(LIBRETRO_COMM_DIR)/include -I$(DEPS_DIR) # Switches @@ -104,7 +105,7 @@ endif ifneq ($(findstring BSD,$(OS)),) BSD_LOCAL_INC += -I/usr/local/include - OBJ += frontend/drivers/platform_bsd.o + HAVE_UNIX = 1 endif ifneq ($(findstring Darwin,$(OS)),) @@ -118,11 +119,13 @@ ifneq ($(findstring Linux,$(OS)),) LIBS += -lrt OBJ += input/drivers/linuxraw_input.o \ input/common/linux_common.o \ - input/common/epoll_common.o \ - input/drivers_joypad/linuxraw_joypad.o \ - frontend/drivers/platform_linux.o + input/drivers_joypad/linuxraw_joypad.o + HAVE_UNIX = 1 endif +ifeq ($(HAVE_UNIX), 1) + OBJ += frontend/drivers/platform_unix.o +endif ifeq ($(findstring Haiku,$(OS)),) LIBS += -lm @@ -156,25 +159,25 @@ OBJ += frontend/frontend.o \ retroarch.o \ dirs.o \ paths.o \ - input/input_keyboard.o \ command.o \ msg_hash.o \ intl/msg_hash_us.o \ - runloop.o \ $(LIBRETRO_COMM_DIR)/queues/task_queue.o \ tasks/task_content.o \ tasks/task_save.o \ tasks/task_file_transfer.o \ tasks/task_image.o \ + tasks/task_audio_mixer.o \ $(LIBRETRO_COMM_DIR)/encodings/encoding_utf.o \ $(LIBRETRO_COMM_DIR)/encodings/encoding_crc32.o \ $(LIBRETRO_COMM_DIR)/lists/file_list.o \ $(LIBRETRO_COMM_DIR)/lists/dir_list.o \ $(LIBRETRO_COMM_DIR)/file/retro_dirent.o \ + $(LIBRETRO_COMM_DIR)/streams/stdin_stream.o \ $(LIBRETRO_COMM_DIR)/streams/file_stream.o \ + $(LIBRETRO_COMM_DIR)/streams/file_stream_transforms.o \ $(LIBRETRO_COMM_DIR)/streams/interface_stream.o \ $(LIBRETRO_COMM_DIR)/streams/memory_stream.o \ - $(LIBRETRO_COMM_DIR)/file/retro_stat.o \ $(LIBRETRO_COMM_DIR)/lists/string_list.o \ $(LIBRETRO_COMM_DIR)/string/stdstring.o \ $(LIBRETRO_COMM_DIR)/memmap/memalign.o \ @@ -204,8 +207,6 @@ OBJ += frontend/frontend.o \ gfx/drivers_font_renderer/bitmapfont.o \ tasks/task_autodetect.o \ input/input_autodetect_builtin.o \ - input/input_joypad_driver.o \ - input/input_config.o \ input/input_keymaps.o \ input/input_remapping.o \ tasks/task_overlay.o \ @@ -222,7 +223,6 @@ OBJ += frontend/frontend.o \ tasks/task_powerstate.o \ $(LIBRETRO_COMM_DIR)/gfx/scaler/scaler.o \ gfx/drivers_shader/shader_null.o \ - gfx/video_shader_driver.o \ gfx/video_shader_parse.o \ $(LIBRETRO_COMM_DIR)/gfx/scaler/pixconv.o \ $(LIBRETRO_COMM_DIR)/gfx/scaler/scaler_int.o \ @@ -269,10 +269,12 @@ OBJ += intl/msg_hash_de.o \ intl/msg_hash_ko.o \ intl/msg_hash_nl.o \ intl/msg_hash_pl.o \ - intl/msg_hash_pt.o \ + intl/msg_hash_pt_br.o \ + intl/msg_hash_pt_pt.o \ intl/msg_hash_ru.o \ intl/msg_hash_vn.o \ - intl/msg_hash_chs.o + intl/msg_hash_chs.o \ + intl/msg_hash_cht.o endif @@ -332,6 +334,203 @@ OBJ += libretro-db/bintree.o \ tasks/task_database_cue.o endif +ifneq ($(C89_BUILD), 1) +HAVE_LIBUI = 0 +HAVE_GTKPLUS = 0 + +ifeq ($(HAVE_SSL), 1) +DEFINES += -DHAVE_SSL +DEFINES += -DMBEDTLS_SSL_DEBUG_ALL + +# MinGW requires this for some reason, even though the include paths are relative to the source +INCLUDE_DIRS += -Ideps/mbedtls + +OBJS_TLS_CRYPTO = deps/mbedtls/aes.o deps/mbedtls/aesni.o deps/mbedtls/arc4.o \ + deps/mbedtls/asn1parse.o deps/mbedtls/asn1write.o deps/mbedtls/base64.o \ + deps/mbedtls/bignum.o deps/mbedtls/blowfish.o deps/mbedtls/camellia.o \ + deps/mbedtls/ccm.o deps/mbedtls/cipher.o deps/mbedtls/cipher_wrap.o \ + deps/mbedtls/cmac.o deps/mbedtls/ctr_drbg.o deps/mbedtls/des.o \ + deps/mbedtls/dhm.o deps/mbedtls/ecdh.o deps/mbedtls/ecdsa.o \ + deps/mbedtls/ecjpake.o deps/mbedtls/ecp.o \ + deps/mbedtls/ecp_curves.o deps/mbedtls/entropy.o deps/mbedtls/entropy_poll.o \ + deps/mbedtls/error.o deps/mbedtls/gcm.o deps/mbedtls/havege.o \ + deps/mbedtls/hmac_drbg.o deps/mbedtls/md.o deps/mbedtls/md2.o \ + deps/mbedtls/md4.o deps/mbedtls/md5.o deps/mbedtls/md_wrap.o \ + deps/mbedtls/memory_buffer_alloc.o deps/mbedtls/oid.o \ + deps/mbedtls/padlock.o deps/mbedtls/pem.o deps/mbedtls/pk.o \ + deps/mbedtls/pk_wrap.o deps/mbedtls/pkcs12.o deps/mbedtls/pkcs5.o \ + deps/mbedtls/pkparse.o deps/mbedtls/pkwrite.o deps/mbedtls/platform.o \ + deps/mbedtls/ripemd160.o deps/mbedtls/rsa.o deps/mbedtls/sha1.o \ + deps/mbedtls/sha256.o deps/mbedtls/sha512.o deps/mbedtls/threading.o \ + deps/mbedtls/timing.o deps/mbedtls/version.o \ + deps/mbedtls/version_features.o deps/mbedtls/xtea.o + +OBJS_TLS_X509 = deps/mbedtls/certs.o deps/mbedtls/pkcs11.o deps/mbedtls/x509.o \ + deps/mbedtls/x509_create.o deps/mbedtls/x509_crl.o deps/mbedtls/x509_crt.o \ + deps/mbedtls/x509_csr.o deps/mbedtls/x509write_crt.o deps/mbedtls/x509write_csr.o + +OBJS_TLS = deps/mbedtls/debug.o deps/mbedtls/net_sockets.o \ + deps/mbedtls/ssl_cache.o deps/mbedtls/ssl_ciphersuites.o \ + deps/mbedtls/ssl_cli.o deps/mbedtls/ssl_cookie.o \ + deps/mbedtls/ssl_srv.o deps/mbedtls/ssl_ticket.o \ + deps/mbedtls/ssl_tls.o + +OBJ += $(OBJS_TLS_CRYPTO) $(OBJS_TLS_X509) $(OBJS_TLS) +endif + +ifeq ($(HAVE_LIBUI), 1) +DEFINES += -DHAVE_LIBUI +ifneq ($(findstring Win32,$(OS)),) +OBJ += deps/libui/windows/alloc.o \ + deps/libui/windows/area.o \ + deps/libui/windows/areadraw.o \ + deps/libui/windows/areaevents.o \ + deps/libui/windows/areascroll.o \ + deps/libui/windows/areautil.o \ + deps/libui/windows/box.o \ + deps/libui/windows/button.o \ + deps/libui/windows/checkbox.o \ + deps/libui/windows/colorbutton.o \ + deps/libui/windows/colordialog.o \ + deps/libui/windows/combobox.o \ + deps/libui/windows/container.o \ + deps/libui/windows/control.o \ + deps/libui/windows/d2dscratch.o \ + deps/libui/windows/datetimepicker.o \ + deps/libui/windows/debug.o \ + deps/libui/windows/draw.o \ + deps/libui/windows/drawmatrix.o \ + deps/libui/windows/drawpath.o \ + deps/libui/windows/drawtext.o \ + deps/libui/windows/dwrite.o \ + deps/libui/windows/editablecombo.o \ + deps/libui/windows/entry.o \ + deps/libui/windows/events.o \ + deps/libui/windows/fontbutton.o \ + deps/libui/windows/fontdialog.o \ + deps/libui/windows/form.o \ + deps/libui/windows/graphemes.o \ + deps/libui/windows/grid.o \ + deps/libui/windows/group.o \ + deps/libui/windows/init.o \ + deps/libui/windows/label.o \ + deps/libui/windows/main.o \ + deps/libui/windows/menu.o \ + deps/libui/windows/multilineentry.o \ + deps/libui/windows/parent.o \ + deps/libui/windows/progressbar.o \ + deps/libui/windows/radiobuttons.o \ + deps/libui/windows/separator.o \ + deps/libui/windows/sizing.o \ + deps/libui/windows/slider.o \ + deps/libui/windows/spinbox.o \ + deps/libui/windows/stddialogs.o \ + deps/libui/windows/tab.o \ + deps/libui/windows/tabpage.o \ + deps/libui/windows/text.o \ + deps/libui/windows/utf16.o \ + deps/libui/windows/utilwin.o \ + deps/libui/windows/window.o \ + deps/libui/windows/winpublic.o \ + deps/libui/windows/winutil.o +LIBS += -luxtheme -ld2d1 -ldwrite -lusp10 +else +ifneq ($(findstring Darwin,$(OS)),) +OBJ += deps/libui/darwin/alloc.o \ + deps/libui/darwin/area.o \ + deps/libui/darwin/areaevents.o \ + deps/libui/darwin/autolayout.o \ + deps/libui/darwin/box.o \ + deps/libui/darwin/button.o \ + deps/libui/darwin/checkbox.o \ + deps/libui/darwin/colorbutton.o \ + deps/libui/darwin/combobox.o \ + deps/libui/darwin/control.o \ + deps/libui/darwin/datetimepicker.o \ + deps/libui/darwin/debug.o \ + deps/libui/darwin/draw.o \ + deps/libui/darwin/drawtext.o \ + deps/libui/darwin/editablecombo.o \ + deps/libui/darwin/entry.o \ + deps/libui/darwin/fontbutton.o \ + deps/libui/darwin/form.o \ + deps/libui/darwin/grid.o \ + deps/libui/darwin/group.o \ + deps/libui/darwin/image.o \ + deps/libui/darwin/label.o \ + deps/libui/darwin/main.o \ + deps/libui/darwin/map.o \ + deps/libui/darwin/menu.o \ + deps/libui/darwin/multilineentry.o \ + deps/libui/darwin/progressbar.o \ + deps/libui/darwin/radiobuttons.o \ + deps/libui/darwin/scrollview.o \ + deps/libui/darwin/separator.o \ + deps/libui/darwin/slider.o \ + deps/libui/darwin/spinbox.o \ + deps/libui/darwin/stddialogs.o \ + deps/libui/darwin/tab.o \ + deps/libui/darwin/text.o \ + deps/libui/darwin/util.o \ + deps/libui/darwin/window.o \ + deps/libui/darwin/winmoveresize.o +else +CFLAGS += -I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include -I/usr/include/gtk-3.0 -I/usr/include/pango-1.0 -I/usr/include/cairo -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/atk-1.0 +LIBS += -lgtk-3 -lgdk-3 -lpangocairo-1.0 -lpango-1.0 -latk-1.0 -lcairo-gobject -lcairo -lgdk_pixbuf-2.0 -lgio-2.0 -lgobject-2.0 -lglib-2.0 +OBJ += deps/libui/unix/alloc.o \ + deps/libui/unix/area.o \ + deps/libui/unix/box.o \ + deps/libui/unix/button.o \ + deps/libui/unix/cellrendererbutton.o \ + deps/libui/unix/checkbox.o \ + deps/libui/unix/child.o \ + deps/libui/unix/colorbutton.o \ + deps/libui/unix/combobox.o \ + deps/libui/unix/control.o \ + deps/libui/unix/datetimepicker.o \ + deps/libui/unix/debug.o \ + deps/libui/unix/draw.o \ + deps/libui/unix/drawmatrix.o \ + deps/libui/unix/drawpath.o \ + deps/libui/unix/drawtext.o \ + deps/libui/unix/editablecombo.o \ + deps/libui/unix/entry.o \ + deps/libui/unix/fontbutton.o \ + deps/libui/unix/form.o \ + deps/libui/unix/future.o \ + deps/libui/unix/graphemes.o \ + deps/libui/unix/grid.o \ + deps/libui/unix/group.o \ + deps/libui/unix/image.o \ + deps/libui/unix/label.o \ + deps/libui/unix/main.o \ + deps/libui/unix/menu.o \ + deps/libui/unix/multilineentry.o \ + deps/libui/unix/progressbar.o \ + deps/libui/unix/radiobuttons.o \ + deps/libui/unix/separator.o \ + deps/libui/unix/slider.o \ + deps/libui/unix/spinbox.o \ + deps/libui/unix/stddialogs.o \ + deps/libui/unix/tab.o \ + deps/libui/unix/text.o \ + deps/libui/unix/util.o \ + deps/libui/unix/window.o +endif +endif + +OBJ += deps/libui/common/areaevents.o \ + deps/libui/common/control.o \ + deps/libui/common/debug.o \ + deps/libui/common/matrix.o \ + deps/libui/common/shouldquit.o \ + deps/libui/common/userbugs.o + +OBJ += deps/libui/libui_main.o +endif +endif + + # Miscellaneous ifeq ($(HAVE_STDIN_CMD), 1) @@ -368,9 +567,7 @@ endif ifeq ($(HAVE_OSS), 1) OBJ += audio/drivers/oss.o -endif - -ifeq ($(HAVE_OSS_BSD), 1) +else ifeq ($(HAVE_OSS_BSD), 1) OBJ += audio/drivers/oss.o endif @@ -384,6 +581,11 @@ endif DEFINES += $(ALSA_CFLAGS) endif +ifeq ($(HAVE_TINYALSA), 1) + OBJ += audio/drivers/tinyalsa.o + DEFINES += -DHAVE_TINYALSA +endif + ifeq ($(HAVE_ROAR), 1) OBJ += audio/drivers/roar.o LIBS += $(ROAR_LIBS) @@ -426,12 +628,17 @@ ifeq ($(HAVE_RSOUND), 1) endif ifeq ($(HAVE_DSOUND), 1) - HAVE_DIRECTX=1 OBJ += audio/drivers/dsound.o DEFINES += -DHAVE_DSOUND LIBS += -ldxguid -ldsound endif +ifeq ($(HAVE_WASAPI), 1) + OBJ += audio/drivers/wasapi.o + DEFINES += -DHAVE_WASAPI + LIBS += -lole32 -lksuser +endif + ifeq ($(HAVE_XAUDIO), 1) OBJ += audio/drivers/xaudio.o DEFINES += -DHAVE_XAUDIO @@ -518,10 +725,7 @@ endif ifeq ($(HAVE_NUKLEAR), 1) OBJ += menu/drivers/nuklear/nk_common.o OBJ += menu/drivers/nuklear/nk_menu.o - OBJ += menu/drivers/nuklear/nk_wnd_main.o - OBJ += menu/drivers/nuklear/nk_wnd_file_picker.o - OBJ += menu/drivers/nuklear/nk_wnd_shader_parameters.o - OBJ += menu/drivers/nuklear/nk_wnd_settings.o + OBJ += menu/drivers/nuklear/nk_wnd_debug.o OBJ += menu/drivers/nuklear.o DEFINES += -DHAVE_NUKLEAR endif @@ -548,7 +752,6 @@ ifeq ($(HAVE_MENU_COMMON), 1) menu/menu_input.o \ menu/menu_event.o \ menu/menu_entries.o \ - menu/menu_navigation.o \ menu/menu_setting.o \ menu/menu_shader.o \ menu/widgets/menu_filebrowser.o \ @@ -576,7 +779,6 @@ ifeq ($(HAVE_MENU_COMMON), 1) menu/cbs/menu_cbs_up.o \ menu/cbs/menu_cbs_down.o \ menu/cbs/menu_cbs_contentlist_switch.o \ - menu/menu_display.o \ menu/menu_displaylist.o \ menu/menu_animation.o \ menu/drivers_display/menu_display_null.o \ @@ -602,7 +804,6 @@ endif ifeq ($(HAVE_THREADS), 1) OBJ += $(LIBRETRO_COMM_DIR)/rthreads/rthreads.o \ - $(LIBRETRO_COMM_DIR)/rthreads/rsemaphore.o \ gfx/video_thread_wrapper.o \ audio/audio_thread_wrapper.o DEFINES += -DHAVE_THREADS @@ -640,7 +841,8 @@ endif endif ifeq ($(HAVE_WAYLAND), 1) - OBJ += gfx/drivers_context/wayland_ctx.o + OBJ += gfx/drivers_context/wayland_ctx.o \ + input/drivers/wayland_input.o DEFINES += $(WAYLAND_CFLAGS) $(WAYLAND_CURSOR_CFLAGS) LIBS += $(WAYLAND_LIBS) $(WAYLAND_CURSOR_LIBS) endif @@ -649,7 +851,6 @@ endif ifeq ($(HAVE_DINPUT), 1) LIBS += -ldinput8 -ldxguid -lole32 - HAVE_DIRECTX=1 DEFINES += -DHAVE_DINPUT OBJ += input/drivers/dinput.o \ input/drivers_joypad/dinput_joypad.o @@ -671,8 +872,7 @@ ifeq ($(HAVE_X11), 1) input/drivers/x11_input.o \ gfx/common/dbus_common.o \ gfx/common/x11_common.o \ - gfx/common/xinerama_common.o \ - input/drivers_keyboard/keyboard_event_x11.o + gfx/common/xinerama_common.o LIBS += $(X11_LIBS) $(XEXT_LIBS) $(XF86VM_LIBS) $(XINERAMA_LIBS) DEFINES += $(X11_CFLAGS) $(XEXT_CFLAGS) $(XF86VM_CFLAGS) $(XINERAMA_CFLAGS) @@ -704,8 +904,6 @@ ifeq ($(HAVE_UDEV), 1) DEFINES += $(UDEV_CFLAGS) LIBS += $(UDEV_LIBS) OBJ += input/drivers/udev_input.o \ - input/common/udev_common.o \ - input/drivers_keyboard/keyboard_event_udev.o \ input/drivers_joypad/udev_joypad.o endif @@ -734,10 +932,10 @@ endif ifeq ($(HAVE_HID), 1) DEFINES += -DHAVE_HID - OBJ += input/input_hid_driver.o \ - input/drivers_joypad/hid_joypad.o \ + OBJ += input/drivers_joypad/hid_joypad.o \ input/connect/joypad_connection.o \ input/connect/connect_ps2adapter.o \ + input/connect/connect_psxadapter.o \ input/connect/connect_ps3.o \ input/connect/connect_ps4.o \ input/connect/connect_wii.o \ @@ -751,6 +949,10 @@ ifeq ($(HAVE_PARPORT), 1) OBJ += input/drivers_joypad/parport_joypad.o endif +ifneq ($(findstring Win32,$(OS)),) + OBJ += input/drivers/winraw_input.o +endif + # Companion UI ifneq ($(findstring Win32,$(OS)),) @@ -763,14 +965,8 @@ endif # Video -OBJ += gfx/video_context_driver.o \ - gfx/drivers_context/gfx_null_ctx.o \ - gfx/video_state_tracker.o \ - $(LIBRETRO_COMM_DIR)/gfx/math/vector_2.o \ - $(LIBRETRO_COMM_DIR)/gfx/math/vector_3.o \ - $(LIBRETRO_COMM_DIR)/gfx/math/vector_4.o \ - $(LIBRETRO_COMM_DIR)/gfx/math/matrix_4x4.o \ - $(LIBRETRO_COMM_DIR)/gfx/math/matrix_3x3.o +OBJ += gfx/drivers_context/gfx_null_ctx.o \ + gfx/video_state_tracker.o ifeq ($(HAVE_KMS), 1) HAVE_AND_WILL_USE_DRM = 1 @@ -795,11 +991,14 @@ ifeq ($(HAVE_PLAIN_DRM), 1) LIBS += -ldrm endif +OBJ += \ + gfx/drivers_renderchain/null_renderchain.o + ifeq ($(HAVE_GL_CONTEXT), 1) DEFINES += -DHAVE_OPENGL -DHAVE_GLSL OBJ += gfx/drivers/gl.o \ + gfx/drivers_renderchain/gl2_renderchain.o \ $(LIBRETRO_COMM_DIR)/gfx/gl_capabilities.o \ - gfx/drivers/gl_renderchains/render_chain_gl_legacy.o \ gfx/common/gl_common.o \ gfx/drivers_font/gl_raster_font.o \ $(LIBRETRO_COMM_DIR)/glsym/rglgen.o @@ -844,7 +1043,7 @@ ifeq ($(HAVE_GL_CONTEXT), 1) ifeq ($(HAVE_FFMPEG), 1) ifneq ($(C89_BUILD), 1) ifneq ($(HAVE_OPENGLES), 1) - OBJ += cores/libretro-ffmpeg/fft/fft.o + OBJ += cores/libretro-ffmpeg/ffmpeg_fft.o DEFINES += -I$(DEPS_DIR) -DHAVE_GL_FFT NEED_CXX_LINKER=1 endif @@ -868,8 +1067,8 @@ endif GL_LIBS := -framework OpenGL OBJ += gfx/drivers_context/cgl_ctx.o else ifneq ($(findstring Win32,$(OS)),) - GL_LIBS := -lopengl32 -lgdi32 -lcomdlg32 -lcomctl32 - OBJ += gfx/drivers_context/wgl_ctx.o + GL_LIBS := -lopengl32 -lgdi32 -lcomdlg32 + WANT_WGL=1 endif LIBS += $(GL_LIBS) endif @@ -922,6 +1121,7 @@ endif ifeq ($(HAVE_VULKAN), 1) ifneq ($(findstring Win32,$(OS)),) GLSLANG_PLATFORM := Windows + WANT_WGL = 1 else GLSLANG_PLATFORM := Unix endif @@ -980,6 +1180,10 @@ ifeq ($(HAVE_VULKAN), 1) DEFINES += -DHAVE_SLANG endif +ifeq ($(WANT_WGL), 1) + OBJ += gfx/drivers_context/wgl_ctx.o +LIBS += -lcomctl32 +endif ifeq ($(HAVE_OMAP), 1) OBJ += gfx/drivers/omap_gfx.o @@ -1027,24 +1231,39 @@ ifeq ($(HAVE_CG), 1) endif ifeq ($(HAVE_D3D9), 1) - OBJ += gfx/drivers/d3d.o \ - gfx/drivers/d3d_renderchains/render_chain_null.o \ - gfx/drivers/d3d_renderchains/render_chain_driver.o \ - gfx/common/d3d_common.o \ - gfx/drivers_font/d3d_w32_font.o \ - gfx/drivers_context/d3d_ctx.o - HAVE_DIRECTX=1 - DEFINES += -DHAVE_D3D -DHAVE_D3D9 + HAVE_D3D_COMMON = 1 + DEFINES += -DHAVE_D3D9 LIBS += -ld3d9 -ld3dx9 -ldxguid + OBJ += gfx/drivers_font/d3d_w32_font.o + ifeq ($(HAVE_CG), 1) + LIBS += -lcgD3D9 + OBJ += gfx/drivers_renderchain/d3d9_cg_renderchain.o + endif + + ifeq ($(HAVE_HLSL), 1) + LIBS += -lcgD3D9 + OBJ += gfx/drivers_renderchain/d3d9_hlsl_renderchain.o \ + gfx/drivers_shader/shader_hlsl.o + endif +endif + +ifeq ($(HAVE_D3D8), 1) + HAVE_D3D_COMMON = 1 + DEFINES += -DHAVE_D3D8 + LIBS += -ld3d8 -ld3dx8 -ldxguid + + OBJ += gfx/drivers_renderchain/d3d8_renderchain.o +endif + +ifeq ($(HAVE_D3D_COMMON), 1) + DEFINES += -DHAVE_D3D + OBJ += gfx/drivers/d3d.o \ + gfx/common/d3d_common.o \ + gfx/drivers_context/d3d_ctx.o ifeq ($(HAVE_MENU_COMMON), 1) OBJ += menu/drivers_display/menu_display_d3d.o endif - - ifeq ($(HAVE_CG), 1) - LIBS += -lcgD3D9 - OBJ += gfx/drivers/d3d_renderchains/render_chain_cg.o - endif endif #ifeq ($(HAVE_LIBXML2), 1) @@ -1063,14 +1282,14 @@ OBJ += $(LIBRETRO_COMM_DIR)/file/archive_file.o \ ifeq ($(HAVE_7ZIP),1) CFLAGS += -I$(DEPS_DIR)/7zip HAVE_COMPRESSION = 1 - DEFINES += -DHAVE_7ZIP + DEFINES += -DHAVE_7ZIP -D_7ZIP_ST 7ZOBJ = $(DEPS_DIR)/7zip/7zIn.o \ - $(DEPS_DIR)/7zip/7zAlloc.o \ $(DEPS_DIR)/7zip/Bra86.o \ $(DEPS_DIR)/7zip/7zFile.o \ $(DEPS_DIR)/7zip/7zStream.o \ - $(DEPS_DIR)/7zip/7zBuf2.o \ + $(DEPS_DIR)/7zip/LzFind.o \ $(DEPS_DIR)/7zip/LzmaDec.o \ + $(DEPS_DIR)/7zip/LzmaEnc.o \ $(DEPS_DIR)/7zip/7zCrcOpt.o \ $(DEPS_DIR)/7zip/Bra.o \ $(DEPS_DIR)/7zip/7zDec.o \ @@ -1082,6 +1301,33 @@ ifeq ($(HAVE_7ZIP),1) $(7ZOBJ) endif +ifeq ($(HAVE_FLAC),1) + CFLAGS += -I$(DEPS_DIR)/libFLAC/include + DEFINES += -DHAVE_FLAC -DHAVE_STDINT_H -DHAVE_LROUND -DFLAC__HAS_OGG=0 \ + -DFLAC_PACKAGE_VERSION="\"retroarch\"" + FLACOBJ = $(DEPS_DIR)/libFLAC/bitmath.o \ + $(DEPS_DIR)/libFLAC/bitreader.o \ + $(DEPS_DIR)/libFLAC/cpu.o \ + $(DEPS_DIR)/libFLAC/crc.o \ + $(DEPS_DIR)/libFLAC/fixed.o \ + $(DEPS_DIR)/libFLAC/float.o \ + $(DEPS_DIR)/libFLAC/format.o \ + $(DEPS_DIR)/libFLAC/lpc.o \ + $(DEPS_DIR)/libFLAC/lpc_intrin_avx2.o \ + $(DEPS_DIR)/libFLAC/lpc_intrin_sse2.o \ + $(DEPS_DIR)/libFLAC/lpc_intrin_sse41.o \ + $(DEPS_DIR)/libFLAC/lpc_intrin_sse.o \ + $(DEPS_DIR)/libFLAC/md5.o \ + $(DEPS_DIR)/libFLAC/memory.o \ + $(DEPS_DIR)/libFLAC/stream_decoder.o + ifneq ($(findstring Win32,$(OS)),) + DEFINES += -DHAVE_FSEEKO + # make sure not to use this on legacy Windows versions that don't have W-functions implemented + DEFINES += -DNEED_UTF8_SUPPORT + FLACOBJ += $(DEPS_DIR)/libFLAC/windows_unicode_filenames.o + endif + OBJ += $(FLACOBJ) +endif ifeq ($(HAVE_ZLIB), 1) OBJ += $(LIBRETRO_COMM_DIR)/file/archive_file_zlib.o \ @@ -1090,6 +1336,7 @@ ifeq ($(HAVE_ZLIB), 1) DEFINES += -DHAVE_ZLIB HAVE_COMPRESSION = 1 ifeq ($(HAVE_BUILTINZLIB), 1) + INCLUDE_DIRS += -I$(LIBRETRO_COMM_DIR)/include/compat DEFINES += -DWANT_ZLIB else LIBS += -lz @@ -1117,6 +1364,11 @@ ifeq ($(HAVE_RBMP), 1) OBJ += $(LIBRETRO_COMM_DIR)/formats/bmp/rbmp.o endif +ifeq ($(HAVE_IBXM), 1) + DEFINES += -DHAVE_IBXM + OBJ += $(DEPS_DIR)/ibxm/ibxm.o +endif + OBJ += $(LIBRETRO_COMM_DIR)/formats/bmp/rbmp_encode.o \ $(LIBRETRO_COMM_DIR)/formats/json/jsonsax.o \ $(LIBRETRO_COMM_DIR)/formats/json/jsonsax_full.o \ @@ -1147,6 +1399,19 @@ OBJ += $(ZLIB_OBJS) endif endif +ifeq ($(HAVE_7ZIP),1) +ifeq ($(HAVE_FLAC),1) + DEFINES += -DHAVE_CHD -DWANT_SUBCODE -DWANT_RAW_DATA_SECTOR + CFLAGS += -I$(LIBRETRO_COMM_DIR)/formats/libchdr + OBJ += $(LIBRETRO_COMM_DIR)/formats/libchdr/bitstream.o \ + $(LIBRETRO_COMM_DIR)/formats/libchdr/cdrom.o \ + $(LIBRETRO_COMM_DIR)/formats/libchdr/chd.o \ + $(LIBRETRO_COMM_DIR)/formats/libchdr/flac.o \ + $(LIBRETRO_COMM_DIR)/formats/libchdr/huffman.o \ + $(LIBRETRO_COMM_DIR)/streams/chd_stream.o +endif +endif + # Video4Linux 2 ifeq ($(HAVE_V4L2),1) @@ -1175,6 +1440,10 @@ ifeq ($(HAVE_NETWORKING), 1) tasks/task_wifi.o \ tasks/task_netplay_find_content.o + ifeq ($(HAVE_SSL), 1) + OBJ += $(LIBRETRO_COMM_DIR)/net/net_socket_ssl.o + endif + ifneq ($(HAVE_SOCKET_LEGACY),1) OBJ += $(LIBRETRO_COMM_DIR)/net/net_ifinfo.o endif @@ -1200,14 +1469,18 @@ ifeq ($(HAVE_NETWORKING), 1) network/netplay/netplay_buf.o \ network/netplay/netplay_room_parse.o - # Retro Achievements (also depends on threads) + # Retro Achievements ifeq ($(HAVE_CHEEVOS), 1) - ifeq ($(HAVE_THREADS), 1) - DEFINES += -DHAVE_CHEEVOS - OBJ += cheevos/cheevos.o \ - $(LIBRETRO_COMM_DIR)/utils/md5.o - endif + DEFINES += -DHAVE_CHEEVOS + OBJ += cheevos/cheevos.o \ + cheevos/var.o \ + cheevos/cond.o \ + $(LIBRETRO_COMM_DIR)/utils/md5.o + endif + + ifeq ($(HAVE_KEYMAPPER), 1) + OBJ += input/input_mapper.o endif ifeq ($(HAVE_NETWORKGAMEPAD), 1) @@ -1241,7 +1514,6 @@ endif ifneq ($(findstring Win32,$(OS)),) OBJ += media/rarch.o \ - input/drivers_keyboard/keyboard_event_win32.o \ gfx/common/win32_common.o \ frontend/drivers/platform_win32.o @@ -1280,10 +1552,6 @@ ifeq ($(HAVE_COMPRESSION), 1) OBJ += tasks/task_decompress.o endif -#ifeq ($(HAVE_DIRECTX), 1) - #$DEFINES += -I"$(DXSDK_DIR)/Include" -#endif - ifeq ($(HAVE_COCOA),1) DEFINES += -DHAVE_MAIN OBJ += input/drivers/cocoa_input.o \ diff --git a/Makefile.ctr b/Makefile.ctr index 34e658c347..308c5bf62f 100644 --- a/Makefile.ctr +++ b/Makefile.ctr @@ -142,7 +142,7 @@ ifeq ($(WHOLE_ARCHIVE_LINK), 1) WHOLE_END := -Wl,--no-whole-archive endif -CFLAGS += -I. -Ideps/libz -Ideps/7zip -Ilibretro-common/include +CFLAGS += -I. -Ideps -Ideps/libz -Ideps/7zip -Ideps/stb -Ilibretro-common/include CFLAGS += -DRARCH_INTERNAL -DRARCH_CONSOLE -DSINC_LOWEST_QUALITY CFLAGS += -DHAVE_FILTERS_BUILTIN $(DEFINES) diff --git a/Makefile.ctr.salamander b/Makefile.ctr.salamander index f3f1a780f3..b53a31ff43 100644 --- a/Makefile.ctr.salamander +++ b/Makefile.ctr.salamander @@ -25,6 +25,7 @@ OBJ := ctr/ctr_system.o \ frontend/frontend_driver.o \ frontend/drivers/platform_ctr.o \ frontend/drivers/platform_null.o \ + libretro-common/encodings/encoding_utf.o \ libretro-common/compat/compat_strcasestr.o \ libretro-common/file/file_path.o \ libretro-common/string/stdstring.o \ @@ -34,7 +35,6 @@ OBJ := ctr/ctr_system.o \ libretro-common/compat/compat_strl.o \ libretro-common/file/config_file.o \ libretro-common/streams/file_stream.o \ - libretro-common/file/retro_stat.o \ libretro-common/hash/rhash.o \ file_path_str.o \ verbosity.o @@ -74,7 +74,7 @@ else CFLAGS += -O3 endif -CFLAGS += -I. -Ideps/libz -Ideps/7zip -Ilibretro-common/include +CFLAGS += -I. -Ideps/libz -Ideps/7zip -Ideps/stb -Ilibretro-common/include #CFLAGS += -DRARCH_INTERNAL CFLAGS += -DRARCH_CONSOLE -DIS_SALAMANDER diff --git a/Makefile.emscripten b/Makefile.emscripten index 3b9bcf5775..fb3a215339 100644 --- a/Makefile.emscripten +++ b/Makefile.emscripten @@ -19,7 +19,6 @@ HAVE_RGUI = 1 HAVE_SDL = 0 HAVE_SDL2 = 1 HAVE_ZLIB = 1 -HAVE_FBO = 1 WANT_ZLIB = 1 MEMORY = 536870912 @@ -72,7 +71,7 @@ OBJ += libretro-common/audio/dsp_filters/phaser.o OBJ += libretro-common/audio/dsp_filters/reverb.o OBJ += libretro-common/audio/dsp_filters/wahwah.o -CFLAGS += -Ideps/libz/ +CFLAGS += -Ideps/libz -Ideps -Ideps/stb libretro = libretro_emscripten.bc ifneq ($(V), 1) diff --git a/Makefile.griffin b/Makefile.griffin index c152619e2e..fccba281b4 100644 --- a/Makefile.griffin +++ b/Makefile.griffin @@ -1,37 +1,47 @@ -ROOT_DIR := . -DEPS_DIR := $(ROOT_DIR)/deps -DEBUG = 0 -HAVE_LOGGER = 0 -HAVE_FILE_LOGGER = 0 -HAVE_CC_RESAMPLER = 1 -WHOLE_ARCHIVE_LINK = 0 -BIG_STACK = 1 -PC_DEVELOPMENT_IP_ADDRESS = 255.255.255.255 -PC_DEVELOPMENT_UDP_PORT = 3490 -RARCH_CONSOLE = 0 -USBGECKO = 0 +ROOT_DIR := . +DEPS_DIR := $(ROOT_DIR)/deps +DEBUG = 0 +HAVE_LOGGER = 0 +HAVE_FILE_LOGGER = 0 +HAVE_CC_RESAMPLER = 1 +WHOLE_ARCHIVE_LINK = 0 +BIG_STACK = 1 +PC_DEVELOPMENT_IP_ADDRESS = 255.255.255.255 +PC_DEVELOPMENT_UDP_PORT = 3490 +RARCH_CONSOLE = 0 +USBGECKO = 0 + +UNAME_ARCH = $(shell uname -m) + +ifeq ($(UNAME_ARCH),x86_64) + HOST_ARCH = x64 +else + HOST_ARCH = x86 +endif ifneq ($(EMSCRIPTEN),) platform = emscripten endif ifeq ($(platform),) -platform = unix -ifeq ($(shell uname -a),) - platform = win -else ifneq ($(findstring MINGW,$(shell uname -a)),) - platform = win -else ifneq ($(findstring Darwin,$(shell uname -a)),) - platform = osx -else ifneq ($(findstring win,$(shell uname -a)),) - platform = win -endif + platform = unix + + ifeq ($(shell uname -a),) + platform = win + else ifneq ($(findstring MINGW,$(shell uname -a)),) + platform = win + else ifneq ($(findstring Darwin,$(shell uname -a)),) + platform = osx + else ifneq ($(findstring win,$(shell uname -a)),) + platform = win + endif endif # system platform system_platform = unix + ifeq ($(shell uname -a),) -EXE_EXT = .exe + EXE_EXT = .exe system_platform = win else ifneq ($(findstring Darwin,$(shell uname -a)),) system_platform = osx @@ -49,361 +59,807 @@ SHADER_CG_DIR := media/shaders_cg OVERLAY_DIR := media/overlays SHADER_GLSL_DIR := media/shaders_glsl -PYTHON2 := python2$(EXE_EXT) -PYTHON3 := python3$(EXE_EXT) -GIT := git$(EXE_EXT) +PYTHON2 := python2$(EXE_EXT) +PYTHON3 := python3$(EXE_EXT) +GIT := git$(EXE_EXT) ifeq ($(WHOLE_ARCHIVE_LINK), 1) WHOLE_START := -Wl,--whole-archive WHOLE_END := -Wl,--no-whole-archive endif -LIBS := $(WHOLE_START) -lretro_$(platform) $(WHOLE_END) +ifneq (,$(findstring msvc,$(platform))) + LIBS := $(WHOLE_START) $(WHOLE_END) +else + LIBS := $(WHOLE_START) -lretro_$(platform) $(WHOLE_END) +endif libogc_platform := ifeq ($(platform), ngc) -libogc_platform := 1 + libogc_platform := 1 else ifeq ($(platform), wii) -libogc_platform := 1 + libogc_platform := 1 endif # PS3 ifeq ($(platform), ps3) - #TODO - MEDIA_SHADER_DIR := pkg/ps3/USRDIR/cores/shaders - RARCH_CONSOLE = 1 + #TODO + MEDIA_SHADER_DIR := pkg/ps3/USRDIR/cores/shaders + RARCH_CONSOLE = 1 # PS3 - Cobra else ifeq ($(platform), ps3-cobra) - #TODO - MEDIA_SHADER_DIR := ps3/iso/PS3_GAME/USRDIR/cores/shaders - RARCH_CONSOLE = 1 + #TODO + MEDIA_SHADER_DIR := ps3/iso/PS3_GAME/USRDIR/cores/shaders + RARCH_CONSOLE = 1 # NGC/Wii - libogc else ifeq ($(libogc_platform), 1) - CC = $(DEVKITPPC)/bin/powerpc-eabi-gcc$(EXE_EXT) - CXX = $(DEVKITPPC)/bin/powerpc-eabi-g++$(EXE_EXT) - LD = $(DEVKITPPC)/bin/powerpc-eabi-ld$(EXE_EXT) - ELF2DOL = $(DEVKITPPC)/bin/elf2dol$(EXE_EXT) - EXT_TARGET := $(TARGET_NAME)_$(platform).dol - EXT_INTER_TARGET := $(TARGET_NAME)_$(platform).elf + EXTERNAL_LIBOGC=0 + CC = $(DEVKITPPC)/bin/powerpc-eabi-gcc$(EXE_EXT) + CXX = $(DEVKITPPC)/bin/powerpc-eabi-g++$(EXE_EXT) + LD = $(DEVKITPPC)/bin/powerpc-eabi-ld$(EXE_EXT) + ELF2DOL = $(DEVKITPPC)/bin/elf2dol$(EXE_EXT) + EXT_TARGET := $(TARGET_NAME)_$(platform).dol + EXT_INTER_TARGET := $(TARGET_NAME)_$(platform).elf - INCLUDE += -I. -I$(DEVKITPRO)/libogc/include -Ideps/libz + INCLUDE += -I. -I$(DEVKITPRO)/libogc/include -Ideps/libz -Iwii/libogc/include + + ifeq ($(EXTERNAL_LIBOGC), 1) + CFLAGS += -DEXTERNAL_LIBOGC + CXXFLAGS += -DEXTERNAL_LIBOGC -ifeq ($(platform), ngc) - LIBDIRS += -L$(DEVKITPRO)/libogc/lib/cube - MACHDEP := -DHW_DOL -mogc -else ifeq ($(platform), wii) - LIBDIRS += -L$(DEVKITPRO)/libogc/lib/wii - MACHDEP := -DHW_RVL -mrvl -endif - LIBDIRS += -L. - MACHDEP += -DGEKKO -mcpu=750 -meabi -mhard-float -DMSB_FIRST + ifeq ($(platform), ngc) + LIBDIRS += -L$(DEVKITPRO)/libogc/lib/cube + else ifeq ($(platform), wii) + LIBDIRS += -L$(DEVKITPRO)/libogc/lib/wii + endif -ifeq ($(platform), ngc) - LDFLAGS += $(MACHDEP) -Wl,-Map,$(notdir $(EXT_INTER_TARGET)).map -ifeq ($(BIG_STACK), 1) - LDFLAGS += -T bootstrap/gx/ogc.ld -endif -else ifeq ($(platform), wii) - LDFLAGS += $(MACHDEP) -Wl,-Map,$(notdir $(EXT_INTER_TARGET)).map,-wrap,malloc,-wrap,free,-wrap,memalign,-wrap,calloc,-wrap,realloc,-wrap,strdup,-wrap,strndup,-wrap,malloc_usable_size -ifeq ($(BIG_STACK), 1) - LDFLAGS += -T bootstrap/gx/rvl.ld -endif -endif - LIBS += -lfat -logc + else + CFLAGS += -DINTERNAL_LIBOGC + CXXFLAGS += -DINTERNAL_LIBOGC -ifeq ($(platform), wii) - LIBS += -lwiiuse -lbte -ifeq ($(USBGECKO), 1) - LIBS += -ldb -endif -else ifeq ($(platform), ngc) -ifeq ($(HAVE_LOGGER), 1) - LIBS += -lbba -endif -endif + ifeq ($(platform), ngc) + LIBDIRS += -Lwii/libogc/libs/cube + else ifeq ($(platform), wii) + LIBDIRS += -Lwii/libogc/libs/wii + endif - CFLAGS += -DGEKKO -U__INT32_TYPE__ -U __UINT32_TYPE__ -D__INT32_TYPE__=int + endif - HAVE_FILTERS_BUILTIN := 1 - HAVE_THREADS := 1 - HAVE_RPNG := 1 - HAVE_RJPEG := 1 - HAVE_RBMP := 1 - HAVE_RTGA := 1 - HAVE_OVERLAY := 1 - HAVE_ZLIB := 1 - WANT_ZLIB := 1 - HAVE_7ZIP := 1 - RARCH_CONSOLE = 1 + ifeq ($(platform), ngc) + MACHDEP := -DHW_DOL -mogc + else ifeq ($(platform), wii) + MACHDEP := -DHW_RVL -mrvl + endif -ifeq ($(platform), wii) - HAVE_LANGEXTRA := 1 - HAVE_WIIUSB_HID := 1 - HAVE_RARCH_EXEC := 1 - HAVE_RSOUND := 1 + LIBDIRS += -L. + MACHDEP += -DGEKKO -mcpu=750 -meabi -mhard-float -DMSB_FIRST - APP_BOOTER_DIR = wii/app_booter - PLATOBJS := $(APP_BOOTER_DIR)/app_booter.binobj -ifeq ($(USBGECKO), 1) - CFLAGS += -DUSBGECKO -endif -endif + ifeq ($(platform), ngc) + LDFLAGS += $(MACHDEP) -Wl,-Map,$(notdir $(EXT_INTER_TARGET)).map + + ifeq ($(BIG_STACK), 1) + LDFLAGS += -T bootstrap/gx/ogc.ld + endif + else ifeq ($(platform), wii) + LDFLAGS += $(MACHDEP) -Wl,-Map,$(notdir $(EXT_INTER_TARGET)).map,-wrap,malloc,-wrap,free,-wrap,memalign,-wrap,calloc,-wrap,realloc,-wrap,strdup,-wrap,strndup,-wrap,malloc_usable_size + + ifeq ($(BIG_STACK), 1) + LDFLAGS += -T bootstrap/gx/rvl.ld + endif + endif + + LIBS += -logc + + ifeq ($(EXTERNAL_LIBOGC), 1) + LIBS += -lfat + endif + + ifeq ($(platform), wii) + LIBS += -lwiiuse -lbte + + ifeq ($(USBGECKO), 1) + LIBS += -ldb + endif + else ifeq ($(platform), ngc) + ifeq ($(HAVE_LOGGER), 1) + LIBS += -lbba + endif + endif + + CFLAGS += -DGEKKO -U__INT32_TYPE__ -U __UINT32_TYPE__ -D__INT32_TYPE__=int + + HAVE_FILTERS_BUILTIN := 1 + HAVE_THREADS := 1 + HAVE_RPNG := 1 + HAVE_RJPEG := 1 + HAVE_RBMP := 1 + HAVE_RTGA := 1 + HAVE_IBXM := 1 + HAVE_OVERLAY := 1 + HAVE_ZLIB := 1 + WANT_ZLIB := 1 + HAVE_7ZIP := 1 + RARCH_CONSOLE = 1 + + ifeq ($(platform), wii) + HAVE_LANGEXTRA := 1 + HAVE_WIIUSB_HID := 1 + HAVE_RARCH_EXEC := 1 + HAVE_RSOUND := 1 + + APP_BOOTER_DIR = wii/app_booter + PLATOBJS := $(APP_BOOTER_DIR)/app_booter.binobj + + ifeq ($(USBGECKO), 1) + CFLAGS += -DUSBGECKO + endif + endif # Libxenon (Xbox 360) else ifeq ($(platform), xenon360) - CC = xenon-gcc$(EXE_EXT) - CXX = xenon-g++$(EXE_EXT) - OBJCOPY = xenon-objcopy$(EXE_EXT) - LD = xenon-ld$(EXE_EXT) - STRIP = xenon-strip$(EXE_EXT) - INCLUDE += -I$(DEVKITXENON)/usr/include + CC = xenon-gcc$(EXE_EXT) + CXX = xenon-g++$(EXE_EXT) + OBJCOPY = xenon-objcopy$(EXE_EXT) + LD = xenon-ld$(EXE_EXT) + STRIP = xenon-strip$(EXE_EXT) + INCLUDE += -I$(DEVKITXENON)/usr/include - EXT_TARGET := $(TARGET_NAME)_$(platform).elf32 - EXT_INTER_TARGET := $(TARGET_NAME)_$(platform).elf + EXT_TARGET := $(TARGET_NAME)_$(platform).elf32 + EXT_INTER_TARGET := $(TARGET_NAME)_$(platform).elf - LIBS += -lxenon -lm -lc + LIBS += -lxenon -lm -lc - LIBDIRS += -L. -L$(DEVKITXENON)/usr/lib -L$(DEVKITXENON)/xenon/lib/32 - LDFLAGS += -Wl,-q -m32 -n -T$(DEVKITXENON)/app.lds - PLATCFLAGS := -DHAVE_GETOPT_LONG=1 - PLATCFLAGS += -maltivec -mhard-float -m32 -mpowerpc64 -mcpu=cell -mtune=cell -fno-pic -g -Wall -DXENON $(INCDIRS) -Wno-char-subscripts - PLATCFLAGS += -u read -u _start -u exc_base - HAVE_THREADS := 1 - HAVE_GETOPT_LONG := 1 - RARCH_CONSOLE = 1 + LIBDIRS += -L. -L$(DEVKITXENON)/usr/lib -L$(DEVKITXENON)/xenon/lib/32 + LDFLAGS += -Wl,-q -m32 -n -T$(DEVKITXENON)/app.lds + PLATCFLAGS := -DHAVE_GETOPT_LONG=1 + PLATCFLAGS += -maltivec -mhard-float -m32 -mpowerpc64 -mcpu=cell -mtune=cell -fno-pic -g -Wall -DXENON $(INCDIRS) -Wno-char-subscripts + PLATCFLAGS += -u read -u _start -u exc_base + HAVE_THREADS := 1 + HAVE_GETOPT_LONG := 1 + RARCH_CONSOLE = 1 # PSP else ifeq ($(platform), psp1) - CC = psp-gcc$(EXE_EXT) - CXX = psp-g++$(EXE_EXT) - LD = psp-ld$(EXE_EXT) - INCLUDE += -I$(PSPSDK)/psp/sdk/include - EXT_TARGET := $(TARGET_NAME)_$(platform).elf - EXT_INTER_TARGET := $(TARGET_NAME)_$(platform).elf - PLATCFLAGS := -DPSP -D_PSP_FW_VERSION=150 -G0 \ - -D_MIPS_ARCH_ALLEGREX - LIBS += -lpspgu -lpspgum -lm -lpspaudio -lpspfpu -lpsppower -lpsprtc -lpspkernel + CC = psp-gcc$(EXE_EXT) + CXX = psp-g++$(EXE_EXT) + LD = psp-ld$(EXE_EXT) + INCLUDE += -I$(PSPSDK)/psp/sdk/include + EXT_TARGET := $(TARGET_NAME)_$(platform).elf + EXT_INTER_TARGET := $(TARGET_NAME)_$(platform).elf + PLATCFLAGS := -DPSP -D_PSP_FW_VERSION=150 -G0 \ + -D_MIPS_ARCH_ALLEGREX + LIBS += -lpspgu -lpspgum -lm -lpspaudio -lpspfpu -lpsppower -lpsprtc -lpspkernel - LIBDIRS += -L. - LDFLAGS += -Wl,-q + LIBDIRS += -L. + LDFLAGS += -Wl,-q - BUILD_PRX = 1 - HAVE_RPNG := 1 - HAVE_RJPEG := 1 - HAVE_RBMP := 1 - HAVE_RTGA := 1 - HAVE_KERNEL_PRX := 1 - HAVE_LANGEXTRA := 1 - RARCH_CONSOLE = 1 + BUILD_PRX = 1 + HAVE_RPNG := 1 + HAVE_RJPEG := 1 + HAVE_RBMP := 1 + HAVE_RTGA := 1 + HAVE_KERNEL_PRX := 1 + HAVE_LANGEXTRA := 1 + RARCH_CONSOLE = 1 -ifeq ($(BUILD_PRX), 1) - LDFLAGS += $(addprefix -L,$(PSPSDK)/lib) -specs=$(PSPSDK)/lib/prxspecs -Wl,-q,-T$(PSPSDK)/lib/linkfile.prx $(LDFLAGS) -endif + ifeq ($(BUILD_PRX), 1) + LDFLAGS += $(addprefix -L,$(PSPSDK)/lib) -specs=$(PSPSDK)/lib/prxspecs -Wl,-q,-T$(PSPSDK)/lib/linkfile.prx $(LDFLAGS) + endif # Vita else ifeq ($(platform), vita) - CC = arm-vita-eabi-gcc$(EXE_EXT) - CXX = arm-vita-eabi-g++$(EXE_EXT) - LD = arm-vita-eabi-ld$(EXE_EXT) - EXT_TARGET := $(TARGET_NAME)_$(platform).velf - EXT_INTER_TARGET := $(TARGET_NAME)_$(platform).elf - MACHDEP := -DVITA - WANT_ZLIB := 1 - INCLUDE += -Ideps/libvita2d/include - INCLUDE += -Ideps/libz - PLATCFLAGS := -marm -mfloat-abi=hard -fsingle-precision-constant \ - -mword-relocations -fno-unwind-tables -fno-asynchronous-unwind-tables -ftree-vectorize -fno-optimize-sibling-calls - LIBS += -lSceDisplay_stub -lSceGxm_stub -lSceNet_stub -lSceNetCtl_stub\ - -lSceSysmodule_stub -lSceCtrl_stub -lSceTouch_stub -lSceAudio_stub -lSceFiber_stub\ - -lScePower_stub -lSceRtc_stub -lSceCommonDialog_stub -lScePgf_stub \ - -lSceMotion_stub -lSceAppMgr_stub -lpng -lm -lc + CC = arm-vita-eabi-gcc$(EXE_EXT) + CXX = arm-vita-eabi-g++$(EXE_EXT) + LD = arm-vita-eabi-ld$(EXE_EXT) + EXT_TARGET := $(TARGET_NAME)_$(platform).velf + EXT_INTER_TARGET := $(TARGET_NAME)_$(platform).elf + MACHDEP := -DVITA + WANT_ZLIB := 1 + INCLUDE += -Ideps/libvita2d/include + INCLUDE += -Ideps/libz + PLATCFLAGS := -mfloat-abi=hard -fsingle-precision-constant \ + -mword-relocations -fno-unwind-tables -fno-asynchronous-unwind-tables -ftree-vectorize -fno-optimize-sibling-calls + LIBS += -lSceDisplay_stub -lSceGxm_stub -lSceNet_stub -lSceNetCtl_stub\ + -lSceSysmodule_stub -lSceCtrl_stub -lSceTouch_stub -lSceAudio_stub -lSceFiber_stub\ + -lScePower_stub -lSceRtc_stub -lSceCommonDialog_stub -lScePgf_stub \ + -lSceMotion_stub -lSceAppMgr_stub -lpng -lm -lc - PLATOBJS += $(DEPS_DIR)/libvita2d/shader/clear_v_gxp.o \ - $(DEPS_DIR)/libvita2d/shader/clear_f_gxp.o \ - $(DEPS_DIR)/libvita2d/shader/color_v_gxp.o \ - $(DEPS_DIR)/libvita2d/shader/color_f_gxp.o \ - $(DEPS_DIR)/libvita2d/shader/texture_v_gxp.o \ - $(DEPS_DIR)/libvita2d/shader/texture_f_gxp.o \ - $(DEPS_DIR)/libvita2d/shader/texture_tint_f_gxp.o + PLATOBJS += $(DEPS_DIR)/libvita2d/shader/clear_v_gxp.o \ + $(DEPS_DIR)/libvita2d/shader/clear_f_gxp.o \ + $(DEPS_DIR)/libvita2d/shader/color_v_gxp.o \ + $(DEPS_DIR)/libvita2d/shader/color_f_gxp.o \ + $(DEPS_DIR)/libvita2d/shader/texture_v_gxp.o \ + $(DEPS_DIR)/libvita2d/shader/texture_f_gxp.o \ + $(DEPS_DIR)/libvita2d/shader/texture_tint_f_gxp.o - PLATOBJS += \ - libretro-common/audio/conversion/s16_to_float_neon.o \ - libretro-common/audio/conversion/float_to_s16_neon.o \ - memory/neon/memcpy-neon.o \ - libretro-common/audio/resampler/drivers/sinc_resampler_neon.o \ - audio/drivers_resampler/cc_resampler_neon.o + PLATOBJS += \ + libretro-common/audio/conversion/s16_to_float_neon.o \ + libretro-common/audio/conversion/float_to_s16_neon.o \ + memory/neon/memcpy-neon.o \ + libretro-common/audio/resampler/drivers/sinc_resampler_neon.o \ + audio/drivers_resampler/cc_resampler_neon.o - LIBDIRS += -L. - LDFLAGS += -Wl,-q + LIBDIRS += -L. + LDFLAGS += -Wl,-q - HAVE_FILTERS_BUILTIN := 1 - HAVE_LANGEXTRA := 1 - HAVE_RPNG := 1 - HAVE_RJPEG := 1 - HAVE_RBMP := 1 - HAVE_RTGA := 1 - HAVE_ZLIB := 1 - HAVE_7ZIP := 1 - HAVE_VITA2D := 1 - HAVE_NETWORKING := 1 - HAVE_OVERLAY := 1 - HAVE_MATERIALUI := 1 - HAVE_XMB := 1 - HAVE_STB_FONT :=1 - RARCH_CONSOLE = 1 - HAVE_THREADS := 1 - HAVE_LIBRETRODB := 1 + HAVE_FILTERS_BUILTIN := 1 + HAVE_LANGEXTRA := 1 + HAVE_RPNG := 1 + HAVE_RJPEG := 1 + HAVE_RBMP := 1 + HAVE_RTGA := 1 + HAVE_ZLIB := 1 + HAVE_7ZIP := 1 + HAVE_VITA2D := 1 + HAVE_NETWORKING := 1 + HAVE_OVERLAY := 1 + HAVE_MATERIALUI := 1 + HAVE_XMB := 1 + HAVE_STB_FONT := 1 + HAVE_THREADS := 1 + HAVE_LIBRETRODB := 1 + RARCH_CONSOLE = 1 +else ifeq ($(platform), windows_msvc6_x86) + HAVE_RPNG := 1 + HAVE_RJPEG := 1 + HAVE_RBMP := 1 + HAVE_RTGA := 1 + HAVE_ZLIB := 1 + WANT_ZLIB := 1 + HAVE_7ZIP := 1 + HAVE_NETWORKING := 0 + HAVE_NETWORK_CMD := 1 + HAVE_OVERLAY := 1 + HAVE_MATERIALUI := 1 + HAVE_XMB := 1 + HAVE_STB_FONT := 1 + HAVE_THREADS := 1 + HAVE_LIBRETRODB := 1 + HAVE_COMMAND := 1 + HAVE_STDIN_CMD := 1 + HAVE_CMD := 1 + HAVE_DYLIB := 1 + HAVE_DYNAMIC := 1 + HAVE_GRIFFIN_CPP := 1 + + EXT_TARGET := $(TARGET_NAME).exe + EXT_INTER_TARGET := $(TARGET_NAME).exe + CC = cl.exe + CXX = cl.exe + LD = link.exe + + PLATCFLAGS += -D_WIN32 -D_WIN32_WINNT=0x0351 -D__STDC_CONSTANT_MACROS -D_MBCS + LDFLAGS += shell32.lib user32.lib gdi32.lib comdlg32.lib winmm.lib ole32.lib + + VCDIR ?= $(shell reg query "HKLM\SOFTWARE\Wow6432Node\Microsoft\DevStudio\6.0\Products\Microsoft Visual C++" -v "ProductDir" | grep -o '[A-Z]:\\.*') + + PATH := $(shell IFS=$$'\n'; cygpath "$(VCDIR)/bin"):$(PATH) + PATH := $(PATH):$(shell IFS=$$'\n'; cygpath "$(VCDIR)/../Common/MSDev98/Bin") + INCLUDE := $(shell IFS=$$'\n'; cygpath -w "$(VCDIR)/Include") + LIB := $(shell IFS=$$'\n'; cygpath -w "$(VCDIR)/Lib") + + export INCLUDE := $(INCLUDE);$(INETSDK)\Include;libretro-common\include;libretro-common\include\compat\msvc;gfx\include;deps;deps\stb + export LIB := $(LIB);$(INETSDK)\Lib +else ifeq ($(platform), windows_msvc2003_x86) + HAVE_RPNG := 1 + HAVE_RJPEG := 1 + HAVE_RBMP := 1 + HAVE_RTGA := 1 + HAVE_ZLIB := 1 + WANT_ZLIB := 1 + HAVE_7ZIP := 1 + HAVE_NETWORKING := 1 + HAVE_NETWORK_CMD := 1 + HAVE_OVERLAY := 1 + HAVE_MATERIALUI := 1 + HAVE_XMB := 1 + HAVE_STB_FONT := 1 + HAVE_THREADS := 1 + HAVE_LIBRETRODB := 1 + HAVE_COMMAND := 1 + HAVE_STDIN_CMD := 1 + HAVE_CMD := 1 + HAVE_DYLIB := 1 + HAVE_DYNAMIC := 1 + HAVE_GRIFFIN_CPP := 1 + + EXT_TARGET := $(TARGET_NAME).exe + EXT_INTER_TARGET := $(TARGET_NAME).exe + CC = cl.exe + CXX = cl.exe + LD = link.exe + + PLATCFLAGS += -D_WIN32 -DWINVER=0x0400 -D_WIN32_WINNT=0x0400 -D__STDC_CONSTANT_MACROS -D_MBCS -D_VC80_UPGRADE=0x0710 + LDFLAGS += shell32.lib user32.lib gdi32.lib comdlg32.lib winmm.lib ole32.lib + + PATH := $(shell IFS=$$'\n'; cygpath "$(VS71COMNTOOLS)../../Vc7/bin"):$(PATH) + PATH := $(PATH):$(shell IFS=$$'\n'; cygpath "$(VS71COMNTOOLS)../IDE") + INCLUDE := $(shell IFS=$$'\n'; cygpath -w "$(VS71COMNTOOLS)../../Vc7/include") + LIB := $(shell IFS=$$'\n'; cygpath -w "$(VS71COMNTOOLS)../../Vc7/lib") + + ifeq ($(HAVE_DIRECTX), 1) + PLATCFLAGS += -DHAVE_DINPUT -DHAVE_DSOUND + DXSDK_DIR := $(DXSDK_DIR:\=) + export INCLUDE := $(INCLUDE);$(INETSDK)\Include;$(DXSDK_DIR)\Include;libretro-common\include;libretro-common\include\compat\msvc;gfx\include;deps;deps\stb + export LIB := $(LIB);$(INETSDK)\Lib;$(DXSDK_DIR)\Lib\x86 + else + export INCLUDE := $(INCLUDE);$(INETSDK)\Include;libretro-common\include;libretro-common\include\compat\msvc;gfx\include;deps;deps\stb + export LIB := $(LIB);$(INETSDK)\Lib + endif +else ifeq ($(platform), windows_msvc2005_x86) + HAVE_RPNG := 1 + HAVE_RJPEG := 1 + HAVE_RBMP := 1 + HAVE_RTGA := 1 + HAVE_ZLIB := 1 + WANT_ZLIB := 1 + HAVE_7ZIP := 1 + HAVE_NETWORKING := 1 + HAVE_NETWORK_CMD := 1 + HAVE_OVERLAY := 1 + HAVE_MATERIALUI := 1 + HAVE_XMB := 1 + HAVE_STB_FONT := 1 + HAVE_THREADS := 1 + HAVE_LIBRETRODB := 1 + HAVE_COMMAND := 1 + HAVE_STDIN_CMD := 1 + HAVE_CMD := 1 + HAVE_DYLIB := 1 + HAVE_DYNAMIC := 1 + HAVE_GRIFFIN_CPP := 1 + HAVE_DIRECTX ?= 1 + + EXT_TARGET := $(TARGET_NAME).exe + EXT_INTER_TARGET := $(TARGET_NAME).exe + CC = cl.exe + CXX = cl.exe + LD = link.exe + + PLATCFLAGS += -D_WIN32 -D_WIN32_WINNT=0x0410 -D__STDC_CONSTANT_MACROS -D_MBCS + LDFLAGS += shell32.lib user32.lib gdi32.lib comdlg32.lib winmm.lib ole32.lib + + PATH := $(shell IFS=$$'\n'; cygpath "$(VS80COMNTOOLS)../../VC/bin"):$(PATH) + PATH := $(PATH):$(shell IFS=$$'\n'; cygpath "$(VS80COMNTOOLS)../IDE") + INCLUDE := $(shell IFS=$$'\n'; cygpath -w "$(VS80COMNTOOLS)../../VC/include") + LIB := $(shell IFS=$$'\n'; cygpath -w "$(VS80COMNTOOLS)../../VC/lib") + + ifeq ($(HAVE_DIRECTX), 1) + PLATCFLAGS += -DHAVE_DINPUT -DHAVE_DSOUND + DXSDK_DIR := $(DXSDK_DIR:\=) + export INCLUDE := $(INCLUDE);$(INETSDK)\Include;$(DXSDK_DIR)\Include;libretro-common\include;libretro-common\include\compat\msvc;gfx\include;deps;deps\stb + export LIB := $(LIB);$(INETSDK)\Lib;$(DXSDK_DIR)\Lib\x86 + else + export INCLUDE := $(INCLUDE);$(INETSDK)\Include;libretro-common\include;libretro-common\include\compat\msvc;gfx\include;deps;deps\stb + export LIB := $(LIB);$(INETSDK)\Lib + endif +else ifneq (,$(findstring windows_msvc2010,$(platform))) + HAVE_RPNG := 1 + HAVE_RJPEG := 1 + HAVE_RBMP := 1 + HAVE_RTGA := 1 + HAVE_ZLIB := 1 + WANT_ZLIB := 1 + HAVE_7ZIP := 1 + HAVE_NETWORKING := 1 + HAVE_NETWORK_CMD := 1 + HAVE_OVERLAY := 1 + HAVE_MATERIALUI := 1 + HAVE_XMB := 1 + HAVE_STB_FONT := 1 + HAVE_THREADS := 1 + HAVE_LIBRETRODB := 1 + HAVE_COMMAND := 1 + HAVE_STDIN_CMD := 1 + HAVE_CMD := 1 + HAVE_DYLIB := 1 + HAVE_DYNAMIC := 1 + HAVE_GRIFFIN_CPP := 1 + HAVE_DIRECTX ?= 1 + + EXT_TARGET := $(TARGET_NAME).exe + EXT_INTER_TARGET := $(TARGET_NAME).exe + CC = cl.exe + CXX = cl.exe + LD = link.exe + + PLATCFLAGS += -D_WIN32 -D__STDC_CONSTANT_MACROS -D_MBCS + PLATCFLAGS += -D__i686__ -D__SSE__ -D_CRT_NONSTDC_NO_WARNINGS -D_CRT_SECURE_NO_WARNINGS -D_WINDOWS -DHAVE_CC_RESAMPLER -DHAVE_GL_SYNC -DHAVE_GLSL -DHAVE_IMAGEVIEWER -DHAVE_LANGEXTRA -DHAVE_OPENGL -DHAVE_SHADERPIPELINE -DHAVE_UPDATE_ASSETS -DWIN32 + LDFLAGS += shell32.lib user32.lib gdi32.lib comdlg32.lib winmm.lib ole32.lib iphlpapi.lib + + PlatformSuffix = $(subst windows_msvc2010_,,$(platform)) + + ifneq (,$(findstring x64,$(PlatformSuffix))) + ifeq ($(HOST_ARCH),x86) + # cross-compile for x64 from x86 host + PATH := $(shell IFS=$$'\n'; cygpath "$(VS100COMNTOOLS)../../VC/bin/x86_amd64"):$(PATH) + else + PATH := $(shell IFS=$$'\n'; cygpath "$(VS100COMNTOOLS)../../VC/bin/amd64"):$(PATH) + endif + + LIB := $(shell IFS=$$'\n'; cygpath -w "$(VS100COMNTOOLS)../../VC/lib/amd64") + WinArch = x64 + PlatLib = Lib\x64 + else + PATH := $(shell IFS=$$'\n'; cygpath "$(VS100COMNTOOLS)../../VC/bin"):$(PATH) + LIB := $(shell IFS=$$'\n'; cygpath -w "$(VS100COMNTOOLS)../../VC/lib") + WinArch = x86 + PlatLib = Lib + endif + + PATH := $(PATH):$(shell IFS=$$'\n'; cygpath "$(VS100COMNTOOLS)../IDE") + INCLUDE := $(shell IFS=$$'\n'; cygpath -w "$(VS100COMNTOOLS)../../VC/include") + + WindowsSdkDir ?= $(shell reg query "HKLM\SOFTWARE\Microsoft\Microsoft SDKs\Windows\v7.0A" -v "InstallationFolder" | grep -o '[A-Z]:\\.*') + WindowsSdkDir ?= $(shell reg query "HKLM\SOFTWARE\Microsoft\Microsoft SDKs\Windows\v7.1A" -v "InstallationFolder" | grep -o '[A-Z]:\\.*') + WindowsSdkDir := $(WindowsSdkDir:\=) + + ifeq ($(HAVE_DIRECTX), 1) + PLATCFLAGS += -DHAVE_DINPUT -DHAVE_DSOUND -DHAVE_D3D -DHAVE_D3D9 -DHAVE_XAUDIO -DHAVE_XINPUT + DXSDK_DIR := $(DXSDK_DIR:\=) + export INCLUDE := $(INCLUDE);$(WindowsSdkDir)\Include;$(DXSDK_DIR)\Include;libretro-common\include;libretro-common\include\compat\msvc;gfx\include;deps;deps\stb + export LIB := $(LIB);$(WindowsSdkDir)\$(PlatLib);$(DXSDK_DIR)\Lib\$(WinArch) + else + export INCLUDE := $(INCLUDE);$(WindowsSdkDir)\Include;libretro-common\include;libretro-common\include\compat\msvc;gfx\include;deps;deps\stb + export LIB := $(LIB);$(WindowsSdkDir)\$(PlatLib) + endif +else ifneq (,$(findstring windows_msvc2012,$(platform))) + HAVE_RPNG := 1 + HAVE_RJPEG := 1 + HAVE_RBMP := 1 + HAVE_RTGA := 1 + HAVE_ZLIB := 1 + WANT_ZLIB := 1 + HAVE_7ZIP := 1 + HAVE_NETWORKING := 1 + HAVE_NETWORK_CMD := 1 + HAVE_OVERLAY := 1 + HAVE_MATERIALUI := 1 + HAVE_XMB := 1 + HAVE_STB_FONT := 1 + HAVE_THREADS := 1 + HAVE_LIBRETRODB := 1 + HAVE_COMMAND := 1 + HAVE_STDIN_CMD := 1 + HAVE_CMD := 1 + HAVE_DYLIB := 1 + HAVE_DYNAMIC := 1 + HAVE_GRIFFIN_CPP := 1 + HAVE_DIRECTX ?= 1 + + EXT_TARGET := $(TARGET_NAME).exe + EXT_INTER_TARGET := $(TARGET_NAME).exe + CC = cl.exe + CXX = cl.exe + LD = link.exe + + PLATCFLAGS += -D_WIN32 -D__STDC_CONSTANT_MACROS -D_MBCS + PLATCFLAGS += -D__i686__ -D__SSE__ -D_CRT_NONSTDC_NO_WARNINGS -D_CRT_SECURE_NO_WARNINGS -D_WINDOWS -DHAVE_CC_RESAMPLER -DHAVE_GL_SYNC -DHAVE_GLSL -DHAVE_IMAGEVIEWER -DHAVE_LANGEXTRA -DHAVE_OPENGL -DHAVE_SHADERPIPELINE -DHAVE_UPDATE_ASSETS -DWIN32 + LDFLAGS += shell32.lib user32.lib gdi32.lib comdlg32.lib winmm.lib ole32.lib iphlpapi.lib + + PlatformSuffix = $(subst windows_msvc2012_,,$(platform)) + + ifneq (,$(findstring x64,$(PlatformSuffix))) + ifeq ($(HOST_ARCH),x86) + # cross-compile for x64 from x86 host + PATH := $(shell IFS=$$'\n'; cygpath "$(VS110COMNTOOLS)../../VC/bin/x86_amd64"):$(PATH) + else + PATH := $(shell IFS=$$'\n'; cygpath "$(VS110COMNTOOLS)../../VC/bin/amd64"):$(PATH) + endif + + LIB := $(shell IFS=$$'\n'; cygpath -w "$(VS110COMNTOOLS)../../VC/lib/amd64") + WinArch = x64 + PlatLib = Lib\winv6.3\um\x64 + else ifneq (,$(findstring arm,$(PlatformSuffix))) + PATH := $(shell IFS=$$'\n'; cygpath "$(VS110COMNTOOLS)../../VC/bin/x86_arm"):$(PATH) + LIB := $(shell IFS=$$'\n'; cygpath -w "$(VS110COMNTOOLS)../../VC/lib/arm") + HAVE_DIRECTX = 0 + PlatLib = Lib\winv6.3\um\arm + else + PATH := $(shell IFS=$$'\n'; cygpath "$(VS110COMNTOOLS)../../VC/bin"):$(PATH) + LIB := $(shell IFS=$$'\n'; cygpath -w "$(VS110COMNTOOLS)../../VC/lib") + WinArch = x86 + PlatLib = Lib\winv6.3\um\x86 + endif + + PATH := $(PATH):$(shell IFS=$$'\n'; cygpath "$(VS110COMNTOOLS)../IDE") + INCLUDE := $(shell IFS=$$'\n'; cygpath -w "$(VS110COMNTOOLS)../../VC/include") + + WindowsSdkDir ?= $(shell reg query "HKLM\SOFTWARE\Microsoft\Windows Kits\Installed Roots" -v "KitsRoot81" | grep -o '[A-Z]:\\.*') + WindowsSdkDir := $(WindowsSdkDir:\=) + + ifeq ($(HAVE_DIRECTX), 1) + PLATCFLAGS += -DHAVE_DINPUT -DHAVE_DSOUND -DHAVE_D3D -DHAVE_D3D9 -DHAVE_XAUDIO -DHAVE_XINPUT + DXSDK_DIR := $(DXSDK_DIR:\=) + export INCLUDE := $(INCLUDE);$(WindowsSdkDir)\Include\um;$(WindowsSdkDir)\Include\shared;$(DXSDK_DIR)\Include;libretro-common\include;libretro-common\include\compat\msvc;gfx\include;deps;deps\stb + export LIB := $(LIB);$(WindowsSdkDir)\$(PlatLib);$(DXSDK_DIR)\Lib\$(WinArch) + else + export INCLUDE := $(INCLUDE);$(WindowsSdkDir)\Include\um;$(WindowsSdkDir)\Include\shared;libretro-common\include;libretro-common\include\compat\msvc;gfx\include;deps;deps\stb + export LIB := $(LIB);$(WindowsSdkDir)\$(PlatLib) + endif +else ifneq (,$(findstring windows_msvc2013,$(platform))) + HAVE_RPNG := 1 + HAVE_RJPEG := 1 + HAVE_RBMP := 1 + HAVE_RTGA := 1 + HAVE_ZLIB := 1 + WANT_ZLIB := 1 + HAVE_7ZIP := 1 + HAVE_NETWORKING := 1 + HAVE_NETWORK_CMD := 1 + HAVE_OVERLAY := 1 + HAVE_MATERIALUI := 1 + HAVE_XMB := 1 + HAVE_STB_FONT := 1 + HAVE_THREADS := 1 + HAVE_LIBRETRODB := 1 + HAVE_COMMAND := 1 + HAVE_STDIN_CMD := 1 + HAVE_CMD := 1 + HAVE_DYLIB := 1 + HAVE_DYNAMIC := 1 + HAVE_GRIFFIN_CPP := 1 + HAVE_DIRECTX ?= 1 + + EXT_TARGET := $(TARGET_NAME).exe + EXT_INTER_TARGET := $(TARGET_NAME).exe + CC = cl.exe + CXX = cl.exe + LD = link.exe + + PLATCFLAGS += -D_WIN32 -D__STDC_CONSTANT_MACROS -D_MBCS + PLATCFLAGS += -D__i686__ -D__SSE__ -D_CRT_NONSTDC_NO_WARNINGS -D_CRT_SECURE_NO_WARNINGS -D_WINDOWS -DHAVE_CC_RESAMPLER -DHAVE_GL_SYNC -DHAVE_GLSL -DHAVE_IMAGEVIEWER -DHAVE_LANGEXTRA -DHAVE_OPENGL -DHAVE_SHADERPIPELINE -DHAVE_UPDATE_ASSETS -DWIN32 + LDFLAGS += shell32.lib user32.lib gdi32.lib comdlg32.lib winmm.lib ole32.lib iphlpapi.lib + + PlatformSuffix = $(subst windows_msvc2013_,,$(platform)) + + ifneq (,$(findstring x64,$(PlatformSuffix))) + ifeq ($(HOST_ARCH),x86) + # cross-compile for x64 from x86 host + PATH := $(shell IFS=$$'\n'; cygpath "$(VS120COMNTOOLS)../../VC/bin/x86_amd64"):$(PATH) + else + PATH := $(shell IFS=$$'\n'; cygpath "$(VS120COMNTOOLS)../../VC/bin/amd64"):$(PATH) + endif + + LIB := $(shell IFS=$$'\n'; cygpath -w "$(VS120COMNTOOLS)../../VC/lib/amd64") + WinArch = x64 + PlatLib = Lib\winv6.3\um\x64 + else ifneq (,$(findstring arm,$(PlatformSuffix))) + PATH := $(shell IFS=$$'\n'; cygpath "$(VS120COMNTOOLS)../../VC/bin/x86_arm"):$(PATH) + LIB := $(shell IFS=$$'\n'; cygpath -w "$(VS120COMNTOOLS)../../VC/lib/arm") + HAVE_DIRECTX = 0 + PlatLib = Lib\winv6.3\um\arm + else + PATH := $(shell IFS=$$'\n'; cygpath "$(VS120COMNTOOLS)../../VC/bin"):$(PATH) + LIB := $(shell IFS=$$'\n'; cygpath -w "$(VS120COMNTOOLS)../../VC/lib") + WinArch = x86 + PlatLib = Lib\winv6.3\um\x86 + endif + + PATH := $(PATH):$(shell IFS=$$'\n'; cygpath "$(VS120COMNTOOLS)../IDE") + INCLUDE := $(shell IFS=$$'\n'; cygpath -w "$(VS120COMNTOOLS)../../VC/include") + + WindowsSdkDir ?= $(shell reg query "HKLM\SOFTWARE\Microsoft\Windows Kits\Installed Roots" -v "KitsRoot81" | grep -o '[A-Z]:\\.*') + WindowsSdkDir := $(WindowsSdkDir:\=) + + ifeq ($(HAVE_DIRECTX), 1) + PLATCFLAGS += -DHAVE_DINPUT -DHAVE_DSOUND -DHAVE_D3D -DHAVE_D3D9 -DHAVE_XAUDIO -DHAVE_XINPUT + DXSDK_DIR := $(DXSDK_DIR:\=) + export INCLUDE := $(INCLUDE);$(WindowsSdkDir)\Include\um;$(WindowsSdkDir)\Include\shared;$(DXSDK_DIR)\Include;libretro-common\include;libretro-common\include\compat\msvc;gfx\include;deps;deps\stb + export LIB := $(LIB);$(WindowsSdkDir)\$(PlatLib);$(DXSDK_DIR)\Lib\$(WinArch) + else + export INCLUDE := $(INCLUDE);$(WindowsSdkDir)\Include\um;$(WindowsSdkDir)\Include\shared;libretro-common\include;libretro-common\include\compat\msvc;gfx\include;deps;deps\stb + export LIB := $(LIB);$(WindowsSdkDir)\$(PlatLib) + endif endif - -CFLAGS += -Wall -std=gnu99 $(MACHDEP) $(PLATCFLAGS) $(INCLUDE) +ifneq (,$(findstring msvc,$(platform))) + CFLAGS += -W2 $(MACHDEP) $(PLATCFLAGS) +else + CFLAGS += -Wall -std=gnu99 $(MACHDEP) $(PLATCFLAGS) $(INCLUDE) + INCLUDE += -I./libretro-common/include \ + -Ideps \ + -Ideps/stb +endif OBJ = griffin/griffin.o $(PLATOBJS) -INCLUDE += -I./libretro-common/include +ifeq ($(HAVE_GRIFFIN_CPP), 1) + OBJ += griffin/griffin_cpp.o +endif ifeq ($(HAVE_LOGGER), 1) -CFLAGS += -DHAVE_LOGGER -CFLAGS += -DPC_DEVELOPMENT_IP_ADDRESS=\"$(PC_DEVELOPMENT_IP_ADDRESS)\" -DPC_DEVELOPMENT_UDP_PORT=$(PC_DEVELOPMENT_UDP_PORT) + CFLAGS += -DHAVE_LOGGER + CFLAGS += -DPC_DEVELOPMENT_IP_ADDRESS=\"$(PC_DEVELOPMENT_IP_ADDRESS)\" -DPC_DEVELOPMENT_UDP_PORT=$(PC_DEVELOPMENT_UDP_PORT) endif ifeq ($(platform), wii) -CFLAGS += -DHAVE_SOCKET_LEGACY + CFLAGS += -DHAVE_SOCKET_LEGACY endif ifeq ($(platform), vita) -CFLAGS += -DHAVE_SOCKET_LEGACY + CFLAGS += -DHAVE_SOCKET_LEGACY endif ifeq ($(HAVE_KERNEL_PRX), 1) -CFLAGS += -DHAVE_KERNEL_PRX + CFLAGS += -DHAVE_KERNEL_PRX endif ifeq ($(HAVE_WIIUSB_HID), 1) -CFLAGS += -DHAVE_WIIUSB_HID -DHAVE_HID + CFLAGS += -DHAVE_WIIUSB_HID -DHAVE_HID endif ifeq ($(HAVE_VITA2D), 1) -CFLAGS += -DHAVE_VITA2D + CFLAGS += -DHAVE_VITA2D endif ifeq ($(HAVE_LIBRETRODB), 1) -CFLAGS += -DHAVE_LIBRETRODB + CFLAGS += -DHAVE_LIBRETRODB endif ifeq ($(BIG_STACK),1) -CFLAGS += -DBIG_STACK + CFLAGS += -DBIG_STACK endif ifeq ($(HAVE_RJPEG), 1) -CFLAGS += -DHAVE_RJPEG + CFLAGS += -DHAVE_RJPEG endif ifeq ($(HAVE_FILE_LOGGER), 1) -CFLAGS += -DHAVE_FILE_LOGGER + CFLAGS += -DHAVE_FILE_LOGGER endif ifeq ($(HAVE_RARCH_EXEC), 1) -CFLAGS += -DHAVE_RARCH_EXEC + CFLAGS += -DHAVE_RARCH_EXEC endif ifeq ($(HAVE_ZLIB), 1) -CFLAGS += -DHAVE_ZLIB + CFLAGS += -DHAVE_ZLIB endif ifeq ($(WANT_ZLIB), 1) -CFLAGS += -DWANT_ZLIB + CFLAGS += -DWANT_ZLIB endif ifeq ($(HAVE_RPNG), 1) -CFLAGS += -DHAVE_RPNG + CFLAGS += -DHAVE_RPNG endif ifeq ($(HAVE_RBMP), 1) -CFLAGS += -DHAVE_RBMP + CFLAGS += -DHAVE_RBMP endif ifeq ($(HAVE_RTGA), 1) -CFLAGS += -DHAVE_RTGA + CFLAGS += -DHAVE_RTGA endif ifeq ($(HAVE_IMAGEVIEWER), 1) -CFLAGS += -DHAVE_IMAGEVIEWER + CFLAGS += -DHAVE_IMAGEVIEWER endif ifeq ($(HAVE_7ZIP), 1) -CFLAGS += -DHAVE_7ZIP + CFLAGS += -DHAVE_7ZIP endif ifeq ($(HAVE_OVERLAY), 1) -CFLAGS += -DHAVE_OVERLAY + CFLAGS += -DHAVE_OVERLAY endif ifeq ($(HAVE_NETWORKING), 1) -CFLAGS += -DHAVE_NETWORKING + CFLAGS += -DHAVE_NETWORKING endif ifeq ($(RARCH_CONSOLE), 1) -CFLAGS += -DRARCH_CONSOLE + CFLAGS += -DRARCH_CONSOLE endif ifeq ($(RARCH_MOBILE), 1) -CFLAGS += -DRARCH_MOBILE + CFLAGS += -DRARCH_MOBILE endif -CFLAGS += -std=gnu99 -DSINC_LOWER_QUALITY -DHAVE_RGUI -DHAVE_MENU -DHAVE_GRIFFIN=1 -Wno-char-subscripts -DRARCH_INTERNAL +ifneq (,$(findstring msvc,$(platform))) + CFLAGS += -DHAVE_RGUI -DHAVE_MENU -DHAVE_GRIFFIN=1 -DRARCH_INTERNAL +else + CFLAGS += -std=gnu99 -DSINC_LOWER_QUALITY -DHAVE_RGUI -DHAVE_MENU -DHAVE_GRIFFIN=1 -Wno-char-subscripts -DRARCH_INTERNAL +endif ifeq ($(HAVE_MATERIALUI), 1) -CFLAGS += -DHAVE_MATERIALUI + CFLAGS += -DHAVE_MATERIALUI endif ifeq ($(HAVE_XMB), 1) -CFLAGS += -DHAVE_XMB + CFLAGS += -DHAVE_XMB endif ifeq ($(HAVE_STB_FONT), 1) -CFLAGS += -DHAVE_STB_FONT + CFLAGS += -DHAVE_STB_FONT endif ifeq ($(HAVE_LANGEXTRA), 1) -CFLAGS += -DHAVE_LANGEXTRA + CFLAGS += -DHAVE_LANGEXTRA endif ifeq ($(HAVE_FILTERS_BUILTIN), 1) -CFLAGS += -DHAVE_FILTERS_BUILTIN + CFLAGS += -DHAVE_FILTERS_BUILTIN endif ifeq ($(HAVE_THREADS), 1) -CFLAGS += -DHAVE_THREADS -ifeq ($(platform), psp1) -LIBS += -lpthread-psp -endif -ifeq ($(platform), vita) -LIBS += -lpthread -endif + CFLAGS += -DHAVE_THREADS + + ifeq ($(platform), psp1) + LIBS += -lpthread-psp + endif + + ifeq ($(platform), vita) + LIBS += -lpthread + endif endif ifeq ($(HAVE_RSOUND), 1) -CFLAGS += -DHAVE_RSOUND + CFLAGS += -DHAVE_RSOUND endif ifeq ($(HAVE_GETOPT_LONG), 1) -CFLAGS += -DHAVE_GETOPT_LONG=1 + CFLAGS += -DHAVE_GETOPT_LONG=1 +endif + +ifeq ($(HAVE_DYLIB), 1) + CFLAGS += -DHAVE_DYLIB +endif + +ifeq ($(HAVE_NETWORK_CMD), 1) + CFLAGS += -DHAVE_NETWORK_CMD +endif + +ifeq ($(HAVE_COMMAND), 1) + CFLAGS += -DHAVE_COMMAND +endif + +ifeq ($(HAVE_STDIN_CMD), 1) + CFLAGS += -DHAVE_STDIN_CMD +endif + +ifeq ($(HAVE_DYNAMIC), 1) + CFLAGS += -DHAVE_DYNAMIC endif ifeq ($(DEBUG), 1) - CFLAGS += -O0 -g -DDEBUG + ifneq (,$(findstring msvc,$(platform))) + ifeq ($(platform), windows_msvc2003_x86) + CFLAGS += -Wp64 + endif + + CFLAGS += -Od -Zi -D_DEBUG -MTd -TP + else + CFLAGS += -O0 -g -DDEBUG + endif else ifeq ($(platform), psp1) CFLAGS += -O2 else ifeq ($(platform), vita) CFLAGS += -O3 +else ifneq (,$(findstring msvc,$(platform))) + ifeq ($(platform), windows_msvc2003_x86) + CFLAGS += -Wp64 + endif + + CFLAGS += -O2 -DNDEBUG -MT -TP else CFLAGS += -O3 endif +ifneq (,$(findstring msvc,$(platform))) + OBJOUT = -Fo + LINKOUT = -out: + LINK = link.exe +else + OBJOUT = -o + LINKOUT = -o + LINK = $(CXX) +endif + all: $(EXT_TARGET) %.dol: %.elf @@ -414,7 +870,7 @@ ifneq ($(DEBUG), 1) arm-vita-eabi-strip -g $< endif vita-elf-create $< $@ - vita-make-fself -s $@ eboot.bin + vita-make-fself -c -s $@ eboot.bin %.elf32: %.elf ifeq ($(platform), xenon360) @@ -427,19 +883,22 @@ ifeq ($(platform),psp1) endif $(EXT_INTER_TARGET): $(OBJ) - $(CXX) -o $@ $(LDFLAGS) $(LIBDIRS) $(OBJ) $(PLATEXTRA) $(LIBS) + $(LINK) $(LINKOUT)$@ $(LDFLAGS) $(LIBDIRS) $(OBJ) $(PLATEXTRA) $(LIBS) %.o: %.c - $(CC) $(CFLAGS) -c -o $@ $< + $(CC) $(CFLAGS) -c $(OBJOUT)$@ $< + +%.o: %.cpp + $(CXX) $(CFLAGS) -c $(OBJOUT)$@ $< %.o: %.S - $(CC) $(CFLAGS) -c -o $@ $< + $(CC) $(CFLAGS) -c $(OBJOUT)$@ $< %.bmpobj: %.bmp - $(LD) -r -b binary -o $@ $< + $(LD) -r -b binary $(OBJOUT)$@ $< %.binobj: %.bin - $(LD) -r -b binary -o $@ $< + $(LD) -r -b binary $(OBJOUT)$@ $< $(APP_BOOTER_DIR)/app_booter.bin: $(MAKE) -C $(APP_BOOTER_DIR) @@ -455,32 +914,32 @@ endif shaders-checkout: @if test -d $(SHADER_CG_DIR); then \ - echo "[SHADER CHECKOUT::] Git pulling common-shaders..."; \ + echo "[SHADER CHECKOUT::] Git pulling common-shaders..."; \ cd $(SHADER_CG_DIR); \ - $(GIT) pull; \ - cd ../../../../..; \ - else \ - echo "[SHADER CHECKOUT::] Git cloning common-shaders first..."; \ + $(GIT) pull; \ + cd ../../../../..; \ + else \ + echo "[SHADER CHECKOUT::] Git cloning common-shaders first..."; \ $(GIT) clone git://github.com/libretro/common-shaders.git $(SHADER_CG_DIR); \ - fi + fi shaders-deploy: ifeq ($(platform), ps3) @if test -d $(MEDIA_SHADER_DIR); then \ - cp -r $(SHADER_CG_DIR)/* $(MEDIA_SHADER_DIR); \ - else \ - echo "[DEPLOY PS3::] Creating PS3 shader directory first..."; \ - mkdir -p $(MEDIA_SHADER_DIR) || bin/true; \ - fi - @echo "[DEPLOY PS3::] Copied shaders to PS3 shaders directory." + cp -r $(SHADER_CG_DIR)/* $(MEDIA_SHADER_DIR); \ + else \ + echo "[DEPLOY PS3::] Creating PS3 shader directory first..."; \ + mkdir -p $(MEDIA_SHADER_DIR) || bin/true; \ + fi + @echo "[DEPLOY PS3::] Copied shaders to PS3 shaders directory." else ifeq ($(platform), ps3-cobra) @if test -d $(MEDIA_SHADER_DIR); then \ - cp -r $(SHADER_CG_DIR)/* $(MEDIA_SHADER_DIR); \ - else \ - echo "[DEPLOY PS3::] Creating PS3 shader directory first..."; \ - mkdir -p $(MEDIA_SHADER_DIR) || bin/true; \ - fi - @echo "[DEPLOY PS3::] Copied shaders to PS3 shaders directory." + cp -r $(SHADER_CG_DIR)/* $(MEDIA_SHADER_DIR); \ + else \ + echo "[DEPLOY PS3::] Creating PS3 shader directory first..."; \ + mkdir -p $(MEDIA_SHADER_DIR) || bin/true; \ + fi + @echo "[DEPLOY PS3::] Copied shaders to PS3 shaders directory." endif shaders-convert-glsl: @@ -488,14 +947,14 @@ shaders-convert-glsl: overlays-checkout: @if test -d $(OVERLAY_DIR); then \ - echo "[OVERLAY CHECKOUT::] Git pulling common-overlays..."; \ + echo "[OVERLAY CHECKOUT::] Git pulling common-overlays..."; \ cd $(OVERLAY_DIR); \ - $(GIT) pull; \ - cd ../../../../..; \ - else \ - echo "[OVERLAY CHECKOUT::] Git cloning common-overlays first..."; \ + $(GIT) pull; \ + cd ../../../../..; \ + else \ + echo "[OVERLAY CHECKOUT::] Git cloning common-overlays first..."; \ $(GIT) clone git://github.com/libretro/common-overlays.git $(OVERLAY_DIR); \ - fi + fi clean: @@ -507,3 +966,6 @@ ifeq ($(platform), wii) endif .PHONY: clean + +print-%: + @echo '$*=$($*)' diff --git a/Makefile.libogc b/Makefile.libogc new file mode 100644 index 0000000000..77d3bf6c5f --- /dev/null +++ b/Makefile.libogc @@ -0,0 +1,358 @@ +#--------------------------------------------------------------------------------- +.SUFFIXES: +#--------------------------------------------------------------------------------- + +ifeq ($(strip $(DEVKITPRO)),) +$(error "Please set DEVKITPRO in your environment. export DEVKITPRO=devkitPro") +endif + +ifeq ($(strip $(DEVKITPPC)),) +$(error "Please set DEVKITPPC in your environment. export DEVKITPPC=devkitPPC") +endif + +export PATH := $(DEVKITPPC)/bin:$(PATH) + +ifeq ($(PLATFORM),) +PLATFORM=wii +endif + +#--------------------------------------------------------------------------------- +# change shell on Snow Leopard +#--------------------------------------------------------------------------------- +UNAME_S := $(shell uname -s) +UNAME_R := $(shell uname -r) + +ifneq (,$(findstring Darwin,$(UNAME_S))) + ifneq (,$(findstring 10.8.0,$(UNAME_R))) + export SHELL=/bin/bash + endif +endif + +#--------------------------------------------------------------------------------- +# path to tools +#--------------------------------------------------------------------------------- +export PORTLIBS := $(DEVKITPRO)/portlibs/ppc +export PATH := $(DEVKITPPC)/bin:$(PORTLIBS)/bin:$(PATH) + +#--------------------------------------------------------------------------------- +# the prefix on the compiler executables +#--------------------------------------------------------------------------------- +PREFIX := powerpc-eabi- + +export AS := $(PREFIX)as +export CC := $(PREFIX)gcc +export CXX := $(PREFIX)g++ +export AR := $(PREFIX)ar +export OBJCOPY := $(PREFIX)objcopy + + +ISVC=$(or $(VCBUILDHELPER_COMMAND),$(MSBUILDEXTENSIONSPATH32),$(MSBUILDEXTENSIONSPATH)) + +#--------------------------------------------------------------------------------- +%.a: +#--------------------------------------------------------------------------------- + @rm -f $@ + $(AR) -rc $@ $^ + +#--------------------------------------------------------------------------------- +%.o: %.cpp + $(CXX) $(CXXFLAGS) -c $< -o $@ + +#--------------------------------------------------------------------------------- +%.o: %.c + $(CC) $(CFLAGS) -c $< -o $@ + +#--------------------------------------------------------------------------------- +%.o: %.m + $(CC) $(OBJCFLAGS) -c $< -o $@ + +#--------------------------------------------------------------------------------- +%.o: %.s + $(CC) -x assembler-with-cpp $(ASFLAGS) -c $< -o $@ + +#--------------------------------------------------------------------------------- +%.o: %.S + $(CC) -x assembler-with-cpp $(ASFLAGS) -c $< -o $@ + +#--------------------------------------------------------------------------------- +# canned command sequence for binary data +#--------------------------------------------------------------------------------- +define bin2o + bin2s -a 32 $< | $(AS) -o $(@) + echo "extern const u8" `(echo $( `(echo $(> `(echo $(> `(echo $(devkitPPC") @@ -101,7 +134,7 @@ else endif -INCDIRS := -I. -Ideps/libz -Ideps/7zip -Ilibretro-common/include -Iwiiu -Iwiiu/include -I$(DEVKITPRO)/portlibs/ppc/include +INCDIRS := -I. -Ideps -Ideps/stb -Ideps/libz -Ideps/7zip -Ilibretro-common/include -Iwiiu -Iwiiu/include -I$(DEVKITPRO)/portlibs/ppc/include LIBDIRS := -L. -L$(DEVKITPRO)/portlibs/ppc/lib CFLAGS := -mwup -mcpu=750 -meabi -mhard-float @@ -123,6 +156,7 @@ CFLAGS += -ffast-math -Werror=implicit-function-declaration #todo: remove -DWIIU and use the built-in macros instead (HW_WUP or __wiiu__). CFLAGS += -DWIIU -DMSB_FIRST CFLAGS += -DHAVE_MAIN +CFLAGS += -DHAVE_UPDATE_ASSETS CFLAGS += -DRARCH_INTERNAL -DRARCH_CONSOLE CFLAGS += -DHAVE_FILTERS_BUILTIN $(DEFINES) @@ -138,7 +172,7 @@ ifeq ($(WHOLE_ARCHIVE_LINK), 1) WHOLE_START := -Wl,--whole-archive WHOLE_END := -Wl,--no-whole-archive endif -CXXFLAGS := $(CFLAGS) -fno-rtti -fno-exceptions +CXXFLAGS := $(CFLAGS) -fno-rtti -fno-exceptions -D_GNU_SOURCE LDFLAGS += -Wl,--gc-sections @@ -172,41 +206,50 @@ all: $(TARGETS) %.o: %.cpp %.o: %.cpp %.depend - $(CXX) -c -o $@ $< $(CXXFLAGS) $(INCDIRS) $(DEPFLAGS) - $(POSTCOMPILE) + @$(if $(Q), echo CXX $<,) + $(Q)$(CXX) -c -o $@ $< $(CXXFLAGS) $(INCDIRS) $(DEPFLAGS) + $(Q)$(POSTCOMPILE) %.o: %.c %.o: %.c %.depend - $(CC) -c -o $@ $< $(CFLAGS) $(INCDIRS) $(DEPFLAGS) - $(POSTCOMPILE) + @$(if $(Q), echo CC $<,) + $(Q)$(CC) -c -o $@ $< $(CFLAGS) $(INCDIRS) $(DEPFLAGS) + $(Q)$(POSTCOMPILE) %.o: %.S %.o: %.S %.depend - $(CC) -c -o $@ $< $(ASFLAGS) $(INCDIRS) $(DEPFLAGS) - $(POSTCOMPILE) + @$(if $(Q), echo AS $<,) + $(Q)$(CC) -c -o $@ $< $(ASFLAGS) $(INCDIRS) $(DEPFLAGS) + $(Q)$(POSTCOMPILE) %.o: %.s %.o: %.s %.depend - $(CC) -c -o $@ $< $(ASFLAGS) $(INCDIRS) $(DEPFLAGS) - $(POSTCOMPILE) + @$(if $(Q), echo AS $<,) + $(Q)$(CC) -c -o $@ $< $(ASFLAGS) $(INCDIRS) $(DEPFLAGS) + $(Q)$(POSTCOMPILE) %.a: - $(AR) -rc $@ $^ + @$(if $(Q), echo AR $<,) + $(Q)$(AR) -rc $@ $^ %.depend: ; $(ELF2RPL): - $(MAKE) -C wiiu/wut/elf2rpl/ + @$(if $(Q), echo MAKE $@,) + $(Q)$(MAKE) -C wiiu/wut/elf2rpl/ $(TARGET).elf: $(OBJ) $(HBL_ELF_OBJ) libretro_wiiu.a wiiu/link_elf.ld - $(LD) $(OBJ) $(HBL_ELF_OBJ) $(LDFLAGS) $(HBL_ELF_LDFLAGS) $(LIBDIRS) $(LIBS) -o $@ + @$(if $(Q), echo LD $@,) + $(Q)$(LD) $(OBJ) $(HBL_ELF_OBJ) $(LDFLAGS) $(HBL_ELF_LDFLAGS) $(LIBDIRS) $(LIBS) -o $@ $(TARGET).rpx.elf: $(OBJ) $(RPX_OBJ) libretro_wiiu.a wiiu/link_elf.ld - $(LD) $(OBJ) $(RPX_OBJ) $(LDFLAGS) $(RPX_LDFLAGS) $(LIBDIRS) $(LIBS) -o $@ + @$(if $(Q), echo LD $@,) + $(Q)$(LD) $(OBJ) $(RPX_OBJ) $(LDFLAGS) $(RPX_LDFLAGS) $(LIBDIRS) $(LIBS) -o $@ $(TARGET).rpx: $(TARGET).rpx.elf $(ELF2RPL) - -$(ELF2RPL) $(TARGET).rpx.elf $@ + @$(if $(Q), echo ELF2RPL $@,) + $(Q)-$(ELF2RPL) $(TARGET).rpx.elf $@ clean: rm -f $(OBJ) $(RPX_OBJ) $(HBL_ELF_OBJ) $(TARGET).elf $(TARGET).rpx.elf $(TARGET).rpx diff --git a/Makefile.wiiu.salamander b/Makefile.wiiu.salamander index 4a292d99fd..221d8193d1 100644 --- a/Makefile.wiiu.salamander +++ b/Makefile.wiiu.salamander @@ -16,6 +16,7 @@ OBJ += frontend/frontend_salamander.o OBJ += frontend/frontend_driver.o OBJ += frontend/drivers/platform_wiiu.o OBJ += frontend/drivers/platform_null.o +OBJ += libretro-common/encodings/encoding_utf.o OBJ += libretro-common/compat/compat_strcasestr.o OBJ += libretro-common/file/file_path.o OBJ += libretro-common/string/stdstring.o @@ -25,7 +26,6 @@ OBJ += libretro-common/file/retro_dirent.o OBJ += libretro-common/compat/compat_strl.o OBJ += libretro-common/file/config_file.o OBJ += libretro-common/streams/file_stream.o -OBJ += libretro-common/file/retro_stat.o OBJ += libretro-common/hash/rhash.o OBJ += file_path_str.o OBJ += verbosity.o diff --git a/Makefile.win b/Makefile.win index a198553aa7..26c3f7aa37 100644 --- a/Makefile.win +++ b/Makefile.win @@ -3,8 +3,8 @@ TARGET = retroarch.exe HAVE_DINPUT = 1 HAVE_XAUDIO = 1 HAVE_DSOUND = 1 +HAVE_WASAPI = 1 HAVE_OPENGL = 1 -HAVE_FBO = 1 HAVE_DYLIB = 1 HAVE_D3D9 = 1 HAVE_NETWORKING = 1 @@ -121,8 +121,8 @@ else CXXFLAGS += -O3 -ffast-math endif -CFLAGS += -Wall -Wno-unused-result -Wno-unused-variable -I. -CXXFLAGS += -Wall -Wno-unused-result -Wno-unused-variable -I. -std=c++98 -D__STDC_CONSTANT_MACROS +CFLAGS += -Wall -Wno-unused-result -Wno-unused-variable -I. -Ideps +CXXFLAGS += -Wall -Wno-unused-result -Wno-unused-variable -I. -Ideps -std=c++98 -D__STDC_CONSTANT_MACROS ifeq ($(CXX_BUILD), 1) CFLAGS += -std=c++98 -xc++ -D__STDC_CONSTANT_MACROS else diff --git a/README.md b/README.md index 07a4cee642..c1f633fbd2 100644 --- a/README.md +++ b/README.md @@ -8,6 +8,12 @@ Popular examples of implementations for this API includes videogame system emula more generalized 3D programs. These programs are instantiated as dynamic libraries. We refer to these as "libretro cores". +![XMB menu driver](http://i.imgur.com/BMR1xxr.png "XMB menu driver") + +![rgui menu driver](http://i.imgur.com/X3CbBKa.png "rgui menu driver") + +![glui menu driver](http://i.imgur.com/ooqv8rw.png "glui menu driver") + ## libretro [libretro](http://libretro.com) is an API that exposes generic audio/video/input callbacks. @@ -30,13 +36,16 @@ or visit our IRC channel: #retroarch @ irc.freenode.org. ## Documentation -See our [wiki](https://github.com/libretro/RetroArch/wiki). On Unix, man-pages are provided. +See our [Documentation Center](https://docs.libretro.com/). On Unix, man-pages are provided. More developer-centric stuff is found [here](https://github.com/libretro/libretro.github.com/wiki/Documentation-devs). ## Related projects - Cg/HLSL shaders: [common-shaders](https://github.com/libretro/common-shaders) + - slang shaders: [slang-shaders](https://github.com/libretro/slang-shaders) + - GLSL shaders: [glsl-shaders](https://github.com/libretro/glsl-shaders) - Helper scripts to build libretro implementations: [libretro-super](https://github.com/libretro/libretro-super) + - GitHub mirrors of projects, useful for generating diff files: [libretro-mirrors](https://github.com/libretro-mirrors/) ## Philosophy @@ -52,12 +61,19 @@ RetroArch also emphasizes on being easy to integrate into various launcher front ## Platforms -RetroArch has been ported to the following platforms outside PC: +RetroArch has been ported to the following platforms: + - Windows + - Linux + - FreeBSD + - NetBSD + - MacOS - PlayStation 3 + - PlayStation Portable + - Original Xbox - Xbox 360 (Libxenon/XeXDK) - - Xbox 1 - - Wii, Gamecube (Libogc) + - Wii, GameCube (Libogc) + - WiiU - Nintendo 3DS - Raspberry Pi - Android @@ -119,94 +135,5 @@ Users only need to configure a certain option if the desired value deviates from To configure joypads, use the built-in menu or the `retroarch-joyconfig` command-line tool. ## Compiling and installing -**Linux** -- Prerequisites: -```bash -sudo apt-get install -y make git-core curl g++ pkg-config libglu1-mesa-dev freeglut3-dev mesa-common-dev libsdl1.2-dev libsdl-image1.2-dev libsdl-mixer1.2-dev libsdl-ttf2.0-dev -``` -- Compiling: -```bash -./configure -make -``` - -**Mac** - -- Prerequisites: [XCode](https://www.google.com/url?sa=t&rct=j&q=&esrc=s&source=web&cd=1&cad=rja&uact=8&ved=0CB4QFjAA&url=https%3A%2F%2Fitunes.apple.com%2Fus%2Fapp%2Fxcode%2Fid497799835%3Fmt%3D12&ei=ZmfeVNPtIILVoASBnoCYBw&usg=AFQjCNGrxKmVtXUdvUU3MhqZhP4MHT6Gtg&sig2=RIXKsWQ79YTQBt_lK5fdKA&bvm=bv.85970519,d.cGU), [Cg](https://developer.nvidia.com/cg-toolkit-download). -- You can open the project (**pkg/apple/RetroArch.xcodeproj**) in the Xcode IDE and build (**⌘-B**) and run (**⌘-R**) it there. Or you can use the command line... -- Debug: -```bash -# Build -xcodebuild -target RetroArch -configuration Debug -project pkg/apple/RetroArch.xcodeproj -# Run -open ./pkg/apple/build/Debug/RetroArch.app/ -``` -- Release: -```bash -# Build -xcodebuild -target RetroArch -configuration Release -project pkg/apple/RetroArch.xcodeproj -# Run -open ./pkg/apple/build/Release/RetroArch.app/ -``` - -**PC** - -Instructions for compiling on PC can be found in the [wiki](https://github.com/Themaister/RetroArch/wiki). - -**PlayStation 3** - -RetroArch PS3 needs to be compiled in the following order: - -1) Compile RetroArch Salamander - - make -f Makefile.ps3.salamander - -2) Finally, compile RetroArch packed together with the GUI: - - make -f Makefile.ps3 - -**PlayStation 3 - Creating a PKG installable file** - -You can add `pkg` as a parameter in order to make a PKG file - for example: - - make -f Makefile.ps3 pkg - -This creates an NPDRM package. This can be installed on debug PS3s. - -To make a non-NPDRM package that can be installed on a jailbroken/CFW PS3 (such as PSGroove or PS3 CFWs and other 3.55 CFW derivatives), do: - - make -f Makefile.ps3 pkg-signed - -If you're using Kmeaw 3.55 firmware, the package needs to be signed: - - make -f Makefile.ps3 pkg-signed-cfw - -NOTE: A pre-existing libretro library needs to be present in the root directory in order to link RetroArch PS3. This file needs to be called ***`libretro_ps3.a`***. - -**Xbox 360 (XeXDK)** - -You will need Microsoft Visual Studio 2010 installed (or higher) in order to compile RetroArch 360. - -The solution file can be found at the following location: - - pkg/msvc-360/RetroArch-360.sln - -NOTE: A pre-existing libretro library needs to be present in the `pkg/msvc-360/RetroArch-360/Release` directory in order to link RetroArch 360. This file needs to be -called ***`libretro_xdk360.lib`***. - -**Xbox 360 (Libxenon)** - -You will need to have the libxenon libraries and a working Devkit Xenon toolchain installed in order to compile RetroArch 360 Libxenon. - - make -f Makefile.xenon - -NOTE: A pre-existing libretro library needs to be present in the root directory in order to link RetroArch 360 Libxenon. This file needs to be called ***`libretro_xenon360.a`***. - -**Wii** - -You will need to have the libogc libraries and a working Devkit PPC toolchain installed in order to compile RetroArch Wii. - - make -f Makefile.griffin platform=wii - -NOTE: A pre-existing libretro library needs to be present in the root directory in order to link RetroArch Wii. This file needs to be called ***`libretro_wii.a`***. +Instructions for compiling and installing RetroArch can be found in the [Libretro/RetroArch Documentation Center](https://docs.libretro.com/). diff --git a/audio/audio_driver.c b/audio/audio_driver.c index be714d9062..6acb0b2ca7 100644 --- a/audio/audio_driver.c +++ b/audio/audio_driver.c @@ -23,9 +23,9 @@ #include