Re: Application path
- From: Jaroslav Šmíd <jardasmid gmail com>
- To: John Emmas <johne53 tiscali co uk>
- Cc: gtk-app-devel-list <gtk-app-devel-list gnome org>
- Subject: Re: Application path
- Date: Tue, 18 Jan 2011 03:07:15 +0100
The only way to get this on linux is to read symlink /proc/self/exe
(readlink()) On Windows, you can use GetModuleName(NULL, xx, yy). Don't
know if glib has anything for this.
On 01/12/2011 02:13 PM, John Emmas wrote:
Browsing through glib/gutils.c this morning, I noticed a function called g_get_application_name() which will return the application's name (e.g.
"my_app" on Linux, or "my_app.exe" on Windows). Is there any similar function that would tell me the full path to the
application - e.g. "/usr/bin/my_app/my_app" under Linux, or "C:\Program Files\my_app\my_app.exe" under Windows?
John
_______________________________________________
gtk-app-devel-list mailing list
gtk-app-devel-list gnome org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]