Monday 9 April 2012

Release 0.2 : Packaging Raspberry PI Kernel utility

Hey everyone, I've really been delaying work on this kernel utility package but hopefully in the next few days get everything working. I'm releasing a late 0.2 release with some changes to the package from 0.1 I released few weeks back. The changes I made were with the permissions of the file, location files are being installed to and the license. Also I fixed some errors with the RPM using rpmlint.

One of the things I did for this release was to check to see If I can actually install this package on my laptop running Fedora 16. The install worked and the files in the package are copied to the raspi-tools directory created in /usr/bin whereas my previous release installed to /usr/share.

Changed the %install section line
FROM-> mkdir -p %{buildroot}%{base_dir}/imagetool
TO->   mkdir -p -m 755 %{buildroot}%{_bindir}/raspi-tools
It was also mentioned to me from my previous release that the license section of my spec file had to be looked into regarding the author of the python script. With assistance to locate the information, I checked raspberry pi repository on github and found the person responsible for the tool after checking the commit message. I emailed the user and received confirmation to treat it as GPLv2.

I have tested the RPM with rpmlint and the SRPM's with Mock. There are some errors from the RPM that I am trying to fix for release 0.3 in the coming days.

Having installed the package on my Fedora 16, I attempted to run the script but received an error regarding the location the other file the python script needs to read from.

[namnguyen@timeline ~]$ /usr/bin/raspi-tools/imagetool-uncompressed.py
Traceback (most recent call last):
  File "/usr/bin/raspi-tools/imagetool-uncompressed.py", line 31, in <module>
    load_to_mem("boot-uncompressed.txt", 0x00000000)
  File "/usr/bin/raspi-tools/imagetool-uncompressed.py", line 17, in load_to_mem
    f = open(name)
IOError: [Errno 2] No such file or directory: 'boot-uncompressed.txt' 


Currently trying to get all of this fixed for my the next and final release. You can view my spec file, download my RPM and SRPM at the location below
View spec file Here
RPM Download
SRPM Download

2 comments:

  1. Hi,

    You have this error (IOError: [Errno 2] No such file or directory: 'boot-uncompressed.txt') because you do not run imagetool-uncompressed.py from its directory : (...)/tools/mkimage/ , but from else where.

    You should :

    cd (...)/tools/mkimage/
    python ./imagetool-uncompressed.py (...)/linux/arch/arm/boot/Image

    ReplyDelete
  2. Hello there,

    thanks for the suggestion, I have since then got past this problem by creating a patch file for modification of the python script by having the full directory path and is similar to what you have mentioned, the most recent work on this is my April post on Release 3.0(updated)

    ReplyDelete