NMake build: added support for WinCNG build.
This commit is contained in:
parent
e4ba5fabec
commit
6a3b5487cb
@ -1,7 +1,10 @@
|
||||
!include "win32/config.mk"
|
||||
|
||||
# only OpenSSL is supported with this build system
|
||||
!if "$(WITH_WINCNG)" == "1"
|
||||
!include "Makefile.WinCNG.inc"
|
||||
!else
|
||||
!include "Makefile.OpenSSL.inc"
|
||||
!endif
|
||||
!include "Makefile.inc"
|
||||
|
||||
OBJECTS=$(CSOURCES:.c=.obj)
|
||||
@ -14,6 +17,7 @@ all-sub: win32\objects.mk
|
||||
|
||||
clean:
|
||||
-rmdir 2>NUL /s/q $(TARGET)
|
||||
-del 2>NUL win32\objects.mk
|
||||
|
||||
real-clean vclean: clean
|
||||
-del 2>NUL libssh2.dll
|
||||
@ -21,7 +25,6 @@ real-clean vclean: clean
|
||||
-del 2>NUL libssh2.ilk
|
||||
-del 2>NUL libssh2.lib
|
||||
-del 2>NUL *.pdb
|
||||
-del 2>NUL win32\objects.mk
|
||||
|
||||
win32\objects.mk: Makefile.inc
|
||||
@echo OBJECTS = \>$@
|
||||
|
@ -1,19 +1,19 @@
|
||||
|
||||
# Tweak these for your system
|
||||
!if "$(OPENSSLINC)" == ""
|
||||
OPENSSLINC=..\openssl-0.9.8x\inc32
|
||||
OPENSSLINC=..\openssl-0.9.8zc\inc32
|
||||
!endif
|
||||
|
||||
!if "$(OPENSSLLIB)" == ""
|
||||
OPENSSLLIB=..\openssl-0.9.8x\out32dll
|
||||
OPENSSLLIB=..\openssl-0.9.8zc\out32dll
|
||||
!endif
|
||||
|
||||
!if "$(ZLIBINC)" == ""
|
||||
ZLIBINC=-DLIBSSH2_HAVE_ZLIB=1 /I..\zlib-1.2.7
|
||||
ZLIBINC=..\zlib-1.2.8
|
||||
!endif
|
||||
|
||||
!if "$(ZLIBLIB)" == ""
|
||||
ZLIBLIB=..\zlib-1.2.7
|
||||
ZLIBLIB=..\zlib-1.2.8
|
||||
!endif
|
||||
|
||||
!if "$(TARGET)" == ""
|
||||
@ -29,11 +29,25 @@ CPPFLAGS=/Oi /O2 /Oy /GF /Y- /MD /DNDEBUG
|
||||
DLLFLAGS=/DEBUG /LD
|
||||
!endif
|
||||
|
||||
CPPFLAGS=/nologo /GL /Zi /EHsc $(CPPFLAGS) /Iwin32 /Iinclude /DLIBSSH2_OPENSSL /I$(OPENSSLINC) $(ZLIBINC)
|
||||
CPPFLAGS=/nologo /GL /Zi /EHsc $(CPPFLAGS) /Iwin32 /Iinclude
|
||||
|
||||
!if "$(WITH_WINCNG)" == "1"
|
||||
CPPFLAGS=$(CPPFLAGS) /DLIBSSH2_WINCNG
|
||||
# LIBS=bcrypt.lib crypt32.lib
|
||||
!else
|
||||
CPPFLAGS=$(CPPFLAGS) /DLIBSSH2_OPENSSL /I$(OPENSSLINC)
|
||||
LIBS=$(OPENSSLLIB)\libeay32.lib $(OPENSSLLIB)\ssleay32.lib
|
||||
!endif
|
||||
|
||||
!if "$(WITH_ZLIB)" == "1"
|
||||
CPPFLAGS=$(CPPFLAGS) /DLIBSSH2_HAVE_ZLIB /I$(ZLIBINC)
|
||||
LIBS=$(ZLIBLIB)\zlib.lib
|
||||
!endif
|
||||
|
||||
CFLAGS=$(CPPFLAGS)
|
||||
RCFLAGS=/Iinclude
|
||||
DLLFLAGS=$(CFLAGS) $(DLLFLAGS)
|
||||
LIBS=$(OPENSSLLIB)\libeay32.lib $(OPENSSLLIB)\ssleay32.lib $(ZLIBLIB)\zlib.lib ws2_32.lib user32.lib advapi32.lib gdi32.lib
|
||||
LIBS=$(LIBS) ws2_32.lib user32.lib advapi32.lib gdi32.lib
|
||||
|
||||
INTDIR=$(TARGET)\$(SUBDIR)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user