[mupen64plus-video-glide64] 21/172: Add dummy PATH_MAX on systems without it

Sven Eckelmann ecsv-guest at moszumanska.debian.org
Thu Nov 26 06:11:41 UTC 2015


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

ecsv-guest pushed a commit to branch master
in repository mupen64plus-video-glide64.

commit 193f44ef28410f95d4cc6792deea5d0b33380861
Author: Sven Eckelmann <sven.eckelmann at gmx.de>
Date:   Tue Jul 13 20:55:24 2010 +0200

    Add dummy PATH_MAX on systems without it
    
    Posix only defines that PATH_MAX may is defined through limits.h.
    GNU/Hurd has removed this definition without violating the standards.
    
    Mupen64Plus still relies on it and we work around that problem by
    defining PATH_MAX as 4096 in all places it is needed. This is not 100%
    correct as their are ways to generate longer paths, but mupen64plus must
    be heavily refactored in some places to fix the actual problem.
---
 debian/changelog              |  3 ++-
 debian/patches/path_max.patch | 41 +++++++++++++++++++++++++++++++++++++++++
 debian/patches/series         |  1 +
 3 files changed, 44 insertions(+), 1 deletion(-)

diff --git a/debian/changelog b/debian/changelog
index 1f70037..3d2e24b 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -18,7 +18,8 @@ mupen64plus-video-glide64 (1.99.4~hg20100511-1) UNRELEASED; urgency=low
       system-zlib.patch, version-string.patch, xdg-basedir.patch,
       rice_fog.patch, ftbfs-gvariant-type-conflicts.patch,
       dont-install-unneeded.patch, rice-ati-symbols.patch, link_gdk.patch
-    - Rebase default-optimisations.patch against 1.99.4~hg20100511
+    - Rebase default-optimisations.patch and path_max.patch against
+      1.99.4~hg20100511
     - Add hurd_os.patch, Add GNU/Hurd as operating system with "linux" userland
   * Convert to 3.0 (quilt) source format
   * debian/control:
diff --git a/debian/patches/path_max.patch b/debian/patches/path_max.patch
new file mode 100644
index 0000000..e3184b0
--- /dev/null
+++ b/debian/patches/path_max.patch
@@ -0,0 +1,41 @@
+Description: Add dummy PATH_MAX on systems without it
+ Posix only defines that PATH_MAX may is defined through limits.h. GNU/Hurd has
+ removed this definition without violating the standards.
+ .
+ Mupen64Plus still relies on it and we work around that problem by defining
+ PATH_MAX as 4096 in all places it is needed. This is not 100% correct as their
+ are ways to generate longer paths, but mupen64plus must be heavily refactored
+ in some places to fix the actual problem.
+Bug-Debian: http://bugs.debian.org/588066
+Author: Sven Eckelmann <sven.eckelmann at gmx.de>
+
+---
+diff --git a/src/Ini.cpp b/src/Ini.cpp
+index d27542dc31f5eabed0ec105e3d8104287fd4e777..5c27338cf442e8d7874576efde60af4097aba05e 100644
+--- a/src/Ini.cpp
++++ b/src/Ini.cpp
+@@ -59,6 +59,11 @@
+ #define PATH_MAX _MAX_PATH
+ #endif
+ 
++/* PATH_MAX only may be defined by limits.h */
++#ifndef PATH_MAX
++  #define PATH_MAX 4096
++#endif
++
+ FILE *ini;
+ int sectionstart;
+ int last_line;      // last good line
+diff --git a/src/Ini.h b/src/Ini.h
+index 3ed67cf8815425f8195962d0984de3c1e2818935..0eed64a2ab082e808a054129186d049ec43a9389 100644
+--- a/src/Ini.h
++++ b/src/Ini.h
+@@ -34,8 +34,6 @@
+ //
+ //****************************************************************
+ 
+-//nmn: Fix for MAX_PATH
+-#include <limits.h>
+ #include <stdio.h>
+ #include "winlnxdefs.h"
+ 
diff --git a/debian/patches/series b/debian/patches/series
index 16e335d..5fed16e 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,2 +1,3 @@
 default-optimisations.patch
 hurd_os.patch
+path_max.patch

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



More information about the Pkg-games-commits mailing list