]> git.donarmstrong.com Git - lilypond.git/commitdiff
move hurd support to a quilt patch
authorDon Armstrong <don@donarmstrong.com>
Tue, 31 Dec 2013 21:46:29 +0000 (13:46 -0800)
committerDon Armstrong <don@donarmstrong.com>
Tue, 31 Dec 2013 21:46:29 +0000 (13:46 -0800)
debian/patches/hurd_file_name_support [new file with mode: 0644]
flower/file-name.cc

diff --git a/debian/patches/hurd_file_name_support b/debian/patches/hurd_file_name_support
new file mode 100644 (file)
index 0000000..8c782a5
--- /dev/null
@@ -0,0 +1,16 @@
+--- lilypond-2.18.0.orig/flower/file-name.cc
++++ lilypond-2.18.0/flower/file-name.cc
+@@ -96,9 +96,13 @@
+ string
+ get_working_directory ()
+ {
++#ifdef _GNU_SOURCE_
++  return string (get_current_dir_name());
++#else
+   char cwd[PATH_MAX];
+   // getcwd returns NULL upon a failure, contents of cwd would be undefined!
+   return string (getcwd (cwd, PATH_MAX));
++#endif
+ }
+ /* Join components to full file_name. */
index 0ff89b8d874fb32f6f189470eb3c596c6cfd22f8..1746c2c28d84adc5cbe8cd19f5e8d431dec10383 100644 (file)
@@ -96,13 +96,9 @@ dir_name (const string &file_name)
 string
 get_working_directory ()
 {
-#ifdef _GNU_SOURCE_
-  return string (get_current_dir_name());
-#else
   char cwd[PATH_MAX];
   // getcwd returns NULL upon a failure, contents of cwd would be undefined!
   return string (getcwd (cwd, PATH_MAX));
-#endif
 }
 
 /* Join components to full file_name. */