You are not logged in.

#1 2010-04-17 21:15:17

peets
Member
From: Montreal
Registered: 2007-01-11
Posts: 936
Website

rebuild homemade packages when a dependecy is upgraded?

I wrote a little volume bar for dzen which needs to be recompiled every time alsa is upgraded. Is there a way to automate this? After I run pacman -Syu, I'd like a message along the lines of "the following local packages need to be rebuilt".

The official package maintainers must have this issue all the time. How do you handle it?

Offline

#2 2010-04-17 21:48:47

falconindy
Developer
From: New York, USA
Registered: 2009-10-22
Posts: 4,111
Website

Re: rebuild homemade packages when a dependecy is upgraded?

The devs use python scripts to create rebuild lists. Looks like they're available on Allan's blog

Offline

#3 2010-04-17 22:51:18

Allan
Pacman
From: Brisbane, AU
Registered: 2007-06-09
Posts: 11,672
Website

Re: rebuild homemade packages when a dependecy is upgraded?

This is also the sort of thing I want to implement with hooks in pacman: http://wiki.archlinux.org/index.php/Use … cman_Hooks

Offline

#4 2010-04-18 04:07:43

peets
Member
From: Montreal
Registered: 2007-01-11
Posts: 936
Website

Re: rebuild homemade packages when a dependecy is upgraded?

Allan, http://allanmcrae.com/scripts/rebuildlist won't load for me... the name looks promising! Edit: loads fine now
I read pacman(8) again and a simple wrapper might do the trick? Unfortunately I can't test this yet because of the ephemeral nature of pacman -Sy && pacman -Quq

#!/bin/bash
# I haven't even tried running this
pacman -Sy
for pkg in $(pacman -Quq); do
    if [ $pkg = "alsa" ]; then
        rebuild_alsa=1
    fi
done
pacman -Su
if [ $rebuild_alsa -eq 1 ]; then
    # rebuild local package...
fi

Last edited by peets (2010-04-20 01:26:01)

Offline

Board footer

Powered by FluxBB