Index: wml_aux/iselect/Makefile.in
--- wml_aux/iselect/Makefile.in.orig	2005-12-01 18:50:13 +0100
+++ wml_aux/iselect/Makefile.in	2008-01-02 16:56:54 +0100
@@ -12,7 +12,7 @@
 
 #   compiler tools
 CC      = @CC@
-CFLAGS  = @CFLAGS@ -I.
+CFLAGS  = @CFLAGS@ -I. @CPPFLAGS@
 LDFLAGS = @LDFLAGS@
 LIBS    = @LIBS@
 debug   = @debug@
Index: wml_aux/tidy/Makefile
sed: -e expression #1, char 23: unknown option to `s'
Index: wml_backend/p2_mp4h/pcre/pcre.c
--- wml_backend/p2_mp4h/pcre/pcre.c.orig	2005-12-01 18:50:13 +0100
+++ wml_backend/p2_mp4h/pcre/pcre.c	2008-01-02 16:56:54 +0100
@@ -716,12 +716,23 @@
 
 while ((cd->ctypes[*p] & ctype_digit) != 0) min = min * 10 + *p++ - '0';
 
+if (min < 0 || min > 65535)
+  {
+  *errorptr = ERR5;
+  return p;
+  }
+
 if (*p == '}') max = min; else
   {
   if (*(++p) != '}')
     {
     max = 0;
     while((cd->ctypes[*p] & ctype_digit) != 0) max = max * 10 + *p++ - '0';
+    if (max < 0 || max > 65535)
+      {
+      *errorptr = ERR5;
+      return p;
+      }
     if (max < min)
       {
       *errorptr = ERR4;
Index: wml_backend/p3_eperl/configure.in
--- wml_backend/p3_eperl/configure.in.orig	2005-12-01 18:50:13 +0100
+++ wml_backend/p3_eperl/configure.in	2008-01-02 16:57:28 +0100
@@ -159,7 +159,7 @@
     define )
         rc=yes
         AC_DEFINE(HAVE_PERL_DYNALOADER)
-        perl_dla=$perl_archlib/auto/DynaLoader/DynaLoader.a
+        perl_dla=
         ;;
     * )
         rc=no
Index: wml_backend/p3_eperl/configure
--- wml_backend/p3_eperl/configure.orig	2005-12-01 18:50:13 +0100
+++ wml_backend/p3_eperl/configure	2008-01-02 16:57:37 +0100
@@ -678,7 +678,7 @@
 #define HAVE_PERL_DYNALOADER 1
 EOF
 
-        perl_dla=$perl_archlib/auto/DynaLoader/DynaLoader.a
+        perl_dla=
         ;;
     * )
         rc=no
Index: wml_backend/p3_eperl/eperl_main.c
--- wml_backend/p3_eperl/eperl_main.c.orig	2005-12-01 18:50:13 +0100
+++ wml_backend/p3_eperl/eperl_main.c	2008-01-02 16:56:54 +0100
@@ -265,7 +265,7 @@
     exit(rc);
 }
 
-struct option options[] = {
+static struct option options[] = {
     { "define",         1, NULL, 'd' },
     { "setenv",         1, NULL, 'D' },
     { "includedir",     1, NULL, 'I' },
Index: wml_common/gd/Makefile.PL.in
--- wml_common/gd/Makefile.PL.in.orig	2005-12-01 18:50:13 +0100
+++ wml_common/gd/Makefile.PL.in	2008-01-02 16:56:54 +0100
@@ -12,8 +12,8 @@
 
     # Uncomment the line below if you're getting link errors
     # having to do with missing math functions (like floor)
-    'LIBS'      =>  ["-lm @LIBPNG@"],
-    'DEFINE'	=> '@DEFS@'
+    'LIBS'      => ["-lm @LIBPNG@ -L/openpkg-dev/lib -lz"],
+    'DEFINE'	=> '@DEFS@ @CPPFLAGS@'
     # Uncomment the line below if you're using a perl compiled
     # for fastCGI (http://www.fastcgi.com/).
     # 'DEFINE'	=> '-DFCGI'
