FLTK logo

Re: [fltk.coredev] fltk-1.4 fluid build broken on 32-bit mingw

FLTK matrix user chat room
(using Element browser app)   FLTK gitter user chat room   GitHub FLTK Project   FLTK News RSS Feed  
  FLTK Apps      FLTK Library      Forums      Links     Login 
 All Forums  |  Back to fltk.coredev  ]
 
Previous Message ]New Message | Reply ]Next Message ]

Re: fltk-1.4 fluid build broken on 32-bit mingw Albrecht Schlosser Sep 28, 2021  
 
On 9/28/21 9:43 AM imacarthur wrote:
OK, tested with the patch (copied below) and that seems fine - built and worked OK with both the 32 and 64-bit mingw targets.

Thanks for testing.

Went with "get_fileno" for the "replacement" name, as I felt that described what it was doing and would not collide with the macro #define.

OK.

I also had to remove the "::" from line 1360 to get this to compile.

As expected.

I committed your patch in b6a69db9a67c9353343d16814cbf35c5e3f36946. Thanks.


diff --git a/fluid/fluid.cxx b/fluid/fluid.cxx
index 0c1647b48..b5e01f316 100644
--- a/fluid/fluid.cxx
+++ b/fluid/fluid.cxx
@@ -1353,11 +1353,11 @@ public:
   // returns fileno(FILE*):
   // (file must be open, i.e. _fpt must be non-null)
   // *FIXME* we should find a better solution for the 'fileno' issue
-  int fileno() const {
+  int get_fileno() const {
 #ifdef _MSC_VER
     return _fileno(_fpt); // suppress MSVC warning
 #else
-    return ::fileno(_fpt);
+    return fileno(_fpt);
 #endif
   } // non null if file is open
 
@@ -1501,7 +1501,7 @@ shell_pipe_cb(FL_SOCKET, void*) {
     shell_run_terminal->append(line);
   } else {
     // End of file; tell the parent...
-    Fl::remove_fd(s_proc.fileno());
+    Fl::remove_fd(s_proc.get_fileno());
     s_proc.close();
     shell_run_terminal->append("... END SHELL COMMAND ...\n");
   }
@@ -1537,7 +1537,7 @@ do_shell_command(Fl_Return_Button*, void*) {
   }
   shell_run_window->show();
 
-  Fl::add_fd(s_proc.fileno(), shell_pipe_cb);
+  Fl::add_fd(s_proc.get_fileno(), shell_pipe_cb);
 
   while (s_proc.desc()) Fl::wait();
 

--
You received this message because you are subscribed to the Google Groups "fltk.coredev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to fltkcoredev+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/fltkcoredev/c4f85e81-096c-b19c-f511-393dc31471e6%40online.de.
Direct Link to Message ]
 
     
Previous Message ]New Message | Reply ]Next Message ]
 
 

Comments are owned by the poster. All other content is copyright 1998-2024 by Bill Spitzak and others. This project is hosted by The FLTK Team. Please report site problems to 'erco@seriss.com'.