Re: [gnome-love] At last... I made it...
- From: Melinda <melinda_sayang hotpop com>
- To: Murray Cumming <murrayc murrayc com>
- Cc: Sean Middleditch <elanthis awesomeplay com>, gnome-love gnome org
- Subject: Re: [gnome-love] At last... I made it...
- Date: Wed, 16 Jun 2004 22:14:29 +0700
I don't know what Makefile.old is, but Makefile.in is a generated file.
You should be using autoconf and automake, so you should only edit
Makefile.am. That is what Sean is suggesting.
I see hat you are using C++. Therefore prefixsuffix is a nice simple
example of this for you:
http://prefixsuffix.sourceforge.net/
Ok, I looked the example. The Makefile.am is like this:
SUBDIRS = src po help docs
# Desktop entry
desktopdir = $(datadir)/gnome/apps/Games
desktop_in_files = prefixsuffix.desktop.in
desktop_DATA = $(desktop_in_files:.desktop.in=.desktop)
@INTLTOOL_DESKTOP_RULE@
# Icon
icondir = $(datadir)/pixmaps
icon_DATA = prefixsuffix.png
EXTRA_DIST = $(desktop_in_files) $(desktop_DATA)
$(icon_DATA)
This example solve my icon and desktop file problem. So my problem
become one now. What I don't understand is how do you tell the binary to
locate its glade file. So I am still struggling with this code:
try {
string blabla = DATADIR + "/wallpapoz.glade";
refXml = Gnome::Glade::Xml::create( blabla );
}
How do you define the DATADIR variable? When user type ./configure
--prefix=/usr, the DATADIR variable will be /usr/share/wallpapoz. When
user type ./configure, the DATADIR variable will be
/usr/local/share/wallpapoz. How do you do that? The prefixsuffix example
don't tell me how to do that.
My Makefile.am is like this:
bin_PROGRAMS = wallpapoz daemon_wallpapoz
wallpapoz_SOURCES = wallpapoz.cpp wallpapoz.h main.cpp Process.cpp
Process.h
daemon_wallpapoz_SOURCES = daemon_wallpapoz.cpp Process.cpp Process.h
glade_DATA = wallpapoz.glade
gladedir = ${datadir}/@PACKAGE_TARNAME@/
INCLUDES = $(DEPS_CFLAGS)
LIBS = $(DEPS_LIBS)
# desktop entry
desktopdir = /usr/share/applications
desktop_DATA = wallpapoz.desktop
# icon
icondir = /usr/share/pixmaps
icon_DATA = wallpapoz.png
Thank you.....
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]