Description: <short summary of the patch>
 TODO: Put a short summary on the line above and replace this paragraph
 with a longer explanation of this change. Complete the meta-information
 with other relevant fields (see below for details). To make it easier, the
 information below has been extracted from the changelog. Adjust it or drop
 it.
 .
 gcl (2.6.7+dfsga-16) unstable; urgency=high
 .
   * no linker script on hurd;fix OBJ_ALIGN
Author: Camm Maguire <camm@debian.org>

---
The information above should follow the Patch Tagging Guidelines, please
checkout http://dep.debian.net/deps/dep3/ to learn about the format. Here
are templates for supplementary fields that you might want to add:

Origin: <vendor|upstream|other>, <url of original patch>
Bug: <url in upstream bugtracker>
Bug-Debian: http://bugs.debian.org/<bugnumber>
Bug-Ubuntu: https://launchpad.net/bugs/<bugnumber>
Forwarded: <no|not-needed|url proving that it has been forwarded>
Reviewed-By: <name and email of someone who approved the patch>
Last-Update: <YYYY-MM-DD>

--- gcl-2.6.7+dfsga.orig/configure
+++ gcl-2.6.7+dfsga/configure
@@ -660,9 +660,9 @@ CLSTANDARD
 SYSTEM
 FLISP
 HAVE_LONG_LONG
+PAGEWIDTH
 DOUBLE_BIGENDIAN
 WORDS_BIGENDIAN
-PAGEWIDTH
 LIBIBERTY
 LIBBFD
 BUILD_BFD
