Skip to content
This repository has been archived by the owner on Aug 29, 2024. It is now read-only.

Commit

Permalink
Fix #346: GHA: CLANG started failing
Browse files Browse the repository at this point in the history
  • Loading branch information
xparq committed Dec 3, 2023
1 parent 386df0a commit f18246d
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,8 @@ TEST_OBJ := test/main
SMOKE_TEST_OBJ := test/smoke

CC := g++
CFLAGS := -I$(SFML_DIR)/include -I./include -std=c++20 -pedantic -Wall -Wextra -Wshadow -Wwrite-strings -O2
#!Note: not using := below, to give $(GHA_OLD_CLANG_WORKAROUND) a chance...:
CFLAGS = -I$(SFML_DIR)/include -I./include -std=c++20 $(GHA_OLD_CLANG_WORKAROUND) -pedantic -Wall -Wextra -Wshadow -Wwrite-strings -O2
LDFLAGS := $(LDFLAGS) -L$(SFML_DIR)/lib
#!! This may also be needed on Debian (not on Ubuntu) -- but just compiled it on my WSL Bullseye without it, so WTF?? --:
#!! LDFLAGS := -pthread $(LDFLAGS)
Expand Down Expand Up @@ -151,3 +152,13 @@ mrproper: clean
-@rm $(TEST_EXE)
@echo "$(TERM_YELLOW)Removing$(TERM_NO_COLOR) $(SMOKE_TEST_EXE)"
-@rm $(SMOKE_TEST_EXE)


#=============================================================================
# Misc. workarounds...
#

# https://github.com/xparq/sfw/issues/346
ifeq "$(CC)" "clang++"
GHA_OLD_CLANG_WORKAROUND = -stdlib=libc++
endif

0 comments on commit f18246d

Please sign in to comment.