Jonathan Wilson | 7 Feb 2012 17:22
Picon

Resources for learning Qt on Mameo5 Fremantle

I am looking for resources related to learning Qt on Maemo5 Fremantle.
More specifically I am trying to understand the workings of this app: (and 
add some new features to it such as a one-step undo for when you press the 
wrong block by mistake)
http://maemo.org/packages/view/skidstone/

I have a copy of a book titled "C++ GUI Programming with Qt 4 Second 
Edition", will the information in that book be of any use in understanding 
whatever version of QT Maemo5 has?
Where can I find tutorials and things dealing with mobile-specific stuff 
like touch events?
Paul Hartman | 7 Feb 2012 17:52
Picon

Re: Resources for learning Qt on Mameo5 Fremantle

On Tue, Feb 7, 2012 at 10:22 AM, Jonathan Wilson <jfwfreo <at> tpgi.com.au> wrote:
> I am looking for resources related to learning Qt on Maemo5 Fremantle.
> More specifically I am trying to understand the workings of this app: (and
> add some new features to it such as a one-step undo for when you press the
> wrong block by mistake)
> http://maemo.org/packages/view/skidstone/
>
> I have a copy of a book titled "C++ GUI Programming with Qt 4 Second
> Edition", will the information in that book be of any use in understanding
> whatever version of QT Maemo5 has?
> Where can I find tutorials and things dealing with mobile-specific stuff
> like touch events?

That book is fine, but is focused on desktop. There are a couple of
books out there focused on Qt and mobile apps. "Beginning Nokia Apps
Development" is about Qt on Symbian and MeeGo and can be had for under
$10 USD.

Also of course the great documentation on the Qt website itself cannot
be overlooked. :)
Jonathan Wilson | 8 Feb 2012 01:41
Picon

Re: Resources for learning Qt on Mameo5 Fremantle

 > That book is fine, but is focused on desktop. There are a couple of
 > books out there focused on Qt and mobile apps. "Beginning Nokia Apps
 > Development" is about Qt on Symbian and MeeGo and can be had for under
 > $10 USD.
Thanks, I will see if I can track down that book (ordering it from Amazon 
is an option but the shipping to Australia is a killer :)
Johan Helsingius | 8 Feb 2012 08:41

Re: Resources for learning Qt on Mameo5 Fremantle

> Thanks, I will see if I can track down that book (ordering it from Amazon is an
> option but the shipping to Australia is a killer :)

It seems to be available as an ebook.

http://www.wowebook.me/book/beginning-nokia-apps-development/

	Julf
John Pietrzak | 8 Feb 2012 19:10
Picon

Subtle difference in behavior of installation packages

Hi folks,

I've been working on a small Maemo app, and have reached the point where 
I've pushed it up to Extras-Devel.  Almost everything works perfectly, 
except for one item: I've created a sudoers file for the app, in order 
to allow it to call "modprobe" to load a kernel module.  (This is the 
"lirc_rx51" module, needed for access to the IR hardware.)  This file 
needs to go into the /etc/sudoers.d directory.

I can install and uninstall the file just fine using the debian package 
I've constructed locally.  When installing the app from the Extras-Devel 
repository, however, the application manager can place the file into 
/etc/sudoers.d, but seems unable to remove it when uninstalling.

I'm using the Qt SDK, and have recently upgraded to Qt Creator 2.4.1, so 
maybe the latest Qt software creates debian packages differently than 
the Extras system does...

So, I guess these are my questions:

1) Do I need to do something special to install/uninstall files to the 
/etc directory in Maemo?

2) Should I even be using /etc/sudoers.d to let my app access modprobe?  
What is the preferred way for an app to make requests of the kernel?

Thanks!

--John
(Continue reading)

Pali Rohár | 8 Feb 2012 19:21
Picon

Re: Subtle difference in behavior of installation packages

Hi,

On Wednesday 08 February 2012 13:10:25 John Pietrzak wrote:
> Hi folks,
> 
> I've been working on a small Maemo app, and have reached the point where
> I've pushed it up to Extras-Devel.  Almost everything works perfectly,
> except for one item: I've created a sudoers file for the app, in order
> to allow it to call "modprobe" to load a kernel module.  (This is the
> "lirc_rx51" module, needed for access to the IR hardware.)  This file
> needs to go into the /etc/sudoers.d directory.
> 
> I can install and uninstall the file just fine using the debian package
> I've constructed locally.  When installing the app from the Extras-Devel
> repository, however, the application manager can place the file into
> /etc/sudoers.d, but seems unable to remove it when uninstalling.

Try to run apt-get remove <package> in xterm. This is what application manager 
doing... Also see error in application manager log.

> 
> I'm using the Qt SDK, and have recently upgraded to Qt Creator 2.4.1, so
> maybe the latest Qt software creates debian packages differently than
> the Extras system does...
> 
> So, I guess these are my questions:
> 
> 1) Do I need to do something special to install/uninstall files to the
> /etc directory in Maemo?

(Continue reading)

gregor herrmann | 8 Feb 2012 21:04
X-Face
Picon
Favicon

Re: Subtle difference in behavior of installation packages

On Wed, 08 Feb 2012 19:21:16 +0100, Pali Rohár wrote:

> > I can install and uninstall the file just fine using the debian package
> > I've constructed locally.  When installing the app from the Extras-Devel
> > repository, however, the application manager can place the file into
> > /etc/sudoers.d, but seems unable to remove it when uninstalling.
> Try to run apt-get remove <package> in xterm. This is what application manager 
> doing... Also see error in application manager log.

apt-get remove without --purge won't remove conffiles, which would
explain why /etc/sudoers.d/foo is still there ...

And that's on purpose at least in Debian. If HAM can't be told to
purge a package there's not much that can be done (short of using
brute force in the postrm maintainer script. Ehh, this sounds ugly.).

Cheers,
gregor

--

-- 
 .''`.  Homepage: http://info.comodo.priv.at/ - OpenPGP key 0xBB3A68018649AA06
 : :' : Debian GNU/Linux user, admin, and developer  -  http://www.debian.org/
 `. `'  Member of VIBE!AT & SPI, fellow of the Free Software Foundation Europe
   `-   NP: Carole King: Will You Still Love Me Tomorrow
_______________________________________________
maemo-developers mailing list
maemo-developers <at> maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers
(Continue reading)

Pali Rohár | 8 Feb 2012 21:15
Picon

Re: Subtle difference in behavior of installation packages

On Wednesday 08 February 2012 21:04:26 gregor herrmann wrote:
> On Wed, 08 Feb 2012 19:21:16 +0100, Pali Rohár wrote:
> > > I can install and uninstall the file just fine using the debian package
> > > I've constructed locally.  When installing the app from the Extras-Devel
> > > repository, however, the application manager can place the file into
> > > /etc/sudoers.d, but seems unable to remove it when uninstalling.
> > 
> > Try to run apt-get remove <package> in xterm. This is what application
> > manager doing... Also see error in application manager log.
> 
> apt-get remove without --purge won't remove conffiles, which would
> explain why /etc/sudoers.d/foo is still there ...
> 
> And that's on purpose at least in Debian. If HAM can't be told to
> purge a package there's not much that can be done (short of using
> brute force in the postrm maintainer script. Ehh, this sounds ugly.).
> 
> 
> Cheers,
> gregor

You can create sudoers.d file in postinst file and remove it in postrm.
echo "..." > /etc/sudoers.d/...

Or you can force debhelper to not add that sudoers file to conffiles.

--

-- 
Pali Rohár
pali.rohar <at> gmail.com
(Continue reading)

John Pietrzak | 9 Feb 2012 00:38
Picon

Re: Subtle difference in behavior of installation packages

On 2/8/12 3:15 PM, Pali Rohár wrote:
> On Wednesday 08 February 2012 21:04:26 gregor herrmann wrote:
>
>> apt-get remove without --purge won't remove conffiles, which would
>> explain why /etc/sudoers.d/foo is still there ...
>>
>> And that's on purpose at least in Debian. If HAM can't be told to
>> purge a package there's not much that can be done (short of using
>> brute force in the postrm maintainer script. Ehh, this sounds ugly.).
>>

Yes, I tried the brute-force approach, and it was ugly.  Ended up with 
the package manager thinking the sudoers file still existed. :(

BTW, what is Debian's purpose on keeping conffiles around?  Is there 
value in having config info for nonexisting packages?  (Should I not be 
worried about leaving sudoers files in the sudoers.d directory?)

> You can create sudoers.d file in postinst file and remove it in postrm.
> echo "...">  /etc/sudoers.d/...

Thanks, tried that out, and it works fine!  I guess I'll just go with 
that for now...

Thanks,

--John
gregor herrmann | 10 Feb 2012 00:30
X-Face
Picon
Favicon

Re: Subtle difference in behavior of installation packages

On Wed, 08 Feb 2012 18:38:53 -0500, John Pietrzak wrote:

> >>apt-get remove without --purge won't remove conffiles, which would
> >>explain why /etc/sudoers.d/foo is still there ...
> >>And that's on purpose at least in Debian.
> BTW, what is Debian's purpose on keeping conffiles around?  Is there
> value in having config info for nonexisting packages?  (Should I not
> be worried about leaving sudoers files in the sudoers.d directory?)

A package might be removed only temporarily or in error, and be
reinstalled again later. In that case the admin will be happy to find
their carefully tweaked config files instead of having to re-create
them from scratch (or grab them from a backup or an older git
revision).
And in general conffiles lying around in /etc/ don't hurt.

Cheers,
gregor

--

-- 
 .''`.  Homepage: http://info.comodo.priv.at/ - OpenPGP key 0xBB3A68018649AA06
 : :' : Debian GNU/Linux user, admin, and developer  -  http://www.debian.org/
 `. `'  Member of VIBE!AT & SPI, fellow of the Free Software Foundation Europe
   `-   NP: Bruce Springsteen: The Promised Land
_______________________________________________
maemo-developers mailing list
maemo-developers <at> maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers
(Continue reading)


Gmane