Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 9d03b66

Browse files
committedJul 7, 2024·
Fix build for clang
Remove declaring POSIX_SOURCE manually. Let the compiler take care of this on its own. Additionally, include a missing header file for the definition of struct sockaddr_in, which we need before we can allocate the struct. With these fixes, we can build with Clang 18.1.5, although there are many warnings.
1 parent b55eb43 commit 9d03b66

File tree

2 files changed

+1
-2
lines changed

2 files changed

+1
-2
lines changed
 

‎src/debug/GdbStub.cpp

+1
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414

1515
#ifndef _WIN32
1616
#include <sys/socket.h>
17+
#include <netinet/in.h>
1718
#include <fcntl.h>
1819
#include <poll.h>
1920
#include <signal.h>

‎src/fatfs/ffsystem.c

-2
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,6 @@
33
/* (C)ChaN, 2018 */
44
/*------------------------------------------------------------------------*/
55

6-
#define _POSIX_SOURCE
7-
#define _POSIX_THREAD_SAFE_FUNCTIONS
86
#include <time.h>
97

108
#include "ff.h"

0 commit comments

Comments
 (0)
Please sign in to comment.