This fixes my compile problem on Solaris. It turns out that mkstemp()
is defined by gcc-2.95 somewhere in its internals, so it *is* available
which is why the configure defines HAVE_MKSTEMP

However, my system header files do not declare mkstemp (and neither do the
gcc headers). That's why this fix is necessary (and I believe it's also
harmless on systems that already declare mkstemp).

                        ---Kayvan
---
Kayvan A. Sylvan                   | Proud husband of      | Father to my kids:
Sylvan Associates, Inc.            | Laura Isabella Sylvan | Katherine Yelena
http://www.successlinks.com/kayvan | Reach your goals now! | Robin Gregory
Index: src/support/tempname.C
===================================================================
RCS file: /usr/local/lyx/cvsroot/lyx-devel/src/support/tempname.C,v
retrieving revision 1.4
diff -u -r1.4 tempname.C
--- src/support/tempname.C      2000/11/15 03:22:08     1.4
+++ src/support/tempname.C      2000/11/15 18:01:40
@@ -12,6 +12,10 @@
 
 extern string system_tempdir;
 
+#ifdef HAVE_MKSTEMP
+extern "C" { int mkstemp(char*); };
+#endif
+
 static inline
 int make_tempfile(char * templ) 
 {

Reply via email to