summaryrefslogtreecommitdiff
path: root/FL/filename.H
diff options
context:
space:
mode:
authorMatthias Melcher <fltk@matthiasm.com>2010-04-14 20:17:44 +0000
committerMatthias Melcher <fltk@matthiasm.com>2010-04-14 20:17:44 +0000
commit30d00ceb075adaa945a5176a3272982a856f0a9b (patch)
tree8eb8bcd198f8166516bb36b81c7ccf2a9c2091ff /FL/filename.H
parent79b2c201a0d36651e97140ddff215a3b1bbde93e (diff)
Fludi IDE: now supporting header files for OS X. If those are included for a library, the resulting framework will receive a copy of the headers, allowing Xcode to simply include the file into any new project. frameworks must be installed in /Library?Frameworks to be found automatically. A little more fixing is required.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@7504 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'FL/filename.H')
-rw-r--r--FL/filename.H8
1 files changed, 8 insertions, 0 deletions
diff --git a/FL/filename.H b/FL/filename.H
index 06041155a..29d0bcf91 100644
--- a/FL/filename.H
+++ b/FL/filename.H
@@ -25,6 +25,12 @@
* http://www.fltk.org/str.php
*/
+// Xcode on OS X includes files by recursing down into directories.
+// This code catches the cycle and directly includes the required file.
+#ifdef fl_dirent_h_cyclic_include
+# include "/usr/include/dirent.h"
+#endif
+
#ifndef FL_FILENAME_H
# define FL_FILENAME_H
@@ -94,7 +100,9 @@ struct dirent {char d_name[1];};
* It would be best to create a <dirent.h> file that does this...
*/
# include <sys/types.h>
+# define fl_dirent_h_cyclic_include
# include <dirent.h>
+# undef fl_dirent_h_cyclic_include
# endif
# if defined (__cplusplus)