From 3476bdd3547170e54a63632526d586a673ae5f7c Mon Sep 17 00:00:00 2001 From: stansmith Date: Tue, 1 Apr 2008 23:45:43 +0000 Subject: [PATCH] [Core,DAPL] make user mode .dll libraries build cleanup DAPL and getpid() missing from documented MS libs. git-svn-id: svn://openib.tc.cornell.edu/gen1@1028 ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86 --- branches/ConnectX/core/al/user/SOURCES | 10 +++++++--- branches/ConnectX/core/complib/user/SOURCES | 8 ++++++++ branches/ConnectX/ulp/dapl/dapl/udapl/SOURCES | 8 +++++++- branches/ConnectX/ulp/dapl/dat/udat/SOURCES | 8 +++++++- branches/ConnectX/ulp/dapl2/dapl/udapl/SOURCES | 9 +++++++-- branches/ConnectX/ulp/dapl2/dapl/udapl_scm/SOURCES | 6 +++++- branches/ConnectX/ulp/dapl2/dat/udat/SOURCES | 6 +++++- branches/ConnectX/ulp/dapl2/test/dapltest/SOURCES | 2 +- branches/ConnectX/ulp/dapl2/test/dtest/SOURCES | 6 ++---- branches/ConnectX/ulp/dapl2/test/dtestx/SOURCES | 6 +++--- branches/ConnectX/ulp/dapl2/test/dtestx/dtestx.c | 3 ++- 11 files changed, 54 insertions(+), 18 deletions(-) diff --git a/branches/ConnectX/core/al/user/SOURCES b/branches/ConnectX/core/al/user/SOURCES index bd1cfbf8..85774fa6 100644 --- a/branches/ConnectX/core/al/user/SOURCES +++ b/branches/ConnectX/core/al/user/SOURCES @@ -9,16 +9,20 @@ TARGETTYPE=DYNLINK DLLENTRY=DllMain - !if $(FREEBUILD) ENABLE_EVENT_TRACING=1 #!else #ENABLE_EVENT_TRACING=1 !endif - - +!if $(_NT_TOOLS_VERSION) == 0x700 +# DDK DLLDEF=$O\al_exports.def +!else +# WDK +DLLDEF=$(OBJ_PATH)\$O\al_exports.def +!endif + USE_NTDLL=1 SOURCES=\ diff --git a/branches/ConnectX/core/complib/user/SOURCES b/branches/ConnectX/core/complib/user/SOURCES index 64725a8d..1a636edc 100644 --- a/branches/ConnectX/core/complib/user/SOURCES +++ b/branches/ConnectX/core/complib/user/SOURCES @@ -6,7 +6,15 @@ TARGETNAME=complibd TARGETPATH=..\..\..\bin\user\obj$(BUILD_ALT_DIR) TARGETTYPE=DYNLINK DLLENTRY=DllMain + +!if $(_NT_TOOLS_VERSION) == 0x700 +# DDK DLLDEF=$O\complib.def +!else +# WDK +DLLDEF=$(OBJ_PATH)\$O\complib.def +!endif + USE_NTDLL=1 SOURCES=\ diff --git a/branches/ConnectX/ulp/dapl/dapl/udapl/SOURCES b/branches/ConnectX/ulp/dapl/dapl/udapl/SOURCES index f7aa65c9..712ba5b4 100644 --- a/branches/ConnectX/ulp/dapl/dapl/udapl/SOURCES +++ b/branches/ConnectX/ulp/dapl/dapl/udapl/SOURCES @@ -6,8 +6,14 @@ TARGETNAME=dapld TARGETPATH=..\..\..\..\bin\user\obj$(BUILD_ALT_DIR) TARGETTYPE=DYNLINK DLLENTRY=_DllMainCRTStartup +!if $(_NT_TOOLS_VERSION) == 0x700 +# DDK DLLDEF=$O\udapl_exports.def -USE_MSVCRT=1 +!else +# WDK +DLLDEF=$(OBJ_PATH)\$O\udapl_exports.def +!endif +USE_LIBCMT=1 SOURCES=udapl.rc \ dapl_init.c \ diff --git a/branches/ConnectX/ulp/dapl/dat/udat/SOURCES b/branches/ConnectX/ulp/dapl/dat/udat/SOURCES index 425cbbeb..e2368537 100644 --- a/branches/ConnectX/ulp/dapl/dat/udat/SOURCES +++ b/branches/ConnectX/ulp/dapl/dat/udat/SOURCES @@ -6,8 +6,14 @@ TARGETNAME=datd TARGETPATH=..\..\..\..\bin\user\obj$(BUILD_ALT_DIR) TARGETTYPE=DYNLINK DLLENTRY=_DllMainCRTStartup +!if $(_NT_TOOLS_VERSION) == 0x700 +# DDK DLLDEF=$O\udat_exports.def -USE_MSVCRT=1 +!else +# WDK +DLLDEF=$(OBJ_PATH)\$O\udat_exports.def +!endif +USE_LIBCMT=1 SOURCES=udat.rc \ udat.c \ diff --git a/branches/ConnectX/ulp/dapl2/dapl/udapl/SOURCES b/branches/ConnectX/ulp/dapl2/dapl/udapl/SOURCES index fd7aa647..c004a600 100644 --- a/branches/ConnectX/ulp/dapl2/dapl/udapl/SOURCES +++ b/branches/ConnectX/ulp/dapl2/dapl/udapl/SOURCES @@ -3,11 +3,16 @@ TARGETNAME=dapl2 !else TARGETNAME=dapl2d !endif + TARGETPATH=..\..\..\..\bin\user\obj$(BUILD_ALT_DIR) TARGETTYPE=DYNLINK DLLENTRY=_DllMainCRTStartup +!if $(_NT_TOOLS_VERSION) == 0x700 DLLDEF=$O\udapl_exports.def -USE_MSVCRT=1 +!else +DLLDEF=$(OBJ_PATH)\$O\udapl_exports.def +!endif +USE_LIBCMT=1 # pickup local files, then via udapl_sources.c get common files @@ -29,7 +34,7 @@ SOURCES=udapl.rc \ dapl_lmr_create.c \ udapl_sources.c -INCLUDES=..\include;..\common;windows;..\ibal;..\..\dat\include;\ +INCLUDES=$(INCLUDES);..\include;..\common;windows;..\ibal;..\..\dat\include;\ ..\..\..\..\inc;..\..\..\..\inc\user; DAPL_OPTS= -DEXPORT_DAPL_SYMBOLS -D_VENDOR_IBAL_ -DDAPL_MERGE_CM_DTO diff --git a/branches/ConnectX/ulp/dapl2/dapl/udapl_scm/SOURCES b/branches/ConnectX/ulp/dapl2/dapl/udapl_scm/SOURCES index 25675d6b..f25a1d6a 100644 --- a/branches/ConnectX/ulp/dapl2/dapl/udapl_scm/SOURCES +++ b/branches/ConnectX/ulp/dapl2/dapl/udapl_scm/SOURCES @@ -6,8 +6,12 @@ TARGETNAME=dapl2-scmd TARGETPATH=..\..\..\..\bin\user\obj$(BUILD_ALT_DIR) TARGETTYPE=DYNLINK DLLENTRY=_DllMainCRTStartup +!if $(_NT_TOOLS_VERSION) == 0x700 DLLDEF=$O\udapl_scm_exports.def -USE_MSVCRT=1 +!else +DLLDEF=$(OBJ_PATH)\$O\udapl_scm_exports.def +!endif +USE_LIBCMT=1 # pickup local files, then via udapl_sources.c get common files diff --git a/branches/ConnectX/ulp/dapl2/dat/udat/SOURCES b/branches/ConnectX/ulp/dapl2/dat/udat/SOURCES index a55d841c..3e5be991 100644 --- a/branches/ConnectX/ulp/dapl2/dat/udat/SOURCES +++ b/branches/ConnectX/ulp/dapl2/dat/udat/SOURCES @@ -6,8 +6,12 @@ TARGETNAME=dat2d TARGETPATH=..\..\..\..\bin\user\obj$(BUILD_ALT_DIR) TARGETTYPE=DYNLINK DLLENTRY=_DllMainCRTStartup +!if $(_NT_TOOLS_VERSION) == 0x700 DLLDEF=$O\udat_exports.def -USE_MSVCRT=1 +!else +DLLDEF=$(OBJ_PATH)\$O\udat_exports.def +!endif +USE_LIBCMT=1 SOURCES=udat.rc \ udat.c \ diff --git a/branches/ConnectX/ulp/dapl2/test/dapltest/SOURCES b/branches/ConnectX/ulp/dapl2/test/dapltest/SOURCES index 6f74cff2..dce1d3bd 100644 --- a/branches/ConnectX/ulp/dapl2/test/dapltest/SOURCES +++ b/branches/ConnectX/ulp/dapl2/test/dapltest/SOURCES @@ -6,7 +6,7 @@ TARGETNAME=dapl2testd TARGETPATH=..\..\..\..\bin\user\obj$(BUILD_ALT_DIR) TARGETTYPE=PROGRAM UMTYPE=console -USE_MSVCRT=1 +USE_LIBCMT=1 SOURCES=dapltest.rc \ dt_cmd.c \ diff --git a/branches/ConnectX/ulp/dapl2/test/dtest/SOURCES b/branches/ConnectX/ulp/dapl2/test/dtest/SOURCES index f6a53309..b8ac5305 100644 --- a/branches/ConnectX/ulp/dapl2/test/dtest/SOURCES +++ b/branches/ConnectX/ulp/dapl2/test/dtest/SOURCES @@ -6,15 +6,13 @@ TARGETNAME=dtest2d TARGETPATH=..\..\..\..\bin\user\obj$(BUILD_ALT_DIR) TARGETTYPE=PROGRAM UMTYPE=console -USE_MSVCRT=1 +USE_LIBCMT=1 SOURCES=dtest.rc \ dtest.c \ getopt.c -INCLUDES=.;..\..\dat\include;\ - ../../../../inc;..\..\..\..\inc\user;\ - $(SDK_INC_PATH); +INCLUDES=.;..\..\dat\include;../../../../inc;..\..\..\..\inc\user; RCOPTIONS=/I..\..\..\..\inc; diff --git a/branches/ConnectX/ulp/dapl2/test/dtestx/SOURCES b/branches/ConnectX/ulp/dapl2/test/dtestx/SOURCES index 492f3a8f..b7fe0a40 100644 --- a/branches/ConnectX/ulp/dapl2/test/dtestx/SOURCES +++ b/branches/ConnectX/ulp/dapl2/test/dtestx/SOURCES @@ -6,14 +6,13 @@ TARGETNAME=dtestxd TARGETPATH=..\..\..\..\bin\user\obj$(BUILD_ALT_DIR) TARGETTYPE=PROGRAM UMTYPE=console -USE_MSVCRT=1 +USE_LIBCMT=1 SOURCES=dtestx.rc \ dtestx.c INCLUDES=.;..\..\dat\include;\ - ../../../../inc;..\..\..\..\inc\user;\ - $(SDK_INC_PATH); + ../../../../inc;..\..\..\..\inc\user; RCOPTIONS=/I..\..\..\..\inc; @@ -29,6 +28,7 @@ DATLIB=dat2d.lib TARGETLIBS=$(TARGETPATH)\*\$(DATLIB) $(SDK_LIB_PATH)\ws2_32.lib + # XXX do this ASAP - MSC_WARNING_LEVEL= /W3 MSC_WARNING_LEVEL= /W1 diff --git a/branches/ConnectX/ulp/dapl2/test/dtestx/dtestx.c b/branches/ConnectX/ulp/dapl2/test/dtestx/dtestx.c index 94fe53a6..2cfc390a 100644 --- a/branches/ConnectX/ulp/dapl2/test/dtestx/dtestx.c +++ b/branches/ConnectX/ulp/dapl2/test/dtestx/dtestx.c @@ -39,11 +39,12 @@ #include #include #include -#include #include #define __BYTE_ORDER __LITTLE_ENDIAN +#include #define getpid _getpid + #define F64x "%I64x" #define DAPL_PROVIDER "ibnic0v2" #else -- 2.41.0