[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: gtk frontend for cdebconf, ready for commit



tor 2002-09-05 klockan 02.31 skrev Michael Cardenas:
> > Attached is a patch for cdebconf that adds a gtk2.0 frontend. It is
> > relatively complete. The select and text handlers are not finished,
> > but there is enough to be tested here.
> 
> I've attached a cleaner, more complete patch to this email. Now all of
> the question handlers are done. 

I couldn't get it to compile, until I changed this line in Makefile:

--- Makefile.orig       2002-09-05 10:03:59.000000000 +0200
+++ Makefile    2002-09-05 10:03:30.000000000 +0200
@@ -1,7 +1,7 @@
 MODULE=gtk
 SOBJ=gtk.so
 OBJS=gtk.opic
-INCLUDES=`pkg-config --cflags gtk+-2.0`
+MODCFLAGS=`pkg-config --cflags gtk+-2.0`

 MODLDFLAGS=`pkg-config --libs gtk+-2.0`


> > I was unable to figure out the
> > cdebconf tests dir, so if someone can explain to me how they work, I
> > can do much better testing on it myself. For now, I've just been
> > making little "hello world" type apps to test the functionality of
> > each handler. The multiselect, password, string and note handlers are

With the help of Mithrandir, I've figured it out now :)

$ ./configure --with-frontend=gtk --with-conffile=./cdebconf.conf

And then you'll have to go to src/test, I copied ../cdebconf.conf-dist
to ./cdebconf.conf and edited so:
--- ../cdebconf.conf-dist       2002-09-05 10:43:21.000000000 +0200
+++ cdebconf.conf       2002-09-05 10:38:40.000000000 +0200
@@ -4,8 +4,8 @@

 global {
   module_path {
-    frontend "/usr/lib/cdebconf/frontend";
-    database "/usr/lib/cdebconf/db";
+    frontend "../modules/frontend";
+    database "../modules/db";
   };

   default {
@@ -17,21 +17,21 @@

 frontend {
   instance "default_fe" {
-    driver "text";
+    driver "gtk";
   };
 };

 template {
   instance "templatedb" {
     driver "rfc822db";
-    path "/var/lib/cdebconf/templates.dat";
+    path "./templates.dat";
   };
 };

 config {
   instance "configdb" {
     driver "rfc822db";
-    path "/var/lib/cdebconf/questions.dat";
+    path "./questions.dat";
   };
 };

You'll also have to touch templates.dat, or it'll complain about it not
existing. At this point you should be able to do:

$ ../debconf-loadtemplate foo test.templates
$ ../debconf test.config

and enjoy ;)

> I still haven't been able to test this, so if someone can give me some
> pointers, that would be great. I know I should be able to run cdebconf
> with the --frontend parameter, but I don't know what to run it on. 

I didn't get that to work!

$ ../debconf --frontend=gtk test.config
execv: No such file or directory
confmodule.c:203 (confmodule_run): Cannot execute client config script
$ ../debconf -fgtk test.config
../debconf: invalid option -- g
../debconf: invalid option -- t
../debconf: invalid option -- k
execv: No such file or directory
confmodule.c:203 (confmodule_run): Cannot execute client config script
$ ../debconf -f gtk test.config
execv: No such file or directory
confmodule.c:203 (confmodule_run): Cannot execute client config script

> It still needs to be made prettier. 

I noticed that window titles aren't set. It might be nice to set them to
the first description line? Also, windows aren't closed after the
question is answered, is this by design or by accident?

Also, after I entered a password, it segfaulted. :)

> > Another issue at hand, now that this is almost ready, is the question
> > of udebs for X and gtk. Should I start on those? Or can we safely
> > assume that the X install medium is going to have lots of space, and
> > thus use regular debs. I don't mind working on the udebs, I just want
> > to know what you guys think. 
> > 
> 
> I still need an answer to this. 

Can't help you there. :/


Regards,
Martin

Attachment: signature.asc
Description: Detta =?ISO-8859-1?Q?=E4r?= en digitalt signerad meddelandedel


Reply to: