Description of problem: Using this string in a shell script: RETURN=$(/usr/sbin/chroot $SYSDIR /usr/bin/zenity --title "Firewall Configuration" --list --radiolist TRUE Enabled FALSE Disabled --column "Item" --column "Option") Zenity returns saying "This option is not available. See --help for all possible options" Version-Release number of selected component (if applicable): zenity-2.18.0-1.fc7 How reproducible: Use the Zenity version listed above, in a script using chroot and a directory, where Zenity is installed. Steps to Reproduce: 1. 2. 3. Actual results: Zenity says this option isn't available. Expected results: Standard behavior, readiolist pops up, etc. Additional info: No additional information at this time.
It doesn't say that here, but instead pops up a dialog containing just the radio column. It works better if you add another --column
Well, if you could tell me why it is behaving like this, I would appreciate it.. I think I've been mixing and matching different quotes, with no quotes, I'm really out of ideas, take a look: [root@localhost ~]# perl -e '$RETURN = `/usr/bin/zenity --text \"Firewall Configuration\" --list --column \"Item\" --column \"Option\" --checklist TRUE Enabled FALSE Disabled`' [root@localhost ~]# rpm -q zenity zenity-2.16.0-1.fc6 [root@localhost ~]# perl -e '$RETURN = `/usr/sbin/chroot /tmp/kadischi.q6brJG/system /usr/bin/zenity --text \"Firewall Configuration\" --list --column \"Item\" --column \"Option\" --checklist TRUE Enabled FALSE Disabled`' This option is not available. Please see --help for all possible usages. [root@localhost ~]# /usr/sbin/chroot /tmp/kadischi.q6brJG/system /bin/rpm -q zenity zenity-2.18.0-1.fc7 [root@localhost ~]# The first invokation of zenity, which is a Fedora Core 6 zenity package, brings up the expected window, with the right options, the second one does not. strace output will be provided which may give you more insight, as I have already looked at it.
Created attachment 154090 [details] strace of Zenity Attached strace output: strace perl -e '$RETURN = `/usr/sbin/chroot /tmp/kadischi.q6brJG/system /usr/bin/zenity --text \"Firewall Configuration\" --list --column \"Item\" --column \"Option\" --checklist TRUE Enabled FALSE Disabled`' >/tmp/strace.log 2>&1
no idea, in any case, this is not a zenity problem, but some shell/perl quoting problem.
I'm not seeing how the addition of "/usr/sbin/chroot /tmp/directory/" makes it fail, leaving this to be a shell/perl quoting problem. It also fails with the same "This option is not available" using this in a BASH script: RETURN=$(/usr/sbin/chroot $SYSDIR /usr/bin/zenity --title "Firewall Configuration" --list --radiolist TRUE Enabled FALSE Disabled --column "Item" --column "Option") If I run that directly in the shell without /usr/sbin/chroot $SYSDIR, it works fine. That doesn't sound to me like a shell/perl quoting problem exactly.
RETURN=$(/usr/sbin/chroot / /usr/bin/zenity --text "Firewall Configuration" --list --radiolist E TRUE D FALSE --column "Item" --column "Option") works fine here. You will have to debug this yourself, I'm afraid. I'd propose to first see if SYSDIR=/ works, and then proceed to look for problems inside your SYSDIR.
Ok. Using strace I have located the problem, bringing it out of the Perl script and running it directly from the fake rootfs. The missing /tmp/.X11-unix and sockets associated with it, along with the hosts's ACL regarding connections to the X server were causing Zenity to return the option not available message. This could be considered a red herring error message, and I've since taken this issue up on Gnome's bugzilla. One thing however, is after the issues above are rectified for using Zenity in a seperate rootfs, under chroot(1), if no fonts are installed, Zenity will fail also, stating this is the case. Perhaps the Zenity package should have a Requires on a standard font package. Thanks Matthias.