0001-Add-conditional-check-for-__linux__.patch 1.0 KB

1234567891011121314151617181920212223242526272829303132
  1. From 69740cf6fe35413edc4b6adc502ba70ce8de8557 Mon Sep 17 00:00:00 2001
  2. From: =?UTF-8?q?J=C3=B6rg=20Krause?= <joerg.krause@embedded.rocks>
  3. Date: Sun, 19 Jul 2015 08:48:13 +0200
  4. Subject: [PATCH 1/1] Add conditional check for __linux__
  5. MIME-Version: 1.0
  6. Content-Type: text/plain; charset=UTF-8
  7. Content-Transfer-Encoding: 8bit
  8. When building upmpdcli with certain toolchains using the compiler flag
  9. -std=c++0x let gcc not define "linux" or "__linux", but "__linux__".
  10. Signed-off-by: Jörg Krause <joerg.krause@embedded.rocks>
  11. ---
  12. src/closefrom.cpp | 2 +-
  13. 1 file changed, 1 insertion(+), 1 deletion(-)
  14. diff --git a/src/closefrom.cpp b/src/closefrom.cpp
  15. index 4429b20..0cd7957 100644
  16. --- a/src/closefrom.cpp
  17. +++ b/src/closefrom.cpp
  18. @@ -111,7 +111,7 @@ int libclf_closefrom(int fd0)
  19. }
  20. /*************************************************************************/
  21. -#elif (defined(linux) || defined(__linux))
  22. +#elif (defined(linux) || defined(__linux) || defined(__linux__))
  23. /* Use /proc/self/fd directory */
  24. #include <sys/types.h>
  25. --
  26. 2.4.6