0N/A#
3909N/A# Copyright (c) 2005, 2011, Oracle and/or its affiliates. All rights reserved.
0N/A# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
0N/A#
0N/A# This code is free software; you can redistribute it and/or modify it
0N/A# under the terms of the GNU General Public License version 2 only, as
2362N/A# published by the Free Software Foundation. Oracle designates this
0N/A# particular file as subject to the "Classpath" exception as provided
2362N/A# by Oracle in the LICENSE file that accompanied this code.
0N/A#
0N/A# This code is distributed in the hope that it will be useful, but WITHOUT
0N/A# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
0N/A# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
0N/A# version 2 for more details (a copy is included in the LICENSE file that
0N/A# accompanied this code).
0N/A#
0N/A# You should have received a copy of the GNU General Public License version
0N/A# 2 along with this work; if not, write to the Free Software Foundation,
0N/A# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
0N/A#
2362N/A# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
2362N/A# or visit www.oracle.com if you need additional information or have any
2362N/A# questions.
0N/A#
0N/A
0N/A#
0N/A# MSVC Compiler settings
0N/A#
0N/A
0N/Aifeq ($(PLATFORM), windows)
0N/A CC = $(COMPILER_PATH)cl
0N/A CPP = $(COMPILER_PATH)cl
0N/A CXX = $(COMPILER_PATH)cl
0N/A CCC = $(COMPILER_PATH)cl
0N/A LIBEXE = $(COMPILER_PATH)lib
0N/A LINK = $(COMPILER_PATH)link
0N/A LINK32 = $(LINK)
3419N/A DUMPBIN = $(COMPILER_PATH)dumpbin.exe
0N/A
0N/A # Fill in unknown values
0N/A COMPILER_NAME=Unknown MSVC Compiler
0N/A COMPILER_VERSION=
0N/A
0N/A # unset any GNU Make settings of MFLAGS and MAKEFLAGS which may mess up nmake
0N/A NMAKE = MFLAGS= MAKEFLAGS= $(COMPILER_PATH)nmake -nologo
0N/A
168N/A # Compiler version and type (Always get word after "Version")
168N/A CC_VER := $(shell $(CC) 2>&1 | $(HEAD) -n 1 | $(SED) 's/.*\(Version.*\)/\1/' | $(NAWK) '{print $$2}')
3258N/A
3798N/A LINK_VER := $(shell $(LINK) | $(HEAD) -n 1 | $(NAWK) '{print $$6}')
3798N/A CC_MAJORVER :=$(call MajorVersion,$(CC_VER))
3258N/A
3258N/A # The VS2010 compiler is the same one used on both 32bit and 64bit
3258N/A ifeq ($(CC_MAJORVER), 16)
3258N/A COMPILER_NAME=Microsoft Visual Studio 10 (16.00.30319.01)
3258N/A COMPILER_VERSION=VS2010
3258N/A ifeq ($(WINDOWSSDKDIR),)
3258N/A WINDOWSSDKDIR := $(error WINDOWSSDKDIR cannot be empty here)
942N/A endif
3258N/A ifeq ($(ARCH_DATA_MODEL), 32)
3258N/A _OTHER_TOOLS_BIN = $(WINDOWSSDKDIR)/Bin
3258N/A else
3258N/A ifeq ($(ARCH), ia64)
3258N/A _OTHER_TOOLS_BIN = $(WINDOWSSDKDIR)/Bin/ia64
3258N/A else
3258N/A _OTHER_TOOLS_BIN = $(WINDOWSSDKDIR)/Bin/x64
3258N/A endif
0N/A endif
3419N/A RC = $(_OTHER_TOOLS_BIN)/RC.Exe
3419N/A REBASE = $(_OTHER_TOOLS_BIN)/ReBase.Exe
3258N/A MT = $(_OTHER_TOOLS_BIN)/mt.exe
3258N/A MTL = $(_OTHER_TOOLS_BIN)/midl.exe
3258N/A endif
3258N/A
3258N/A # These variables can never be empty
3258N/A ifndef COMPILER_PATH
3258N/A COMPILER_PATH := $(error COMPILER_PATH cannot be empty here)
0N/A endif
0N/A ifndef COMPILER_VERSION
0N/A COMPILER_VERSION := $(error COMPILER_VERSION cannot be empty here)
0N/A endif
3696N/A ifneq ($(COMPILER_VERSION),VS2010)
3696N/A COMPILER_VERSION := $(error COMPILER_VERSION must be VS2010)
3696N/A endif
3258N/A
0N/A # Shared library generation flag
0N/A SHARED_LIBRARY_FLAG = -LD
3258N/A # RSC is always same as RC (Not sure who uses this RSC variable)
3258N/A RSC = $(RC)
3258N/A
0N/Aendif
0N/A