Paul's Blog Entries for July 2009

Wednesday 1st July 2009

Local Packages

I built the automake packages as a reaction to the controversial set of updates to automake 1.11 made for Fedora releases 9, 10, and 11 - in particular the one for Fedora 11 which is already "stable". As a packager, I sometimes need to make patches to autotools files, and the resulting patches to the generated output is always smaller and more understandable if I use the same versions of the tools that the original project used, hence the usefulness of these compatibility packages.

Thursday 2nd June 2009

Local Packages

Friday 3rd July 2009

Fedora Project

Local Packages

Saturday 4th July 2009

Fedora Project

Local Packages

Sunday 5th July 2009

Local Packages

Tuesday 7th July 2009

Local Packages

Wednesday 8th July 2009

Local Packages

Friday 10th July 2009

Local Packages

Saturday 11th July 2009

Local Packages

Monday 13th July 2009

Local Packages

Tuesday 14th July 2009

Trac SpamFilter Plugin

My repository trac instance has recently attracted the interest of a pill-spammer, so I installed trac-spamfilter-plugin with a view to making life awkward for the spammer. Whilst it was easy enough to install, I had a few issues with it.

This latter problem turned out to be due to the (default) assumption by the SpamFilter plugin that authenticated users are to be trusted, i.e. not to have their submissions vetted by the spam filter. This assumption doesn't hold true when, as in my case, the AccountManager plugin is used to enable users to register themselves. The spammer was registering himself (or herself) and using the newly-created account to spam the wiki. This behaviour can be turned off, but not using the Admin pages in a browser. Instead, the following option needs to be added in the [spam-filter] section of trac.ini:

[spam-filter]
trust_authenticated = false

It's also necessary to make test submissions from an account that doesn't have TRAC_ADMIN permission - admins bypass the spam filter too, and that can't be turned off.

Fedora Project

Local Packages

Wednesday 15th July 2009

Problems with Yum and Arch/Noarch Packages

The yum tool as shipped in Fedora 11 will choose an arch-specific package over a "later" arch-independent package - Bug #502401. This is a bit of a blow for those of us trying to move ahead with Features/NoarchSubpackages and it's been closed UPSTREAM and not fixed in Fedora (a pet hate of mine). So I built the Rawhide version of yum (which contains the fix) for F-11 and stuck it in my local repository. This allowed me to build the perl-IO-Zlib update today (the package has build requirements that have changed from arch-specific to arch-independent, and F-11's yum was selecting the arch-specific version, which was too old for perl-IO-Zlib).

Using this update was not without its consequences. My custom repocheck script (a modified version of repoclosure) broke:

Running: repocheck --config=/home/paul/lib/repoc-rhel5-i386.conf --newest --checkrepo city-fan.org-rhel5-i386
Traceback (most recent call last):
  File "/home/paul/bin/repocheck", line 258, in <module>
    main()
  File "/home/paul/bin/repocheck", line 158, in main
    my = RepoClosure(arch = opts.arch, config = opts.config, builddeps = opts.builddeps)
  File "/home/paul/bin/repocheck", line 69, in __init__
    self.doConfigSetup(fn = config,init_plugins=False)
  File "/usr/lib/python2.6/site-packages/yum/__init__.py", line 168, in doConfigSetup
    return self.conf
  File "/usr/lib/python2.6/site-packages/yum/__init__.py", line 681, in <lambda>
    conf = property(fget=lambda self: self._getConfig(),
  File "/usr/lib/python2.6/site-packages/yum/__init__.py", line 210, in _getConfig
    arch = self.arch.canonarch
AttributeError: 'list' object has no attribute 'canonarch'

Now I don't know much python but after a bit of googling around and looking at the code, I made these changes, which seemed to fix things:

--- repoclosure.orig    2009-07-15 17:21:13.168971727 +0100
+++ repoclosure 2009-07-15 17:26:10.748969996 +0100
@@ -69,10 +69,11 @@
     def __init__(self, arch=[], config="/etc/yum.conf", builddeps=False, pkgonly=None):
         yum.YumBase.__init__(self)
         self.logger = logging.getLogger("yum.verbose.repoclosure")
-        self.arch = arch
+        self.arch.archlist = arch
         self.builddeps = builddeps
         self.pkgonly = pkgonly
-        self.doConfigSetup(fn = config,init_plugins=False)
+        self.preconf.fn = config
+        self.preconf.init_plugins = False
         if hasattr(self.repos, 'sqlite'):
             self.repos.sqlite = False
             self.repos._selectSackType()
@@ -98,10 +99,10 @@
     def readMetadata(self):
         self.doRepoSetup()
         archs = []
-        if not self.arch:
+        if not self.arch.archlist:
             archs.extend(rpmUtils.arch.getArchList())
         else:
-            for arch in self.arch:
+            for arch in self.arch.archlist:
                 archs.extend(rpmUtils.arch.getArchList(arch))
         if self.builddeps and 'src' not in archs:
             archs.append('src')

Fedora Project

Local Packages

Thursday 16th July 2009

Local Packages

Friday 17th July 2009

Local Packages

Fedora Project

Monday 27th July 2009

Local Packages

Fedora Project

Tuesday 28th July 2009

Local Packages

Wednesday 29th July 2009

Local Packages

Thursday 30th July 2009

Local Packages

Fedora Project

Finally committed my changes for proftpd in the devel branch following feedback from MatthiasSaou in Bug #506735. My first attempted build failed on i386 and x86_64 due to a parallel build problem that I'd not seen locally, so I raised upstream bug #3271 about it and disabled parallel build as a workaround.

Friday 31st July 2009

Fedora Project

Previous Month: June 2009
Next Month: August 2009