about summary refs log tree commit diff
path: root/nixpkgs/pkgs/applications/editors/emacs/at-fdcwd.patch
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/applications/editors/emacs/at-fdcwd.patch')
-rw-r--r--nixpkgs/pkgs/applications/editors/emacs/at-fdcwd.patch15
1 files changed, 15 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/applications/editors/emacs/at-fdcwd.patch b/nixpkgs/pkgs/applications/editors/emacs/at-fdcwd.patch
new file mode 100644
index 000000000000..2d8099b73736
--- /dev/null
+++ b/nixpkgs/pkgs/applications/editors/emacs/at-fdcwd.patch
@@ -0,0 +1,15 @@
+diff --git a/lib/careadlinkat.h b/lib/careadlinkat.h
+index 84ede3e..8e8f42e 100644
+--- a/lib/careadlinkat.h
++++ b/lib/careadlinkat.h
+@@ -23,6 +23,10 @@
+ #include <fcntl.h>
+ #include <unistd.h>
+ 
++#ifndef AT_FDCWD
++#define AT_FDCWD -2
++#endif
++
+ struct allocator;
+ 
+ /* Assuming the current directory is FD, get the symbolic link value