Added pre-compile defines to Win32 build using Visual C++ 6.0. Documented the defines in readme file.
This commit is contained in:
@@ -67,7 +67,7 @@ LINK32=link.exe
|
|||||||
# PROP Ignore_Export_Lib 0
|
# PROP Ignore_Export_Lib 0
|
||||||
# PROP Target_Dir ""
|
# PROP Target_Dir ""
|
||||||
# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c
|
# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c
|
||||||
# ADD CPP /nologo /W3 /Gm /GX /ZI /Od /I "..\..\.." /I ".." /I "..\..\..\demo\object\\" /I "..\..\..\demo\handler\\" /D "_DEBUG" /D "BACDL_BIP" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /D TSM_ENABLED=1 /D PRINT_ENABLED=1 /FR /FD /GZ /c
|
# ADD CPP /nologo /W3 /Gm /GX /ZI /Od /I "..\..\.." /I ".." /I "..\..\..\demo\object\\" /I "..\..\..\demo\handler\\" /D "_DEBUG" /D BACDL_BIP=1 /D "WIN32" /D "_CONSOLE" /D "_MBCS" /D TSM_ENABLED=1 /D PRINT_ENABLED=1 /D BIG_ENDIAN=0 /D USE_INADDR=0 /FR /FD /GZ /c
|
||||||
# SUBTRACT CPP /YX
|
# SUBTRACT CPP /YX
|
||||||
# ADD BASE RSC /l 0x409 /d "_DEBUG"
|
# ADD BASE RSC /l 0x409 /d "_DEBUG"
|
||||||
# ADD RSC /l 0x409 /d "_DEBUG"
|
# ADD RSC /l 0x409 /d "_DEBUG"
|
||||||
|
|||||||
Binary file not shown.
Binary file not shown.
@@ -6,9 +6,9 @@
|
|||||||
--------------------Configuration: bacnet - Win32 Debug--------------------
|
--------------------Configuration: bacnet - Win32 Debug--------------------
|
||||||
</h3>
|
</h3>
|
||||||
<h3>Command Lines</h3>
|
<h3>Command Lines</h3>
|
||||||
Creating temporary file "C:\DOCUME~1\stk01\LOCALS~1\Temp\RSP1254.tmp" with contents
|
Creating temporary file "C:\DOCUME~1\stk01\LOCALS~1\Temp\RSP133F.tmp" with contents
|
||||||
[
|
[
|
||||||
/nologo /MLd /W3 /Gm /GX /ZI /Od /I "..\..\.." /I ".." /I "..\..\..\demo\object\\" /I "..\..\..\demo\handler\\" /D "_DEBUG" /D "BACDL_BIP" /D "WIN32" /D "_CONSOLE" /D "_MBCS" /D TSM_ENABLED=1 /D PRINT_ENABLED=1 /FR"Debug/" /Fo"Debug/" /Fd"Debug/" /FD /GZ /c
|
/nologo /MLd /W3 /Gm /GX /ZI /Od /I "..\..\.." /I ".." /I "..\..\..\demo\object\\" /I "..\..\..\demo\handler\\" /D "_DEBUG" /D BACDL_BIP=1 /D "WIN32" /D "_CONSOLE" /D "_MBCS" /D TSM_ENABLED=1 /D PRINT_ENABLED=1 /D BIG_ENDIAN=0 /D USE_INADDR=0 /FR"Debug/" /Fo"Debug/" /Fd"Debug/" /FD /GZ /c
|
||||||
"C:\code\bacnet-stack\abort.c"
|
"C:\code\bacnet-stack\abort.c"
|
||||||
"C:\code\bacnet-stack\address.c"
|
"C:\code\bacnet-stack\address.c"
|
||||||
"C:\code\bacnet-stack\demo\object\ai.c"
|
"C:\code\bacnet-stack\demo\object\ai.c"
|
||||||
@@ -43,6 +43,7 @@ Creating temporary file "C:\DOCUME~1\stk01\LOCALS~1\Temp\RSP1254.tmp" with conte
|
|||||||
"C:\code\bacnet-stack\indtext.c"
|
"C:\code\bacnet-stack\indtext.c"
|
||||||
"C:\code\bacnet-stack\demo\object\lsp.c"
|
"C:\code\bacnet-stack\demo\object\lsp.c"
|
||||||
"C:\code\bacnet-stack\ports\win32\main.c"
|
"C:\code\bacnet-stack\ports\win32\main.c"
|
||||||
|
"C:\code\bacnet-stack\demo\object\mso.c"
|
||||||
"C:\code\bacnet-stack\demo\handler\noserv.c"
|
"C:\code\bacnet-stack\demo\handler\noserv.c"
|
||||||
"C:\code\bacnet-stack\npdu.c"
|
"C:\code\bacnet-stack\npdu.c"
|
||||||
"C:\code\bacnet-stack\reject.c"
|
"C:\code\bacnet-stack\reject.c"
|
||||||
@@ -55,10 +56,9 @@ Creating temporary file "C:\DOCUME~1\stk01\LOCALS~1\Temp\RSP1254.tmp" with conte
|
|||||||
"C:\code\bacnet-stack\demo\handler\txbuf.c"
|
"C:\code\bacnet-stack\demo\handler\txbuf.c"
|
||||||
"C:\code\bacnet-stack\whois.c"
|
"C:\code\bacnet-stack\whois.c"
|
||||||
"C:\code\bacnet-stack\wp.c"
|
"C:\code\bacnet-stack\wp.c"
|
||||||
"C:\code\bacnet-stack\demo\object\mso.c"
|
|
||||||
]
|
]
|
||||||
Creating command line "cl.exe @C:\DOCUME~1\stk01\LOCALS~1\Temp\RSP1254.tmp"
|
Creating command line "cl.exe @C:\DOCUME~1\stk01\LOCALS~1\Temp\RSP133F.tmp"
|
||||||
Creating temporary file "C:\DOCUME~1\stk01\LOCALS~1\Temp\RSP1255.tmp" with contents
|
Creating temporary file "C:\DOCUME~1\stk01\LOCALS~1\Temp\RSP1340.tmp" with contents
|
||||||
[
|
[
|
||||||
kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib wsock32.lib /nologo /subsystem:console /incremental:yes /pdb:"Debug/bacnet.pdb" /debug /machine:I386 /out:"Debug/bacnet.exe" /pdbtype:sept
|
kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib wsock32.lib /nologo /subsystem:console /incremental:yes /pdb:"Debug/bacnet.pdb" /debug /machine:I386 /out:"Debug/bacnet.exe" /pdbtype:sept
|
||||||
".\Debug\abort.obj"
|
".\Debug\abort.obj"
|
||||||
@@ -95,6 +95,7 @@ kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32
|
|||||||
".\Debug\indtext.obj"
|
".\Debug\indtext.obj"
|
||||||
".\Debug\lsp.obj"
|
".\Debug\lsp.obj"
|
||||||
".\Debug\main.obj"
|
".\Debug\main.obj"
|
||||||
|
".\Debug\mso.obj"
|
||||||
".\Debug\noserv.obj"
|
".\Debug\noserv.obj"
|
||||||
".\Debug\npdu.obj"
|
".\Debug\npdu.obj"
|
||||||
".\Debug\reject.obj"
|
".\Debug\reject.obj"
|
||||||
@@ -107,22 +108,17 @@ kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32
|
|||||||
".\Debug\txbuf.obj"
|
".\Debug\txbuf.obj"
|
||||||
".\Debug\whois.obj"
|
".\Debug\whois.obj"
|
||||||
".\Debug\wp.obj"
|
".\Debug\wp.obj"
|
||||||
".\Debug\mso.obj"
|
|
||||||
]
|
]
|
||||||
Creating command line "link.exe @C:\DOCUME~1\stk01\LOCALS~1\Temp\RSP1255.tmp"
|
Creating command line "link.exe @C:\DOCUME~1\stk01\LOCALS~1\Temp\RSP1340.tmp"
|
||||||
<h3>Output Window</h3>
|
<h3>Output Window</h3>
|
||||||
Compiling...
|
Compiling...
|
||||||
abort.c
|
abort.c
|
||||||
address.c
|
address.c
|
||||||
ai.c
|
ai.c
|
||||||
c:\code\bacnet-stack\demo\object\ai.c(87) : warning C4305: 'initializing' : truncation from 'const double ' to 'float '
|
|
||||||
c:\code\bacnet-stack\demo\object\ai.c(125) : warning C4305: 'function' : truncation from 'const double ' to 'float '
|
|
||||||
ao.c
|
ao.c
|
||||||
c:\code\bacnet-stack\demo\object\ao.c(163) : warning C4305: 'initializing' : truncation from 'const double ' to 'float '
|
|
||||||
apdu.c
|
apdu.c
|
||||||
arf.c
|
arf.c
|
||||||
av.c
|
av.c
|
||||||
c:\code\bacnet-stack\demo\object\av.c(162) : warning C4305: 'initializing' : truncation from 'const double ' to 'float '
|
|
||||||
bacapp.c
|
bacapp.c
|
||||||
bacdcode.c
|
bacdcode.c
|
||||||
bacerror.c
|
bacerror.c
|
||||||
@@ -137,8 +133,6 @@ bo.c
|
|||||||
bv.c
|
bv.c
|
||||||
crc.c
|
crc.c
|
||||||
Generating Code...
|
Generating Code...
|
||||||
c:\code\bacnet-stack\demo\object\bacfile.c(322) : warning C4761: integral size mismatch in argument; conversion supplied
|
|
||||||
c:\code\bacnet-stack\bacapp.c(351) : warning C4761: integral size mismatch in argument; conversion supplied
|
|
||||||
Compiling...
|
Compiling...
|
||||||
datalink.c
|
datalink.c
|
||||||
dcc.c
|
dcc.c
|
||||||
@@ -154,31 +148,24 @@ iam.c
|
|||||||
indtext.c
|
indtext.c
|
||||||
lsp.c
|
lsp.c
|
||||||
main.c
|
main.c
|
||||||
|
mso.c
|
||||||
noserv.c
|
noserv.c
|
||||||
npdu.c
|
npdu.c
|
||||||
reject.c
|
reject.c
|
||||||
ringbuf.c
|
ringbuf.c
|
||||||
rp.c
|
rp.c
|
||||||
s_rp.c
|
|
||||||
Generating Code...
|
Generating Code...
|
||||||
c:\code\bacnet-stack\demo\handler\s_rp.c(92) : warning C4761: integral size mismatch in argument; conversion supplied
|
|
||||||
c:\code\bacnet-stack\npdu.c(340) : warning C4761: integral size mismatch in argument; conversion supplied
|
|
||||||
c:\code\bacnet-stack\demo\handler\h_rp_a.c(73) : warning C4761: integral size mismatch in argument; conversion supplied
|
|
||||||
Compiling...
|
Compiling...
|
||||||
|
s_rp.c
|
||||||
s_whois.c
|
s_whois.c
|
||||||
s_wp.c
|
s_wp.c
|
||||||
tsm.c
|
tsm.c
|
||||||
txbuf.c
|
txbuf.c
|
||||||
whois.c
|
whois.c
|
||||||
wp.c
|
wp.c
|
||||||
mso.c
|
|
||||||
c:\code\bacnet-stack\demo\object\mso.c(308) : warning C4244: '=' : conversion from 'unsigned long ' to 'unsigned char ', possible loss of data
|
|
||||||
c:\code\bacnet-stack\demo\object\mso.c(333) : warning C4244: '=' : conversion from 'unsigned long ' to 'unsigned char ', possible loss of data
|
|
||||||
Generating Code...
|
Generating Code...
|
||||||
c:\code\bacnet-stack\wp.c(134) : warning C4761: integral size mismatch in argument; conversion supplied
|
|
||||||
c:\code\bacnet-stack\demo\handler\s_wp.c(95) : warning C4761: integral size mismatch in argument; conversion supplied
|
|
||||||
Linking...
|
Linking...
|
||||||
Creating temporary file "C:\DOCUME~1\stk01\LOCALS~1\Temp\RSP1257.tmp" with contents
|
Creating temporary file "C:\DOCUME~1\stk01\LOCALS~1\Temp\RSP1342.tmp" with contents
|
||||||
[
|
[
|
||||||
/nologo /o"Debug/bacnet.bsc"
|
/nologo /o"Debug/bacnet.bsc"
|
||||||
".\Debug\abort.sbr"
|
".\Debug\abort.sbr"
|
||||||
@@ -215,6 +202,7 @@ Creating temporary file "C:\DOCUME~1\stk01\LOCALS~1\Temp\RSP1257.tmp" with conte
|
|||||||
".\Debug\indtext.sbr"
|
".\Debug\indtext.sbr"
|
||||||
".\Debug\lsp.sbr"
|
".\Debug\lsp.sbr"
|
||||||
".\Debug\main.sbr"
|
".\Debug\main.sbr"
|
||||||
|
".\Debug\mso.sbr"
|
||||||
".\Debug\noserv.sbr"
|
".\Debug\noserv.sbr"
|
||||||
".\Debug\npdu.sbr"
|
".\Debug\npdu.sbr"
|
||||||
".\Debug\reject.sbr"
|
".\Debug\reject.sbr"
|
||||||
@@ -226,16 +214,15 @@ Creating temporary file "C:\DOCUME~1\stk01\LOCALS~1\Temp\RSP1257.tmp" with conte
|
|||||||
".\Debug\tsm.sbr"
|
".\Debug\tsm.sbr"
|
||||||
".\Debug\txbuf.sbr"
|
".\Debug\txbuf.sbr"
|
||||||
".\Debug\whois.sbr"
|
".\Debug\whois.sbr"
|
||||||
".\Debug\wp.sbr"
|
".\Debug\wp.sbr"]
|
||||||
".\Debug\mso.sbr"]
|
Creating command line "bscmake.exe @C:\DOCUME~1\stk01\LOCALS~1\Temp\RSP1342.tmp"
|
||||||
Creating command line "bscmake.exe @C:\DOCUME~1\stk01\LOCALS~1\Temp\RSP1257.tmp"
|
|
||||||
Creating browse info file...
|
Creating browse info file...
|
||||||
<h3>Output Window</h3>
|
<h3>Output Window</h3>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<h3>Results</h3>
|
<h3>Results</h3>
|
||||||
bacnet.exe - 0 error(s), 13 warning(s)
|
bacnet.exe - 0 error(s), 0 warning(s)
|
||||||
</pre>
|
</pre>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|||||||
@@ -4,6 +4,30 @@ Build for Visual C++ 6.0
|
|||||||
When building the BACnet stack using Visual C++ compiler,
|
When building the BACnet stack using Visual C++ compiler,
|
||||||
there are some settings that are important.
|
there are some settings that are important.
|
||||||
|
|
||||||
|
Q. Are there some global configuration options for this BACnet stack?
|
||||||
|
|
||||||
|
A. The BACnet stack uses some preprocessor defines to configure
|
||||||
|
a number of subtle personalities.
|
||||||
|
PRINT_ENABLED=1 - enables printing to stdio
|
||||||
|
BIG_ENDIAN=0 - chooses the BACnet encoding and decoding order
|
||||||
|
BACDL_BIP=1 - chooses BACnet/IP for the datalink layer
|
||||||
|
BACDL_ETHERNET=0 - chooses BACnet Ethernet for the datalink layer
|
||||||
|
BACDL_ARCNET=0 - chooses BACnet ARCNET for the datalink layer
|
||||||
|
BACDL_MSTP=0 - chooses BACnet MS/TP for the datalink layer
|
||||||
|
USE_INADDR=1 - uses INADDR_BROADCAST for broadcast rather than CLASSx
|
||||||
|
TSM_ENABLED=1 - enables the Transaction State Machine for clients
|
||||||
|
BIP_DEBUG=1 - enables print statements for debugging
|
||||||
|
In Visual C++, add a Preprocessor Definition by:
|
||||||
|
1. Select "Project" menu
|
||||||
|
2. Select "Settings..."
|
||||||
|
3. Select the "C/C++" tab (3rd Tab)
|
||||||
|
4. Select the Category: General
|
||||||
|
5. You can see the "Preprocessor Definitions:" box
|
||||||
|
6. Type OPTION_NAME=1 or OPTION_NAME=0 in that edit box
|
||||||
|
using a comma to separate multiple options.
|
||||||
|
7. Press OK
|
||||||
|
8. Compile the entire project again...
|
||||||
|
|
||||||
Q. MSVC refuses to open bacnet.dsw and bacnet.dsp.
|
Q. MSVC refuses to open bacnet.dsw and bacnet.dsp.
|
||||||
|
|
||||||
A. bacnet.dsw and bacnet.dsp are text files that were retrieved
|
A. bacnet.dsw and bacnet.dsp are text files that were retrieved
|
||||||
@@ -51,6 +75,19 @@ its datalink layer. In Visual C++, add a Preprocessor Definition by:
|
|||||||
7. Press OK
|
7. Press OK
|
||||||
8. Compile the entire project again...
|
8. Compile the entire project again...
|
||||||
|
|
||||||
|
Q. error LNK2001: unresolved external symbol _bacapp_print
|
||||||
|
|
||||||
|
A. The BACnet stack uses a preprocessor define to configure
|
||||||
|
printing to stdio. In Visual C++, add a Preprocessor Definition by:
|
||||||
|
1. Select "Project" menu
|
||||||
|
2. Select "Settings..."
|
||||||
|
3. Select the "C/C++" tab (3rd Tab)
|
||||||
|
4. Select the Category: General
|
||||||
|
5. You can see the "Preprocessor Definitions:" box
|
||||||
|
6. Type PRINT_ENABLED=1 in that edit box (using a comma if necessary)
|
||||||
|
7. Press OK
|
||||||
|
8. Compile the entire project again...
|
||||||
|
|
||||||
Q. error LNK2001: unresolved external symbol __imp__closesocket@4
|
Q. error LNK2001: unresolved external symbol __imp__closesocket@4
|
||||||
|
|
||||||
A. Visual C++ needs to have the Winsock library to be happy:
|
A. Visual C++ needs to have the Winsock library to be happy:
|
||||||
|
|||||||
Reference in New Issue
Block a user