- Add patch to support guile-2.0
- Add guile-2.0 and font-texgyre to Build-Depends
- Enable guile-2.0 in debian/rules
+ * Fix patch for FTBFS on hurd. Thanks to Petter Reinholdtsen for
+ the bug report and patch. (Closes: #761036)
-- Don Armstrong <don@debian.org> Mon, 01 Dec 2014 15:01:50 -0800
Author: Don Armstrong <don@debian.org>
--- a/flower/file-name.cc
+++ b/flower/file-name.cc
-@@ -77,9 +77,13 @@
+@@ -77,9 +77,16 @@
string
get_working_directory ()
{
-+#ifdef _GNU_SOURCE_
-+ return string (get_current_dir_name());
++#ifdef _GNU_SOURCE
++ char *cwd = get_current_dir_name();
++ string scwd(cwd);
++ free(cwd);
++ return scwd;
+#else
char cwd[PATH_MAX];
// getcwd returns NULL upon a failure, contents of cwd would be undefined!
}
/* Join components to full file_name. */
+--- a/flower/test-file-path.cc
++++ b/flower/test-file-path.cc
+@@ -6,12 +6,26 @@
+ #include "yaffut.hh"
+ #include "config.hh"
+
++string
++get_working_directory ()
++{
++#ifdef _GNU_SOURCE
++ char *cwd = get_current_dir_name();
++ string scwd(cwd);
++ free(cwd);
++ return scwd;
++#else
++ char cwd[PATH_MAX];
++ // getcwd returns NULL upon a failure, contents of cwd would be undefined!
++ return string (getcwd (cwd, PATH_MAX));
++#endif
++}
++
+ TEST (File_path, Find)
+ {
+ char const *extensions[] = {"ly", "", 0};
+ string file = "init";
+- char cwd[PATH_MAX];
+- if (!getcwd (cwd, PATH_MAX))
++ if (get_working_directory().empty())
+ {
+ cerr << "Could not get current work directory\n";
+ exit (1);