mirror of
https://github.com/libretro/RetroArch
synced 2025-02-20 15:40:44 +00:00
C89_BUILD fixes
This commit is contained in:
parent
493d442f8c
commit
00d57af005
@ -2409,7 +2409,7 @@ void video_driver_frame(const void *data, unsigned width,
|
||||
|
||||
video_driver_frame_count++;
|
||||
|
||||
// Display the FPS, with a higher priority.
|
||||
/* Display the FPS, with a higher priority. */
|
||||
if (video_info.fps_show)
|
||||
runloop_msg_queue_push(video_info.fps_text, 2, 1, true);
|
||||
}
|
||||
|
@ -2662,7 +2662,7 @@ void input_config_get_bind_string(char *buf, const struct retro_keybind *bind,
|
||||
{
|
||||
if (delim)
|
||||
strlcat(buf, ", ", size);
|
||||
strlcat(buf, msg_hash_to_str((msg_hash_enums)tag), size );
|
||||
strlcat(buf, msg_hash_to_str((enum msg_hash_enums)tag), size );
|
||||
delim = 1;
|
||||
}
|
||||
}
|
||||
|
@ -20,6 +20,8 @@
|
||||
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
*/
|
||||
|
||||
#include <file/nbio.h>
|
||||
|
||||
#if defined(__linux__)
|
||||
|
||||
#define _GNU_SOURCE
|
||||
@ -28,7 +30,6 @@
|
||||
#include <stdint.h>
|
||||
#include <string.h>
|
||||
|
||||
#include <file/nbio.h>
|
||||
|
||||
#include <unistd.h>
|
||||
#include <fcntl.h>
|
||||
@ -226,5 +227,17 @@ nbio_intf_t nbio_linux = {
|
||||
nbio_linux_free,
|
||||
"nbio_linux",
|
||||
};
|
||||
#else
|
||||
nbio_intf_t nbio_linux = {
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
"nbio_linux",
|
||||
};
|
||||
|
||||
#endif
|
||||
|
@ -20,13 +20,13 @@
|
||||
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
*/
|
||||
|
||||
#include <file/nbio.h>
|
||||
|
||||
#if defined(HAVE_MMAP) && defined(BSD)
|
||||
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
|
||||
#include <file/nbio.h>
|
||||
|
||||
#ifdef _WIN32
|
||||
#include <direct.h>
|
||||
#else
|
||||
@ -157,5 +157,17 @@ nbio_intf_t nbio_mmap_unix = {
|
||||
nbio_mmap_unix_free,
|
||||
"nbio_mmap_unix",
|
||||
};
|
||||
#else
|
||||
nbio_intf_t nbio_mmap_unix = {
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
"nbio_mmap_unix",
|
||||
};
|
||||
|
||||
#endif
|
||||
|
@ -20,12 +20,13 @@
|
||||
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
*/
|
||||
|
||||
#include <file/nbio.h>
|
||||
|
||||
#if defined(_WIN32) && !defined(_XBOX)
|
||||
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
|
||||
#include <file/nbio.h>
|
||||
#include <encodings/utf.h>
|
||||
|
||||
#include <windows.h>
|
||||
@ -79,7 +80,7 @@ static void *nbio_mmap_win32_open(const char * filename, unsigned mode)
|
||||
ptr = MapViewOfFile(mem, is_write ? (FILE_MAP_READ|FILE_MAP_WRITE) : FILE_MAP_READ, 0, 0, len.QuadPart);
|
||||
CloseHandle(mem);
|
||||
|
||||
handle = (nbio_mmap_win32_t*)malloc(sizeof(struct nbio_mmap_win32_t));
|
||||
handle = (struct nbio_mmap_win32_t*)malloc(sizeof(struct nbio_mmap_win32_t));
|
||||
|
||||
handle->file = file;
|
||||
handle->is_write = is_write;
|
||||
@ -182,5 +183,17 @@ nbio_intf_t nbio_mmap_win32 = {
|
||||
nbio_mmap_win32_free,
|
||||
"nbio_mmap_win32",
|
||||
};
|
||||
#else
|
||||
nbio_intf_t nbio_mmap_win32 = {
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
"nbio_mmap_win32",
|
||||
};
|
||||
|
||||
#endif
|
||||
|
@ -2799,11 +2799,10 @@ static enum runloop_state runloop_check_state(
|
||||
driver_set_nonblock_state();
|
||||
}
|
||||
|
||||
// Display the fast forward state to the user, if needed.
|
||||
if (runloop_fastmotion) {
|
||||
/* Display the fast forward state to the user, if needed. */
|
||||
if (runloop_fastmotion)
|
||||
runloop_msg_queue_push(
|
||||
msg_hash_to_str(MSG_FAST_FORWARD), 1, 1, false);
|
||||
}
|
||||
|
||||
old_button_state = new_button_state;
|
||||
old_hold_button_state = new_hold_button_state;
|
||||
|
Loading…
x
Reference in New Issue
Block a user