@@ -6045,6 +6045,93 @@ _ACEOF
 
 ####  Memory areas and alignment
 
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for byte order" >&5
+$as_echo_n "checking for byte order... " >&6; }
+if test "$cross_compiling" = yes; then :
+  { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "cannot run test program while cross compiling
+See \`config.log' for more details" "$LINENO" 5; }
+else
+  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h.  */
+
+
+
+int
+main ()
+{
+
+
+		/* Are we little or big endian?  Adapted from Harbison&Steele.  */
+		union {long l;char c[sizeof(long)];} u;
+		u.l = 1;
+		return u.c[sizeof(long)-1] ? 1 : 0;
+
+  ;
+  return 0;
+}
+_ACEOF
+if ac_fn_c_try_run "$LINENO"; then :
+
+	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: little" >&5
+$as_echo "little" >&6; }
+else
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: big" >&5
+$as_echo "big" >&6; }
+
+$as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
+
+fi
+rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
+  conftest.$ac_objext conftest.beam conftest.$ac_ext
+fi
+
+
+
+
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for word order" >&5
+$as_echo_n "checking for word order... " >&6; }
+if test "$cross_compiling" = yes; then :
+  { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "cannot run test program while cross compiling
+See \`config.log' for more details" "$LINENO" 5; }
+else
+  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h.  */
+
+
+
+int
+main ()
+{
+
+		/* Are we little or big endian?  Adapted from Harbison&Steele.  */
+		union {double d;int l[sizeof(double)/sizeof(int)];} u;
+		u.d = 1.0;
+		return u.l[sizeof(double)/sizeof(int)-1] ? 0 : 1;
+
+  ;
+  return 0;
+}
+_ACEOF
+if ac_fn_c_try_run "$LINENO"; then :
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: little" >&5
+$as_echo "little" >&6; }
+else
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: big" >&5
+$as_echo "big" >&6; }
+
+$as_echo "#define DOUBLE_BIGENDIAN 1" >>confdefs.h
+
+fi
+rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
+  conftest.$ac_objext conftest.beam conftest.$ac_ext
+fi
+
+
+
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for required object alignment" >&5
 $as_echo_n "checking for required object alignment... " >&6; }
 if test "$cross_compiling" = yes; then :
@@ -6654,6 +6741,8 @@ $as_echo "$cstack_direction" >&6; }
 
 
 
+if test "$use" != "386-gnu" ; then
+
    { $as_echo "$as_me:${as_lineno-$LINENO}: checking finding default linker script" >&5
 $as_echo_n "checking finding default linker script... " >&6; }
    touch unixport/gcl.script
@@ -6695,6 +6784,8 @@ $as_echo "none" >&6; }
      rm -f gcl.script
    fi
 
+fi
+
 
 
 
@@ -6834,93 +6925,6 @@ _ACEOF
 fi
 
 
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for byte order" >&5
-$as_echo_n "checking for byte order... " >&6; }
-if test "$cross_compiling" = yes; then :
-  { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "cannot run test program while cross compiling
-See \`config.log' for more details" "$LINENO" 5; }
-else
-  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h.  */
-
-
-
-int
-main ()
-{
-
-
-		/* Are we little or big endian?  Adapted from Harbison&Steele.  */
-		union {long l;char c[sizeof(long)];} u;
-		u.l = 1;
-		return u.c[sizeof(long)-1] ? 1 : 0;
-
-  ;
-  return 0;
-}
-_ACEOF
-if ac_fn_c_try_run "$LINENO"; then :
-
-	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: little" >&5
-$as_echo "little" >&6; }
-else
-  { $as_echo "$as_me:${as_lineno-$LINENO}: result: big" >&5
-$as_echo "big" >&6; }
-
-$as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
-
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
-  conftest.$ac_objext conftest.beam conftest.$ac_ext
-fi
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for word order" >&5
-$as_echo_n "checking for word order... " >&6; }
-if test "$cross_compiling" = yes; then :
-  { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "cannot run test program while cross compiling
-See \`config.log' for more details" "$LINENO" 5; }
-else
-  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h.  */
-
-
-
-int
-main ()
-{
-
-		/* Are we little or big endian?  Adapted from Harbison&Steele.  */
-		union {double d;int l[sizeof(double)/sizeof(int)];} u;
-		u.d = 1.0;
-		return u.l[sizeof(double)/sizeof(int)-1] ? 0 : 1;
-
-  ;
-  return 0;
-}
-_ACEOF
-if ac_fn_c_try_run "$LINENO"; then :
-  { $as_echo "$as_me:${as_lineno-$LINENO}: result: little" >&5
-$as_echo "little" >&6; }
-else
-  { $as_echo "$as_me:${as_lineno-$LINENO}: result: big" >&5
-$as_echo "big" >&6; }
-
-$as_echo "#define DOUBLE_BIGENDIAN 1" >>confdefs.h
-
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
-  conftest.$ac_objext conftest.beam conftest.$ac_ext
-fi
-
-
-
 
 
 # On systems with execshield, brk is randomized.  We need to catch
--- gcl-2.6.7+dfsga.orig/configure.in
+++ gcl-2.6.7+dfsga/configure.in
@@ -1102,6 +1102,36 @@ AC_CHECK_SIZEOF(long,0)
 
 ####  Memory areas and alignment
 
+AC_MSG_CHECKING(for byte order)
+AC_RUN_IFELSE([
+	AC_LANG_PROGRAM([[
+		]],[[
+
+		/* Are we little or big endian?  Adapted from Harbison&Steele.  */
+		union {long l;char c[sizeof(long)];} u;
+		u.l = 1;
+		return u.c[sizeof(long)-1] ? 1 : 0;
+	]])],[
+	AC_MSG_RESULT(little)],
+	[AC_MSG_RESULT(big) 
+	AC_DEFINE(WORDS_BIGENDIAN,1,[big endian byte order])])
+AC_SUBST(WORDS_BIGENDIAN)
+
+
+AC_MSG_CHECKING(for word order)
+AC_RUN_IFELSE([
+	AC_LANG_PROGRAM([[
+		]],[[
+		/* Are we little or big endian?  Adapted from Harbison&Steele.  */
+		union {double d;int l[sizeof(double)/sizeof(int)];} u;
+		u.d = 1.0;
+		return u.l[sizeof(double)/sizeof(int)-1] ? 0 : 1;
+	]])],
+	[AC_MSG_RESULT(little)],
+	[AC_MSG_RESULT(big) 
+	AC_DEFINE(DOUBLE_BIGENDIAN,1,[big endian word order])])
+AC_SUBST(DOUBLE_BIGENDIAN)
+
 AC_MSG_CHECKING([for required object alignment])
 AC_RUN_IFELSE([AC_LANG_PROGRAM([[
         #include <stdio.h>
@@ -1456,6 +1486,8 @@ dnl fi
 dnl $CC foo.c -o foo
 dnl if ./foo ; then
 
+if test "$use" != "386-gnu" ; then
+
    AC_MSG_CHECKING([finding default linker script])
    touch unixport/gcl.script
    echo "int main() {return 0;}" >foo.c
@@ -1489,6 +1521,8 @@ dnl if ./foo ; then
      rm -f gcl.script
    fi
 
+fi
+
    dnl old_LDFLAGS="$LDFLAGS"
    dnl LDFLAGS="$LDFLAGS $TLDFLAGS"
    dnl AC_MSG_CHECKING([revised DBEGIN])
@@ -1694,36 +1728,6 @@ if test "$enable_immfix" = "yes" ; then
 fi
 
 
-AC_MSG_CHECKING(for byte order)
-AC_RUN_IFELSE([
-	AC_LANG_PROGRAM([[
-		]],[[
-
-		/* Are we little or big endian?  Adapted from Harbison&Steele.  */
-		union {long l;char c[sizeof(long)];} u;
-		u.l = 1;
-		return u.c[sizeof(long)-1] ? 1 : 0;
-	]])],[
-	AC_MSG_RESULT(little)],
-	[AC_MSG_RESULT(big) 
-	AC_DEFINE(WORDS_BIGENDIAN,1,[big endian byte order])])
-AC_SUBST(WORDS_BIGENDIAN)
-
-
-AC_MSG_CHECKING(for word order)
-AC_RUN_IFELSE([
-	AC_LANG_PROGRAM([[
-		]],[[
-		/* Are we little or big endian?  Adapted from Harbison&Steele.  */
-		union {double d;int l[sizeof(double)/sizeof(int)];} u;
-		u.d = 1.0;
-		return u.l[sizeof(double)/sizeof(int)-1] ? 0 : 1;
-	]])],
-	[AC_MSG_RESULT(little)],
-	[AC_MSG_RESULT(big) 
-	AC_DEFINE(DOUBLE_BIGENDIAN,1,[big endian word order])])
-AC_SUBST(DOUBLE_BIGENDIAN)
-
 dnl AC_MSG_CHECKING(for word order)
 dnl AC_TRY_RUN([int main () {
 dnl   /* Are we little or big endian?  Adapted from Harbison&Steele.  */
--- gcl-2.6.7+dfsga.orig/o/alloc.c
+++ gcl-2.6.7+dfsga/o/alloc.c
@@ -1451,7 +1451,7 @@ DEFUN_NEW("GPROF-START",object,fSgprof_s
 
   if (!gprof_on) {
     start=start ? start : textstart;
-    end=end ? end : (unsigned long)core_end;
+    end=end ? end : textend;
     monstartup(start,end);
     gprof_on=1;
     if (!n && atexit(gprof_cleanup)) {
@@ -1784,7 +1784,7 @@ void *
 calloc(size_t nelem, size_t elsize)
 {
 	char *ptr;
-	int i;
+	long i;
 
 	ptr = malloc(i = nelem*elsize);
 	while (--i >= 0)
