Skip to content

Commit

Permalink
[Make.inc] Require C11 standard (#44556)
Browse files Browse the repository at this point in the history
* [Make.inc] Require C11 standard

Julia effectively requires C11 because of the use of `_Atomic`.  This is shown
when compiling with `-pedantic`.

* Add missing header file needed for `ssize_t`

* Change C standard also in `contrib/julia-config.jl`
  • Loading branch information
giordano committed Mar 12, 2022
1 parent 6be86a3 commit d291c8b
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
4 changes: 2 additions & 2 deletions Make.inc
Original file line number Diff line number Diff line change
Expand Up @@ -485,7 +485,7 @@ endif
ifeq ($(USEGCC),1)
CC := $(CROSS_COMPILE)gcc
CXX := $(CROSS_COMPILE)g++
JCFLAGS := -std=gnu99 -pipe $(fPIC) -fno-strict-aliasing -D_FILE_OFFSET_BITS=64
JCFLAGS := -std=gnu11 -pipe $(fPIC) -fno-strict-aliasing -D_FILE_OFFSET_BITS=64
# AArch64 needs this flag to generate the .eh_frame used by libunwind
JCPPFLAGS := -fasynchronous-unwind-tables
JCXXFLAGS := -pipe $(fPIC) -fno-rtti -std=c++14
Expand All @@ -500,7 +500,7 @@ endif
ifeq ($(USECLANG),1)
CC := $(CROSS_COMPILE)clang
CXX := $(CROSS_COMPILE)clang++
JCFLAGS := -std=gnu99 -pipe $(fPIC) -fno-strict-aliasing -D_FILE_OFFSET_BITS=64
JCFLAGS := -std=gnu11 -pipe $(fPIC) -fno-strict-aliasing -D_FILE_OFFSET_BITS=64
# AArch64 needs this flag to generate the .eh_frame used by libunwind
JCPPFLAGS := -fasynchronous-unwind-tables
JCXXFLAGS := -pipe $(fPIC) -fno-rtti -pedantic -std=c++14
Expand Down
2 changes: 1 addition & 1 deletion contrib/julia-config.jl
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ end

function cflags(doframework)
flags = IOBuffer()
print(flags, "-std=gnu99")
print(flags, "-std=gnu11")
if doframework
include = shell_escape(frameworkDir())
print(flags, " -F", include)
Expand Down
1 change: 1 addition & 0 deletions src/support/ios.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
#define JL_IOS_H

#include <stdarg.h>
#include <sys/types.h>
#include "analyzer_annotations.h"

#ifdef __cplusplus
Expand Down

2 comments on commit d291c8b

@nanosoldier
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Executing the daily package evaluation, I will reply here when finished:

@nanosoldier runtests(ALL, isdaily = true)

@nanosoldier
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Your package evaluation job has completed - possible new issues were detected. A full report can be found here.

Please sign in to comment.