Archive for the ‘Uncategorized’ Category

Sadly, back to chromium

Wednesday, May 26th, 2010

My day job does not involve Linux or programming, so I usually go around with a netbook as my primary machine.
Sadly, on F13 (which I installed gracefully since beta) Firefox has some performance issue, such as to force me to Chromium. So no weave anymore (weave is awesome) and some support less for the FLOSS world.

Hope Firefox catch back the performance crown, or anyway improve it to be good enough. In the meantime, Chromium is my platform.

Spam Results

Wednesday, May 5th, 2010

Posts now require registration. Too much spam, even for a low profile, low posting blog like this.

Pinax Dependencies – django-extensions

Monday, August 24th, 2009

Ok, so I checked Pinax dependencies and found some external libs to be packaged before being able to completely package Pinax. This packages will form the “depends” line of Pinax itself.

Looking carefully, the first one is named django_extensions, but really the name should be “django-extensions”, and you can find the project with the not intuitive name of “django-commandline-extensions” here at googlecode.

Ok, let’s see the spec file:

%{!?python_sitelib: %define python_sitelib %(%{__python} -c “from distutils.sysconfig import get_python_lib; print get_python_lib()”)}

Name:           django-extensions
Version:        0.4.1
Release:        1%{?dist}
Summary:        Django command line extensions

Up to this point, standard stuff. The {?dist} should stand for “current distribution”, so it will end in a “fc11″ package.

Group:          Development/Languages
License:        BSD
URL:            http://code.google.com/p/django-command-extensions/
Source0:        %{name}-%{version}.tar.gz
Source1:        %{name}-docs-%{version}.tar.gz

The Group is standard for Python / Django libraries. License is taken from the project’s homepage, source is the standard .tar.gz file which is downloaded from the front page of the project. Source1 is extracted from the github 0.4.1 tag of the project and contains just the documentation to be built.

BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)

BuildArch:      noarch
BuildRequires:  python-devel python-sphinx
Requires:       Django

%description
This is a repository for collecting global custom management extensions
for the Django Framework

The buildroot path is standard, arch is noarch (just python code…), the build requires gets the addition of python-sphinx (python documentation generator) which, at buildtime, generates html documentation from .rst files. Obviously runtime requirements are Django, while the description is a copy and paste from the project home page.

%package doc
Summary:        Documentation for django-extensions
Group:          Documentation
Requires:       %{name} = %{version}-%{release}
Provides:       %{name}-docs = %{version}-%{release}
Obsoletes:      %{name}-docs < %{version}-%{release}

%description doc
This package contains the documentation for the django-extension library

Wait a minute, what is this? Exactly, we are building not one but two packages. One for code, one for doc.

%prep
%setup -q -n %{name}-%{version}
%setup -a 1

Ok, now things become interesting. According to both the Fedora Project RPM Guide and the Maximum RPM book on rpm.org, the above section reads as: prepare environment; extract first source file silently in a directory named $name-$version (e.g. django-extension-0.4.1), then extract the second source file after changing directory to the newly created directory. This is necessary because I compressed just the docs directory level in the git-donwloaded file.

%build
%{__python} setup.py build

%install
rm -rf $RPM_BUILD_ROOT
%{__python} setup.py install -O1 –skip-build –root $RPM_BUILD_ROOT

(cd docs && make html)

All this stuff comes standard creating an empty python spec file, apart from the last line, which builds the html documentation. This is suggested also by Django spec file (go get it with a yumdownloader –source Django and rpm -ivh the src.rpm).

%clean
rm -rf $RPM_BUILD_ROOT

%files
%defattr(-,root,root,-)
%{python_sitelib}/*

Standard stuff again.

%files doc
%doc docs

doc packages files

%changelog
* Sun Aug 23 2009 Luca Botti <lucabotti…fedoraproject.org>
- Initial RPM Release

changelog description.

This file is uploaded at my fedorapeople.org’s address and is submitted in bugzilla for review here. I am waiting for sponsorship. Thanks.

More packages will follow. Stay tuned.

Submitting packages

Saturday, August 22nd, 2009

After reading Tim Niemueller’s blog entry I contacted him proposing to maintain the packages he prepared, so now I am beginning to submit them for maintenance.

I need sponsorship, so if somebody reading this blog entry is willing to step up, bugzilla’s bug 518647 and bug 518636 are asking for support.

A question to fedora guys: why the fedorapeople.org email alias is not working with my mail address?

JDK6 update 16 and Fedora

Saturday, August 15th, 2009

Sun did it again. They released the update to jdk (a security fixes update) just few days after my previous post .

Ok, then. Let’s try to keep up the pace. Just download this file and be happy again. Just, before doing the install, remove previous packages.

A note to contributors: I did not merge your suggestions, yet, because right now I am on vacation. In the next weeks I will check them.