[xml] Win32 Debug/Release versions



Does anyone else use a "d" suffix on DLL and lib files to distinguish
between debug and release versions (i.e. libxml.dll and libxmld.dll)?  I've
altered my copies of libxml2 and libxslt to do this.  As per the LGPL
licensing agreement I'd like to return these alterations to the code base
(if anyone else wants them).
The changes that I made were to change the ouput filename for the debug
system to end with a "d" suffix and this updated to the lib file entry
accordingly.  This change is shown in the following diff

*** original_libxslt_so.dsp     Thu Jul 12 08:17:56 2001
--- modified_libxslt_so.dsp     Thu Jul 12 08:18:32 2001
***************
*** 53,59 ****
  # ADD BSC32 /nologo
  LINK32=link.exe
  # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib
comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib
odbc32.lib odbccp32.lib /nologo /dll /machine:I386
! # ADD LINK32 ..\..\..\gnome-xml\win32\libxml2\release_so\libxml2.lib
/nologo /dll /machine:I386 /out:"Release/libxslt.dll"
  
  !ELSEIF  "$(CFG)" == "libxslt_so - Win32 Debug"
  
--- 53,59 ----
  # ADD BSC32 /nologo
  LINK32=link.exe
  # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib
comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib
odbc32.lib odbccp32.lib /nologo /dll /machine:I386
! # ADD LINK32 ..\..\..\libxml2-2.4.0\win32\libxml2\release_so\libxml2.lib
/nologo /dll /machine:I386 /out:"Release/libxslt.dll"
  
  !ELSEIF  "$(CFG)" == "libxslt_so - Win32 Debug"
  
***************
*** 79,85 ****
  # ADD BSC32 /nologo
  LINK32=link.exe
  # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib
comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib
odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
! # ADD LINK32 ..\..\..\gnome-xml\win32\libxml2\debug_so\libxml2.lib /nologo
/dll /debug /machine:I386 /out:"Debug/libxslt.dll" /pdbtype:sept
  
  !ENDIF 
  
--- 79,85 ----
  # ADD BSC32 /nologo
  LINK32=link.exe
  # ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib
comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib
odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
! # ADD LINK32 ..\..\..\libxml2-2.4.0\win32\libxml2\debug_so\libxml2D.lib
/nologo /dll /debug /machine:I386 /out:"Debug/libxsltD.dll" /pdbtype:sept
  
  !ENDIF 
  

The next file that needed to be changed for this to work was the .DEF (and
.DEF.src) file.  If the "LIBRARY libxml" line isn't present, then the MSCC
linker uses the output DLL name to determine the library name.  Without this
change, the output file would end in a "d" for debug mode, but any
applications that linked with libxml2d.dll would still be looking for
libxml2.dll by mistake.

On a side note, are there any plans to create a libxslt.def.src?  The
libxslt.def that is packaged with libxslt 1.0.0 is already missing the
xsltProfileStylesheet entry needed for xsltproc to link properly.





[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]