diff options
| author | Manolis Ragkousis <manolis837@gmail.com> | 2015-06-08 16:04:07 +0300 |
|---|---|---|
| committer | Manolis Ragkousis <manolis837@gmail.com> | 2015-06-08 22:26:28 +0300 |
| commit | 56eba3d1521e38ef21116ac6502e2c4021836b79 (patch) | |
| tree | 718ce61c326a914f0b4359362458c7ffd03c9907 | |
| parent | 8d866b96f75cd6fc8006721fdcb0c2ed7da6c842 (diff) | |
gnu: sed: Set PATH_MAX for Hurd systems.
* gnu/packages/patches/sed-hurd-path-max.patch: New file.
* gnu-system.am (dist_patch_DATA): Add it.
| -rw-r--r-- | gnu-system.am | 1 | ||||
| -rw-r--r-- | gnu/packages/base.scm | 3 | ||||
| -rw-r--r-- | gnu/packages/patches/sed-hurd-path-max.patch | 34 |
3 files changed, 37 insertions, 1 deletions
diff --git a/gnu-system.am b/gnu-system.am index 6b2b1c7bf38..d4631d6c9ed 100644 --- a/gnu-system.am +++ b/gnu-system.am | |||
| @@ -534,6 +534,7 @@ dist_patch_DATA = \ | |||
| 534 | gnu/packages/patches/ratpoison-shell.patch \ | 534 | gnu/packages/patches/ratpoison-shell.patch \ |
| 535 | gnu/packages/patches/readline-link-ncurses.patch \ | 535 | gnu/packages/patches/readline-link-ncurses.patch \ |
| 536 | gnu/packages/patches/ripperx-libm.patch \ | 536 | gnu/packages/patches/ripperx-libm.patch \ |
| 537 | gnu/packages/patches/sed-hurd-path-max.patch \ | ||
| 537 | gnu/packages/patches/scheme48-tests.patch \ | 538 | gnu/packages/patches/scheme48-tests.patch \ |
| 538 | gnu/packages/patches/scotch-test-threading.patch \ | 539 | gnu/packages/patches/scotch-test-threading.patch \ |
| 539 | gnu/packages/patches/sdl-libx11-1.6.patch \ | 540 | gnu/packages/patches/sdl-libx11-1.6.patch \ |
diff --git a/gnu/packages/base.scm b/gnu/packages/base.scm index e59abd035c2..37ada9c7bfa 100644 --- a/gnu/packages/base.scm +++ b/gnu/packages/base.scm | |||
| @@ -101,7 +101,8 @@ including, for example, recursive directory searching.") | |||
| 101 | ".tar.bz2")) | 101 | ".tar.bz2")) |
| 102 | (sha256 | 102 | (sha256 |
| 103 | (base32 | 103 | (base32 |
| 104 | "1myvrmh99jsvk7v3d7crm0gcrq51hmmm1r2kjyyci152in1x2j7h")))) | 104 | "1myvrmh99jsvk7v3d7crm0gcrq51hmmm1r2kjyyci152in1x2j7h")) |
| 105 | (patches (list (search-patch "sed-hurd-path-max.patch"))))) | ||
| 105 | (build-system gnu-build-system) | 106 | (build-system gnu-build-system) |
| 106 | (synopsis "Stream editor") | 107 | (synopsis "Stream editor") |
| 107 | (arguments | 108 | (arguments |
diff --git a/gnu/packages/patches/sed-hurd-path-max.patch b/gnu/packages/patches/sed-hurd-path-max.patch new file mode 100644 index 00000000000..5226cba4cb8 --- /dev/null +++ b/gnu/packages/patches/sed-hurd-path-max.patch | |||
| @@ -0,0 +1,34 @@ | |||
| 1 | 7bb8d35d0330161a5af5341471d0c183a067e8c2 | ||
| 2 | Author: Jose E. Marchesi <jemarch@gnu.org> | ||
| 3 | Date: Sun Oct 6 14:43:38 2013 +0200 | ||
| 4 | |||
| 5 | Set PATH_MAX to some constant in case it is not defined in system | ||
| 6 | headers. | ||
| 7 | |||
| 8 | 2013-10-06 Jose E. Marchesi <jemarch@gnu.org> | ||
| 9 | |||
| 10 | * basicdefs.h (PATH_MAX): Defined to some constant in case it is | ||
| 11 | not defined by system headers. | ||
| 12 | * sed/utils.c: Do not include pathmax.h anymore. | ||
| 13 | * bootstrap.conf (gnulib_modules): Do not use the gnulib module | ||
| 14 | pathmax. | ||
| 15 | |||
| 16 | diff --git a/basicdefs.h b/basicdefs.h | ||
| 17 | index 0d28a97..09f5beb 100644 | ||
| 18 | --- a/basicdefs.h | ||
| 19 | +++ b/basicdefs.h | ||
| 20 | @@ -40,6 +41,13 @@ typedef unsigned long countT; | ||
| 21 | #define obstack_chunk_alloc ck_malloc | ||
| 22 | #define obstack_chunk_free free | ||
| 23 | |||
| 24 | +/* MAX_PATH is not defined in some platforms, most notably GNU/Hurd. | ||
| 25 | + In that case we define it here to some constant. Note however that | ||
| 26 | + this relies in the fact that sed does reallocation if a buffer | ||
| 27 | + needs to be larger than PATH_MAX. */ | ||
| 28 | +#ifndef PATH_MAX | ||
| 29 | +# define PATH_MAX 200 | ||
| 30 | +#endif | ||
| 31 | |||
| 32 | /* handle misdesigned <ctype.h> macros (snarfed from lib/regex.c) */ | ||
| 33 | /* Jim Meyering writes: | ||
| 34 | |||
