Alien-cares

 view release on metacpan or  search on metacpan

libcares/Makefile.msvc  view on Meta::CPAN


# Copyright (C) 2009-2013 by Daniel Stenberg
#
# Permission to use, copy, modify, and distribute this
# software and its documentation for any purpose and without
# fee is hereby granted, provided that the above copyright
# notice appear in all copies and that both that copyright
# notice and this permission notice appear in supporting
# documentation, and that the name of M.I.T. not be used in
# advertising or publicity pertaining to distribution of the
# software without specific, written prior permission.
# M.I.T. makes no representations about the suitability of
# this software for any purpose.  It is provided "as is"
# without express or implied warranty.

# ------------------------------------------------------------------------------
#
# Makefile for building c-ares libraries and sample programs with MSVC.
#
# Usage: nmake /f makefile.msvc CFG=<config> <target>
#
# <config> must be one of: [ lib-release | lib-debug | dll-release | dll-debug }
# <target> must be one of: [ ALL | c-ares | acountry | adig | ahost | clean }
#
# If a <target> other than ALL or clean is given, <config> becomes mandatory.
#
# If neither <config> nor <target> are specified this results in
# all targets being built for all <config> c-ares library types.
#
# This makefile must be processed from the subdir where it is located.
#
# All results are generated below a subdirectory named msvcXXX.
#
# ------------------------------------------------------------------------------

NAME = cares

# ------------------------------------------------
# c-ares static and dynamic libraries common base
# file names for release and debug configurations
# ------------------------------------------------

STA_LIB_REL = lib$(NAME)
DYN_LIB_REL = $(NAME)
STA_LIB_DBG = $(STA_LIB_REL)d
DYN_LIB_DBG = $(DYN_LIB_REL)d

# -------------------------------------------
# Base names for c-ares DLL import libraries
# -------------------------------------------

IMP_LIB_REL = $(DYN_LIB_REL)
IMP_LIB_DBG = $(DYN_LIB_DBG)

# --------------------------
# Runtime library selection
# --------------------------

RTLIB  = /MD
RTLIBD = /MDd

!IF "$(RTLIBCFG)" == "static"
RTLIB  = /MT
RTLIBD = /MTd
!ENDIF

# --------------------------------------------------------
# Define USE_WATT32 to 1 to use the Watt-32 tcp/ip stack,
# otherwise Winsock tcp/ip stack will be used as default.
# --------------------------------------------------------

USE_WATT32 = 0

# --------------------------------------------------------
# Detect compiler version.
# --------------------------------------------------------
!INCLUDE .\msvc_ver.inc

# ----------------------------------------------------
# Verify that current subdir is the c-ares source one
# ----------------------------------------------------

!IF ! EXIST(.\ares_init.c)
!  MESSAGE Can not process Makefile.msvc from outside of c-ares source subdirectory.
!  MESSAGE Change to the subdirectory where Makefile.msvc is found, and try again.
!  ERROR   See previous message.
!ENDIF

# ------------------------------------------------------------------
# Base subdir is the common root from which other subdirs will hang.
# ------------------------------------------------------------------

BASE_DIR = .\msvc

# ----------------------------------------
# Subdir holding sources for all projects
# ----------------------------------------

SRCDIR = .

# -----------------------------
# Default installation subdirs
# -----------------------------

!IFNDEF INSTALL_DIR
INSTALL_DIR = .
!ENDIF

!IFNDEF INSTALL_DIR_LIB
INSTALL_DIR_LIB = $(INSTALL_DIR)\lib
!ENDIF

!IFNDEF INSTALL_DIR_INC
INSTALL_DIR_INC = $(INSTALL_DIR)\include
!ENDIF



( run in 0.558 second using v1.01-cache-2.11-cpan-3d66aa2751a )