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 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66
|
#------------------------------------------------------------- -*- makefile -*-
#
# Makefile for TclCurl
#
# Example build:
# nmake /f makefile.vc INSTALLDIR=d:\tcl\debug\x64 CURLDIR=D:\src\curl-7.74.0\builds\libcurl-vc15-x64-release-static-zlib-static-ipv6-sspi-schannel CURLDEPSDIR=D:\src\curl-7.74.0\deps\x64
# nmake /f makefile.vc INSTALLDIR=d:\tcl\debug\x64 CURLDIR=D:\src\curl-7.74.0\builds\libcurl-vc15-x64-release-static-zlib-static-ipv6-sspi-schannel CURLDEPSDIR=D:\src\curl-7.74.0\deps\x64 install
#
# For other build options (debug, static etc.),
# See TIP 477 (https://core.tcl.tk/tips/doc/trunk/tip/477.md) for
# detailed documentation.
#
#
# This makefile assumes static linking to the curl libraries
#------------------------------------------------------------------------------
PROJECT = TclCurl
!if "$(CURLDIR)" == ""
!error Please define CURLDIR on command line to point to CURL distribution containing lib and include dirs.
!endif
# Curl dependencies directory.
!if "$(CURLDEPSDIR)" == ""
!error Please define CURLDEPDIR on command line to point to CURL dependencies containing lib and include dirs.
!endif
# Make package version same as Curl version for now
!if [echo DOTVERSION = \> nmakehlp.out] \
|| [for /f "tokens=3" %i in ('findstr /C:"define LIBCURL_VERSION " $(CURLDIR)\include\curl\curlver.h') do @echo %i >> nmakehlp.out]
!error *** Could not retrieve PACKAGE_VERSION from Curl.
!endif
!include nmakehlp.out
# Some Curls (from vcpkg e.g.) have -DEV in the middle of the version
# string (eyeroll)). Remove it.
DOTVERSION=$(DOTVERSION:-DEV=)
# Remove the quotes from DOTVERSION
DOTVERSION=$(DOTVERSION:"=)
# " - Fix for Emacs highlighting to match quotes above
# Script files (LIBDIR) are in same location as C generic files
# NOTE: define this BEFORE including rules-ext.vc
LIBDIR = $(GENERICDIR)
!include "rules-ext.vc"
PRJ_OBJS = \
$(TMP_DIR)\tclcurl.obj \
$(TMP_DIR)\multi.obj
PRJ_DEFINES = -D _CRT_SECURE_NO_DEPRECATE -D _CRT_NONSTDC_NO_DEPRECATE
PRJ_INCLUDES = $(PRJ_INCLUDES) -I"$(CURLDIR)\include" -I"$(CURLDEPSDIR)\include"
PRJ_LIBS = $(PRJ_LIBS) "$(CURLDIR)\lib\libcurl.lib" "$(CURLDEPSDIR)\lib\zlib.lib" ws2_32.lib crypt32.lib wldap32.lib Normaliz.lib
!include "$(_RULESDIR)\targets.vc"
install: default-install-docs-html default-install-libraries
pkgindex:
@type << >"$(OUT_DIR)\pkgIndex.tcl"
package ifneeded $(PROJECT) $(DOTVERSION) "[list load [file join $$dir $(PRJLIBNAME)] TclCurl]; [list source [file join $$dir tclcurl.tcl]]"
<<
|