[fenix] 106/127: Fix the FTBFS on GNU/kFreeBSD.

Peter Pentchev roam at ringlet.net
Thu Dec 17 14:39:40 UTC 2015


This is an automated email from the git hooks/post-receive script.

roam-guest pushed a commit to branch master
in repository fenix.

commit d3746e0e942e9f8d478d46c48813b6688bf913ca
Author: Peter Pentchev <roam at ringlet.net>
Date:   Tue Mar 15 12:16:11 2011 +0000

    Fix the FTBFS on GNU/kFreeBSD.
---
 debian/changelog              |   6 +++
 debian/patches/kfreebsd.patch | 101 ++++++++++++++++++++++++++++++++++++++++++
 debian/patches/series         |   1 +
 3 files changed, 108 insertions(+)

diff --git a/debian/changelog b/debian/changelog
index ea7f439..5a42380 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,9 @@
+fenix (0.92a.dfsg1-8) UNRELEASED; urgency=low
+
+  * Add the kfreebsd patch to fix the FTBFS on GNU/kFreeBSD.
+
+ -- Peter Pentchev <roam at ringlet.net>  Mon, 14 Mar 2011 12:44:14 +0200
+
 fenix (0.92a.dfsg1-7) unstable; urgency=low
 
   * Team upload.
diff --git a/debian/patches/kfreebsd.patch b/debian/patches/kfreebsd.patch
new file mode 100644
index 0000000..b4b53e8
--- /dev/null
+++ b/debian/patches/kfreebsd.patch
@@ -0,0 +1,101 @@
+Description: Fix the build on GNU/kFreeBSD
+Forwarded: no
+Author: Peter Pentchev <roam at ringlet.net>
+Last-Update: 2011-03-15
+
+--- a/configure
++++ b/configure
+@@ -1621,7 +1621,7 @@
+ 
+ 
+ case "$target_os" in
+-    linux-gnu*)
++    linux-gnu*|kfreebsd-gnu*)
+         case "$target_cpu" in
+             powerpc*)
+ 	            COMMON_CFLAGS="-Wall -DTARGET_LinuxPPC -DTARGET_Linux"
+--- a/configure.in
++++ b/configure.in
+@@ -40,7 +40,7 @@
+ 
+ dnl Aqui es donde se chequeara el SO, pero solo hay una opcion xD
+ case "$target_os" in
+-    linux-gnu*)
++    linux-gnu*|kfreebsd-gnu*)
+         case "$target_cpu" in
+             powerpc*)
+ 	            COMMON_CFLAGS="-Wall -DTARGET_LinuxPPC -DTARGET_Linux"
+--- a/fxi/src/i_func.c
++++ b/fxi/src/i_func.c
+@@ -3577,6 +3577,27 @@
+ 
+ #elif !defined(TARGET_MAC)
+     /* Linux and other Unix (?) */
++#ifdef __FreeBSD_kernel__
++    long pagesize, freeram;
++
++    pagesize = sysconf(_SC_PAGE_SIZE);
++    freeram = sysconf(_SC_AVPHYS_PAGES);
++    if (pagesize == -1L)
++    {
++	gr_con_printf (_("No pagesize"));
++	return -1;
++    }
++    else if (freeram == -1L)
++    {
++	gr_con_printf (_("No freeram"));
++	return -1;
++    }
++    else
++    {
++	gr_con_printf (_("Returning %d"), pagesize * freeram);
++	return pagesize * freeram;
++    }
++#else
+     struct sysinfo meminf;
+     int fv;
+ 
+@@ -3596,6 +3617,7 @@
+         gr_con_printf (_("Returning %d"), meminf.freeram);
+         return meminf.freeram;
+     }
++#endif
+ 
+     return -1;
+ 
+@@ -3623,6 +3645,27 @@
+ 
+ #elif !defined(TARGET_MAC)
+     /* Linux and other Unix (?) */
++#ifdef __FreeBSD_kernel__
++    long pagesize, totalram;
++
++    pagesize = sysconf(_SC_PAGE_SIZE);
++    totalram = sysconf(_SC_PHYS_PAGES);
++    if (pagesize == -1L)
++    {
++	gr_con_printf (_("No pagesize"));
++	return -1;
++    }
++    else if (totalram == -1L)
++    {
++	gr_con_printf (_("No totalram"));
++	return -1;
++    }
++    else
++    {
++	gr_con_printf (_("Returning %d"), pagesize * totalram);
++	return pagesize * totalram;
++    }
++#else
+     struct sysinfo meminf;
+     int fv;
+ 
+@@ -3636,6 +3679,7 @@
+         return meminf.totalram * meminf.mem_unit;
+     else
+         return meminf.totalram;
++#endif
+ 
+     return -1;
+ 
diff --git a/debian/patches/series b/debian/patches/series
index c0b7b92..afeb6af 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -24,3 +24,4 @@ warning_fixes.patch
 string_alloc_crash.patch
 spelling.patch
 headers.patch
+kfreebsd.patch

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-games/fenix.git



More information about the Pkg-games-commits mailing list