summaryrefslogtreecommitdiff
path: root/games/openttd/patches/patch-Makefile.setting.in
blob: e63d3002e3a5126c12d8a122da4f69346fc24410 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
$NetBSD: patch-Makefile.setting.in,v 1.2 2013/08/05 19:24:35 adam Exp $

--- Makefile.setting.in.orig	2013-07-27 15:09:40.000000000 +0000
+++ Makefile.setting.in
@@ -9,14 +9,17 @@ SETTINGSGEN      = !!SETTINGSGEN!!
 ENDIAN_CHECK     = !!ENDIAN_CHECK!!
 SRC_DIR          = !!SRC_DIR!!
 CXX_BUILD        = !!CXX_BUILD!!
-CFLAGS_BUILD     = !!CFLAGS_BUILD!!
-CXXFLAGS_BUILD   = !!CXXFLAGS_BUILD!!
-LDFLAGS_BUILD    = !!LDFLAGS_BUILD!!
+CFLAGS_BUILD     = !!CFLAGS!! !!CFLAGS_BUILD!!
+CXXFLAGS_BUILD   = !!CXXFLAGS!! !!CXXFLAGS_BUILD!!
+LDFLAGS_BUILD    = !!LDFLAGS!! !!LDFLAGS_BUILD!! !!LIBS!!
 STAGE            = !!STAGE!!
 SETTING_OBJS_DIR = !!SETTING_OBJS_DIR!!
 
 ENDIAN_TARGETS := endian_host.h endian_target.h $(ENDIAN_CHECK)
 
+# Make sure endian_host.h is reachable as if it was in the src/ dir
+CFLAGS_BUILD += -I $(SETTING_OBJS_DIR)
+
 # Check if we want to show what we are doing
 ifdef VERBOSE
 	Q =