[xml] Borland C++ Builder (Windows)



Hello all,

I have received project files for Borland C++ Builder 5 from Moritz Both for
libxml. Including these into libxml source would require two things:

  1. A win32/bcb5 directory for the project files
  2. Minor modifications to the source (only preprocessor directives)

The project files are attached to this email. The patch for the source
follows below.

If there are no objections, or corrections, or ideas or whatever from other
BCB users, I would commit these.

Ciao
Igor

*******

The BCB 5 patch follows (it really does nothing but follows the MS compiler
in its preprocessor path):



*** gnome-xml/threads.c 18 Mar 2002 19:37:03 -0000 1.10
--- gnome-xml/threads.c 10 Apr 2002 22:04:07 -0000
***************
*** 87,93 ****
  static pthread_t mainthread;
  static pthread_once_t once_control = PTHREAD_ONCE_INIT;
  #elif defined HAVE_WIN32_THREADS
! #ifdef _MSC_VER
  static __declspec (thread) xmlGlobalState tlstate;
  static __declspec (thread) int tlstate_inited = 0;
  #else
--- 87,93 ----
  static pthread_t mainthread;
  static pthread_once_t once_control = PTHREAD_ONCE_INIT;
  #elif defined HAVE_WIN32_THREADS
! #if defined(_MSC_VER) || defined(__BORLANDC__)
  static __declspec (thread) xmlGlobalState tlstate;
  static __declspec (thread) int tlstate_inited = 0;
  #else
***************
*** 330,336 ****
   */

  #ifdef HAVE_WIN32_THREADS
! #ifndef _MSC_VER
  typedef struct _xmlGlobalStateCleanupHelperParams
  {
   HANDLE thread;
--- 330,336 ----
   */

  #ifdef HAVE_WIN32_THREADS
! #if !defined(_MSC_VER) && !defined(__BORLANDC__)
  typedef struct _xmlGlobalStateCleanupHelperParams
  {
   HANDLE thread;
***************
*** 366,372 ****
      }
      return (globalval);
  #elif defined HAVE_WIN32_THREADS
! #ifdef _MSC_VER
   if (!tlstate_inited)
   {
    tlstate_inited = 1;
--- 366,372 ----
      }
      return (globalval);
  #elif defined HAVE_WIN32_THREADS
! #if defined(_MSC_VER) || defined(__BORLANDC__)
   if (!tlstate_inited)
   {
    tlstate_inited = 1;
***************
*** 525,531 ****
     (void) pthread_key_create(&globalkey, xmlFreeGlobalState);
      mainthread = pthread_self();
  #elif defined HAVE_WIN32_THREADS
! #ifndef _MSC_VER
   globalkey = TlsAlloc ();
  #endif /* _MSC_VER */
   mainthread = GetCurrentThreadId ();
--- 525,531 ----
     (void) pthread_key_create(&globalkey, xmlFreeGlobalState);
      mainthread = pthread_self();
  #elif defined HAVE_WIN32_THREADS
! #if !defined(_MSC_VER) && !defined(__BORLANDC__)
   globalkey = TlsAlloc ();
  #endif /* _MSC_VER */
   mainthread = GetCurrentThreadId ();
*** gnome-xml/include/libxml/encoding.h 12 Mar 2002 18:46:39 -0000 1.27
--- gnome-xml/include/libxml/encoding.h 10 Apr 2002 22:04:08 -0000
***************
*** 21,27 ****
  #ifndef __XML_CHAR_ENCODING_H__
  #define __XML_CHAR_ENCODING_H__

! #if defined(WIN32) && defined(_MSC_VER)
  #include <libxml/xmlwin32version.h>
  #else
  #include <libxml/xmlversion.h>
--- 21,27 ----
  #ifndef __XML_CHAR_ENCODING_H__
  #define __XML_CHAR_ENCODING_H__

! #if defined(WIN32) && (defined(_MSC_VER) || defined(__BORLANDC__))
  #include <libxml/xmlwin32version.h>
  #else
  #include <libxml/xmlversion.h>
*** gnome-xml/include/libxml/tree.h 20 Mar 2002 21:55:57 -0000 1.106
--- gnome-xml/include/libxml/tree.h 10 Apr 2002 22:04:09 -0000
***************
*** 14,20 ****
  #define __XML_TREE_H__

  #include <stdio.h>
! #if defined(WIN32) && defined(_MSC_VER)
  #include <libxml/xmlwin32version.h>
  #else
  #include <libxml/xmlversion.h>
--- 14,20 ----
  #define __XML_TREE_H__

  #include <stdio.h>
! #if defined(WIN32) && (defined(_MSC_VER) || defined(__BORLANDC__))
  #include <libxml/xmlwin32version.h>
  #else
  #include <libxml/xmlversion.h>

Attachment: bcb5.zip
Description: Zip compressed data



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