Re: Hildonized Blackjack Proof of Concept



Hi;

Le lundi 25 août 2008 à 00:26 -0700, James Liggett a écrit : 
> On Sun, 2008-08-24 at 14:53 +0200, Christian Persch wrote:
> >  AC_ARG_ENABLE([scalable],
> >    [AS_HELP_STRING([--enable-scalable],[Enable scalable graphics])],
> > -  [],[case "$with_platform" in
> > -        gnome|gtk-only) enable_scalable=yes ;;
> > -        hildon) enable_scalable=no ;;
> > -      esac])
> > +  [],[enable_scalable=yes])
> > 
> > This is wrong. If you want scalable on hildon, just pass
> > --enable-scalable, don't make everyone build with that (I don't want it
> > for aisleriot). need_rsvg might be set wrongly for bj, it seems it has
> > svg's that don't have png variants. You either should correct that, or
> > optionally convert these to pngs in the packaging and use that... 
> Really? I tried passing --enable-scalable to configure and it didn't
> work; in any case neither the chips nor the card outlines would render.
> Besides, if I read this correctly it seems to say that RSVG should be
> disabled for all hildon builds, even if --enable-scalable is passed to
> configure. That seems to be commensurate with my experience described
> above, so what do I do here? Should I just set enable_scalable to yes if
> blackjack is being built on any platform? 

I guess you need to remove bj from here:
  case $game in
    aisleriot|blackjack) ;;
    *) need_rsvg=yes ;;
  esac

so it sets need_rsvg=yes. And then below

  [],[case "$with_platform" in
        gnome|gtk-only) enable_scalable=yes ;;
        hildon) enable_scalable=no ;;
      esac])

replace the hildon case with enable_scalable=$need_rsvg ? 

However, based on my experience with aisleriot, I think you will need to
change the bj code so that it doesn't depend on scalable graphics. I
tried scalable with aisleriot and it was way too slow to be usable on my
N800. That's why I reengineered the aisleriot and libgames-support code
to allow using prebuilt cards in PNG format. (You can use the
gnome-games-render-cards programme in libgames-support to build such a
card cache; however that only works with rsvg enabled so you need to
build the cache on your desktop and just install it on the device.) (And
even with the PNGs it was still too slow, so I also had to cache the
cards as GdkPixmaps instead of the GdkPixbufs.) You can use that for the
cards in bj, and you'll probably need to make something similar for the
other svg images that bj uses. 

> > > I'm also working on making an installable package for it, but being a
> > > Debian packaging newbie it seems I've still got a ways to go before I
> > > figure it out... ;) 
> > 
> > You might want to try the packaging from my aisleriot packages (from
> > maemo extras repo, only for os2007 though). It needs lots of improvement
> > work though to be a 'good' packaging...
> Actually, my package is based on your work here. With some minor
> modifications to to rules file I was able to build AisleRiot for Diablo
> and get it to install on my tablet. And I will say it works very well.
> The problem I'm experiencing is that the resultant bj package insists on
> having a prerm script that tries to remove gconf schemas that weren't
> installed per arguments to configure, and this makes the package
> unremovable unless you manually delete the script
> from /var/lib/dpkg/info.
> 
> I noticed that your package has no such script, but I can't quite figure
> out where I'm going wrong with it. The offending script has a note at
> the top that says it was automatically added by dh_gconf. But I just
> realized that out of stupidity I deleted the debian folder so that I
> could start over again, otherwise I'd show it to you to see if you could
> spot anything. :( I'll try it again sometime in the next day or so. 

No idea, sorry. I'm not an experienced debian packager either, I just
got something semi-working by trial-and-error. That's why I said that
the packaging needs lots of work. It also doesn't comply with the maemo
packaging guidelines, which is among the reasons why I haven't made an
aisleriot package for OS2008 yet.

> > > I did get a package built, but it doesn't install if
> > > you have AisleRiot installed on your tablet, because of the way
> > > gnome-games deals with po files. The problem is that we assume that
> > > users will always install all of the games as one package, so we just
> > > have one big set of po files, which will be provided by the AisleRiot
> > > package if you install it. 
> > 
> > Maybe split that into a gnome-games-i18n package that both the aisleriot
> > and bj debs then depend on?
> That's fine with me.

Or you could change the GETTEXT_DOMAIN variable with a debian packaging
patch to configure so aisleriot and bj uses different domains and are
thus parallel-installable. Would reduce the size of the gettext files in
the package, saving space if you only install one of the games instead
of both. So that might be better even.

Regards,
	Christian



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