summaryrefslogtreecommitdiff
path: root/src/Fl_PostScript.cxx
diff options
context:
space:
mode:
authorMatthias Melcher <fltk@matthiasm.com>2016-01-04 23:31:55 +0000
committerMatthias Melcher <fltk@matthiasm.com>2016-01-04 23:31:55 +0000
commit19c8c9b9180e599a6b5bd3933e4e008632f8ce5a (patch)
tree4782de4354d7ab6fa85b1a9eea1680c2dbb41bed /src/Fl_PostScript.cxx
parent64aa17ca09cda7696c4d404884ee7e3f4540c2d1 (diff)
Compiling in OS X from the command line goes pretty far for __APPLE__ undefined and FL_PORTING defined.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@10995 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'src/Fl_PostScript.cxx')
-rw-r--r--src/Fl_PostScript.cxx9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/Fl_PostScript.cxx b/src/Fl_PostScript.cxx
index d2264a8c7..9ad6b2173 100644
--- a/src/Fl_PostScript.cxx
+++ b/src/Fl_PostScript.cxx
@@ -155,6 +155,14 @@ Fl_PostScript_File_Device::~Fl_PostScript_File_Device() {
*/
int Fl_PostScript_Graphics_Driver::clocale_printf(const char *format, ...)
{
+#ifdef FL_PORTING
+# pragma message "FL_PORTING: must define LC_NUMERIC"
+ va_list args;
+ va_start(args, format);
+ int retval = vfprintf(output, format, args);
+ va_end(args);
+ return retval;
+#else
char *saved_locale = setlocale(LC_NUMERIC, NULL);
setlocale(LC_NUMERIC, "C");
va_list args;
@@ -163,6 +171,7 @@ int Fl_PostScript_Graphics_Driver::clocale_printf(const char *format, ...)
va_end(args);
setlocale(LC_NUMERIC, saved_locale);
return retval;
+#endif
}
#ifndef FL_DOXYGEN