2022-08-18 22:58:41 +02:00
|
|
|
MAKEFLAGS="-j $(grep -c ^processor /proc/cpuinfo)"
|
|
|
|
|
|
|
|
CXXFLAGS:=$(CXXFLAGS) -std=c++20 -Wall -Wextra -Werror=switch -Werror=return-type -Werror=unused-result -Wno-maybe-uninitialized
|
2022-10-08 12:48:42 +02:00
|
|
|
CPPFLAGS:=$(CPPFLAGS) -Ilib/expected/ -I. -Ilib/bestline/ -Ilib/rtmidi/
|
2022-10-08 20:32:41 +02:00
|
|
|
LDFLAGS=-flto
|
|
|
|
LDLIBS= -lpthread -static-libgcc -static-libstdc++
|
2022-08-18 22:58:41 +02:00
|
|
|
|
2022-09-25 12:01:19 +02:00
|
|
|
RELEASE_FLAGS=-O2
|
2022-08-18 22:58:41 +02:00
|
|
|
DEBUG_FLAGS=-O0 -ggdb -fsanitize=undefined -DDebug
|
|
|
|
|
2022-10-08 20:32:41 +02:00
|
|
|
ifeq ($(os),windows)
|
2022-10-08 17:18:55 +02:00
|
|
|
CC=i686-w64-mingw32-gcc
|
|
|
|
CXX=i686-w64-mingw32-g++
|
2022-10-08 20:32:41 +02:00
|
|
|
CPPFLAGS:=$(CPPFLAGS) -D__WINDOWS_MM__
|
|
|
|
LDLIBS:=-lwinmm $(LDLIBS)
|
|
|
|
else
|
|
|
|
CC=gcc
|
|
|
|
CXX=g++
|
|
|
|
CPPFLAGS:=$(CPPFLAGS) -D __LINUX_ALSA__
|
|
|
|
LDLIBS:=-lasound $(LDLIBS)
|
|
|
|
endif
|
2022-08-18 22:58:41 +02:00
|
|
|
|