Small amount of changes. Haven't bothered with the tests.

* Build as Unicode project.
* Include non-Unicode version of winldap.h since it's implemented and avoids
  conversions. Maybe this should use the Unicode version and convert strings
  as needed on the fly (UTF-8 apply?).
* Added a couple of needed errno values.
Index: include/apr_ldap.hw
===================================================================
--- include/apr_ldap.hw (revision 574284)
+++ include/apr_ldap.hw (working copy)
@@ -63,10 +63,19 @@
 /*
  * Include the standard LDAP header files.
  */
-
+#ifndef _WIN32_WCE
 #include <winldap.h>
+#else
+/* CE is Unicode by default, but LDAP has ASCII functions, include the
+ * non-Unicode version of the LDAP header.
+ */
+#undef UNICODE
+#undef _UNICODE
+#include <winldap.h>
+#define UNICODE
+#define _UNICODE
+#endif
 
-
 /*
  * Detected standard functions
  */
Index: include/private/apu_config.hw
===================================================================
--- include/private/apu_config.hw       (revision 574284)
+++ include/private/apu_config.hw       (working copy)
@@ -34,6 +34,12 @@
 /* define if Expat 1.0 or 1.1 was found */
 /* #undef APR_HAVE_OLD_EXPAT */
 
+/* Needed CE errno defines. */
+#ifdef _WIN32_WCE
+#define E2BIG 7
+#define EINVAL 22
+#define EILSEQ 42
+#endif
 
 #endif /* APU_CONFIG_H */
 #endif /* WIN32 */

Reply via email to