head	1.1;
access;
symbols
	pkgsrc-2026Q1:1.1.0.38
	pkgsrc-2026Q1-base:1.1
	pkgsrc-2025Q4:1.1.0.36
	pkgsrc-2025Q4-base:1.1
	pkgsrc-2025Q3:1.1.0.34
	pkgsrc-2025Q3-base:1.1
	pkgsrc-2025Q2:1.1.0.32
	pkgsrc-2025Q2-base:1.1
	pkgsrc-2025Q1:1.1.0.30
	pkgsrc-2025Q1-base:1.1
	pkgsrc-2024Q4:1.1.0.28
	pkgsrc-2024Q4-base:1.1
	pkgsrc-2024Q3:1.1.0.26
	pkgsrc-2024Q3-base:1.1
	pkgsrc-2024Q2:1.1.0.24
	pkgsrc-2024Q2-base:1.1
	pkgsrc-2024Q1:1.1.0.22
	pkgsrc-2024Q1-base:1.1
	pkgsrc-2023Q4:1.1.0.20
	pkgsrc-2023Q4-base:1.1
	pkgsrc-2023Q3:1.1.0.18
	pkgsrc-2023Q3-base:1.1
	pkgsrc-2023Q2:1.1.0.16
	pkgsrc-2023Q2-base:1.1
	pkgsrc-2023Q1:1.1.0.14
	pkgsrc-2023Q1-base:1.1
	pkgsrc-2022Q4:1.1.0.12
	pkgsrc-2022Q4-base:1.1
	pkgsrc-2022Q3:1.1.0.10
	pkgsrc-2022Q3-base:1.1
	pkgsrc-2022Q2:1.1.0.8
	pkgsrc-2022Q2-base:1.1
	pkgsrc-2022Q1:1.1.0.6
	pkgsrc-2022Q1-base:1.1
	pkgsrc-2021Q4:1.1.0.4
	pkgsrc-2021Q4-base:1.1
	pkgsrc-2021Q3:1.1.0.2
	pkgsrc-2021Q3-base:1.1;
locks; strict;
comment	@# @;


1.1
date	2021.08.08.20.40.42;	author nia;	state Exp;
branches;
next	;
commitid	Zwoe7J2Whsfq3d4D;


desc
@@


1.1
log
@cataclysm-dda: add missing patch
@
text
@$NetBSD$

Just use optimization flags from pkgsrc.
Don't use -Werror.

--- Makefile.orig	2021-07-03 05:00:06.000000000 +0000
+++ Makefile
@@@@ -97,7 +97,7 @@@@
 # RELEASE_FLAGS is flags for release builds.
 RELEASE_FLAGS =
 WARNINGS = \
-  -Werror -Wall -Wextra \
+  -Wall -Wextra \
   -Wformat-signedness \
   -Wlogical-op \
   -Wmissing-declarations \
@@@@ -112,7 +112,7 @@@@ WARNINGS = \
   -Wno-unknown-warning-option
 # Uncomment below to disable warnings
 #WARNINGS = -w
-DEBUGSYMS = -g
+DEBUGSYMS =
 #PROFILE = -pg
 #OTHERS = -O3
 #DEFINES = -DNDEBUG
@@@@ -337,85 +337,6 @@@@ ifneq ($(SANITIZE),)
   LDFLAGS += $(SANITIZE_FLAGS)
 endif
 
-# enable optimizations. slow to build
-ifeq ($(RELEASE), 1)
-  ifeq ($(NATIVE), osx)
-    ifeq ($(shell $(CXX) -E -Os - < /dev/null > /dev/null 2>&1 && echo fos),fos)
-      OPTLEVEL = -Os
-    else
-      OPTLEVEL = -O3
-    endif
-  else
-    # MXE ICE Workaround
-    # known bad on 4.9.3 and 4.9.4, if it gets fixed this could include a version test too
-    ifeq ($(CXXMACHINE), x86_64-w64-mingw32.static)
-      OPTLEVEL = -O3
-    else
-      OPTLEVEL = -Os
-    endif
-  endif
-
-  ifeq ($(LTO), 1)
-    ifneq ($(CLANG), 0)
-      # LLVM's LTO will complain if the optimization level isn't between O0 and
-      # O3 (inclusive)
-      OPTLEVEL = -O3
-    endif
-  endif
-  CXXFLAGS += $(OPTLEVEL)
-
-  ifeq ($(LTO), 1)
-    ifeq ($(NATIVE), osx)
-      ifneq ($(CLANG), 0)
-        LTOFLAGS += -flto=full
-      endif
-    else
-      LDFLAGS += -fuse-ld=gold # This breaks in OS X because gold can only produce ELF binaries, not Mach
-    endif
-
-    ifneq ($(CLANG), 0)
-      LTOFLAGS += -flto
-    else
-      LTOFLAGS += -flto=jobserver -flto-odr-type-merging
-    endif
-  endif
-  LTOFLAGS += -Wodr
-  CXXFLAGS += $(LTOFLAGS)
-
-  # OTHERS += -mmmx -m3dnow -msse -msse2 -msse3 -mfpmath=sse -mtune=native
-  # OTHERS += -march=native # Uncomment this to build an optimized binary for your machine only
-
-  # Strip symbols, generates smaller executable.
-  OTHERS += $(RELEASE_FLAGS)
-  DEBUG =
-  ifndef DEBUG_SYMBOLS
-    DEBUGSYMS =
-  endif
-  DEFINES += -DRELEASE
-  # Check for astyle or JSON regressions on release builds.
-  ifeq ($(ASTYLE), 1)
-    CHECKS += astyle-check
-  endif
-  ifeq ($(LINTJSON), 1)
-    CHECKS += style-json
-  endif
-else
-  ifeq ($(NOOPT), 1)
-    # While gcc claims to include all information required for
-    # debugging at -Og, at least with gcc 8.3, control flow
-    # doesn't move line-by-line at -Og.  Provide a command-line
-    # way to turn off optimization (make NOOPT=1) entirely.
-    OPTLEVEL = -O0
-  else
-    ifeq ($(shell $(CXX) -E -Og - < /dev/null > /dev/null 2>&1 && echo fog),fog)
-      OPTLEVEL = -Og
-    else
-      OPTLEVEL = -O0
-    endif
-  endif
-  CXXFLAGS += $(OPTLEVEL)
-endif
-
 ifeq ($(shell sh -c 'uname -o 2>/dev/null || echo not'),Cygwin)
   OTHERS += -std=gnu++14
 else
@
