gthread-2.0 in Linux link items
Hi, all,
I seem to remember us having gthread-2.0 on our link line previously. I am finally getting the trace function to run on a background thread. Does configure.in need to be adjusted? Or just a Makefile.am?
The --cflags part is redundant, and is not needed: %>pkg-config --cflags gthread-2.0 -pthread -I/usr/local/include/glib-2.0 -I/usr/local/lib/glib-2.0/include
But this needs to be added. Didn't we have this once? %>pkg-config --libs gthread-2.0 -pthread -L/usr/local/lib -lgthread-2.0 -lglib-2.0
I need it for the following lines in trace.cpp:
#if HAVE_THREADS //Ensure that thread support is running if (!Glib::thread_supported()) Glib::thread_init();
//Create our thread and run it Glib::Thread::create( sigc::mem_fun(*this, &Trace::convertImageToPathThread), false); #else convertImageToPathThread(); #endif
If anyone could adjust this, I would appreciate it.
Bob
On Fri, 24 Sep 2004, Bob Jamison wrote:
Hi, all,
I seem to remember us having gthread-2.0 on our link line previously. I am finally getting the trace function to run on a background thread. Does configure.in need to be adjusted? Or just a Makefile.am?
configure.in, with the PKG_CONFIG macro or whatever -- but please don't do this right now.
I need it for the following lines in trace.cpp:
#if HAVE_THREADS //Ensure that thread support is running if (!Glib::thread_supported()) Glib::thread_init();
//Create our thread and run it Glib::Thread::create( sigc::mem_fun(*this, &Trace::convertImageToPathThread), false);
#else convertImageToPathThread(); #endif
Please find another way to do this without using threads. Our codebase isn't remotely thread-safe right now.
One simple approach would be to introduce a few points in the image conversion routines that periodically called out to a function which would run the event loop once.
-mental
participants (2)
-
Bob Jamison
-
MenTaLguY