]> granicus.if.org Git - curl/commitdiff
build: in Makefile.m32 moved target autodetection.
authorGuenter Knauf <lists@gknw.net>
Wed, 19 Nov 2014 11:39:20 +0000 (12:39 +0100)
committerGuenter Knauf <lists@gknw.net>
Wed, 19 Nov 2014 11:39:20 +0000 (12:39 +0100)
Moved target autodetection block after defining CC macro.

lib/Makefile.m32
src/Makefile.m32

index 2ce597320720933030954ffb57726e7a19bb0c9a..de44c66ea1a42a08c4bc2d6c3e32fff1e4966b4b 100644 (file)
@@ -54,16 +54,6 @@ ifndef LIBCARES_PATH
 LIBCARES_PATH = $(PROOT)/ares
 endif
 
-# Set environment var ARCH to your architecture to override autodetection.
-ifndef ARCH
-TARGET := $(shell $(CC) -dumpmachine)
-ifeq ($(findstring x86_64,$(TARGET)),x86_64)
-ARCH   = w64
-else
-ARCH   = w32
-endif
-endif
-
 CC     = $(CROSSPREFIX)gcc
 CFLAGS = -g -O2 -Wall
 CFLAGS += -fno-strict-aliasing
@@ -75,6 +65,16 @@ RC   = $(CROSSPREFIX)windres
 RCFLAGS        = --include-dir=$(PROOT)/include -DDEBUGBUILD=0 -O COFF
 STRIP  = $(CROSSPREFIX)strip -g
 
+# Set environment var ARCH to your architecture to override autodetection.
+ifndef ARCH
+TARGET := $(shell $(CC) -dumpmachine)
+ifeq ($(findstring x86_64,$(TARGET)),x86_64)
+ARCH   = w64
+else
+ARCH   = w32
+endif
+endif
+
 ifeq ($(ARCH),w64)
 CFLAGS  += -D_AMD64_
 RCFLAGS += -F pe-x86-64
index 707b5bc2adf05aa6c2fb6dfc746b65996b36da6b..4f1c99bdd04209f9e2f14cdbaa39a5c922dc3a31 100644 (file)
@@ -66,16 +66,6 @@ ifndef LIBCARES_PATH
 LIBCARES_PATH = $(PROOT)/ares
 endif
 
-# Set environment var ARCH to your architecture to override autodetection.
-ifndef ARCH
-TARGET  := $(shell $(CC) -dumpmachine)
-ifeq ($(findstring x86_64,$(TARGET)),x86_64)
-ARCH    = w64
-else
-ARCH    = w32
-endif
-endif
-
 CC     = $(CROSSPREFIX)gcc
 CFLAGS = -g -O2 -Wall
 CFLAGS += -fno-strict-aliasing
@@ -90,6 +80,16 @@ STRIP   = $(CROSSPREFIX)strip -g
 # PERL = perl
 # NROFF = nroff
 
+# Set environment var ARCH to your architecture to override autodetection.
+ifndef ARCH
+TARGET  := $(shell $(CC) -dumpmachine)
+ifeq ($(findstring x86_64,$(TARGET)),x86_64)
+ARCH    = w64
+else
+ARCH    = w32
+endif
+endif
+
 ifeq ($(ARCH),w64)
 CFLAGS += -D_AMD64_
 RCFLAGS += -F pe-x86-64