You are not logged in.

#1 2011-08-25 17:41:38

Unia
Member
From: Stockholm, Sweden
Registered: 2010-03-30
Posts: 2,486
Website

[SOLVED] Edit bzr using PKGBUILD to install an older version?

Hello,

My understanding of bzr is close to zero, so this might be impossible.. anyway, I would like to build Slingshot (the launcher from the elementary project), but the latest version gives me an error when I launch it (it compiles fine, though). I figured I should use/build an older version, because I used it before and it worked properly. However, I can't seem to get this done, so I'm asking for your help.

How would I edit this PKGBUILD to use an older revision? Latest is numbered 48, I would like to try 46.. Simply chancing 48 to 46 doesn't work, sadly.

pkgname=slingshot-bzr
pkgver=48
pkgrel=1
pkgdesc="An application launcher by the Elementary project"
arch=(i686 x86_64)
url=https://launchpad.net/slingshot-launcher
license=(GPL)
depends=(glib2 gnome-menus gtk2 libgee libunique libwnck)
makedepends=(bzr intltool vala)
options=('!libtool' '!emptydirs')
install=slingshot-bzr.install

_bzrtrunk=lp:slingshot
_bzrmod=slingshot

build()
{
  msg "Connecting to Launchpad..."
  if [ -d ${_bzrmod} ]; then
    bzr up ${_bzrmod}
    msg2 "The local files have been updated."
  else
    bzr co ${_bzrtrunk} ${_bzrmod}
  fi
  msg2 "BZR checkout done or server timeout"
  [ -d ${_bzrmod}-build ] && rm -r ${_bzrmod}-build
  cp -a ${_bzrmod} ${_bzrmod}-build
  cd ${_bzrmod}-build
  valac --pkg gtk+-2.0 \
        --pkg unique-1.0 \
        --pkg gee-1.0 \
        --pkg gio-unix-2.0 \
        --pkg libgnome-menu --Xcc='-DGMENU_I_KNOW_THIS_IS_UNSTABLE' \
        --pkg libwnck-1.0 --Xcc='-DWNCK_I_KNOW_THIS_IS_UNSTABLE' \
        slingshot.vala \
        frontend/widgets/*.vala \
        frontend/*.vala \
        backend/*.vala
  install -Dm755 slingshot "${pkgdir}"/usr/bin/slingshot
}

Last edited by Unia (2011-08-26 16:58:31)


If you can't sit by a cozy fire with your code in hand enjoying its simplicity and clarity, it needs more work. --Carlos Torres

Offline

#2 2011-08-25 18:05:04

karol
Archivist
Registered: 2009-05-06
Posts: 25,440

Re: [SOLVED] Edit bzr using PKGBUILD to install an older version?

The url still points to the same place, you need to find the older code.

Offline

#3 2011-08-25 18:07:01

Unia
Member
From: Stockholm, Sweden
Registered: 2010-03-30
Posts: 2,486
Website

Re: [SOLVED] Edit bzr using PKGBUILD to install an older version?

Forgive me asking this, but what url? The

url=https://launchpad.net/slingshot-launcher

Would I then need to browse the launchpad website to the url holding the older revision's code?


If you can't sit by a cozy fire with your code in hand enjoying its simplicity and clarity, it needs more work. --Carlos Torres

Offline

#4 2011-08-25 18:13:53

karol
Archivist
Registered: 2009-05-06
Posts: 25,440

Re: [SOLVED] Edit bzr using PKGBUILD to install an older version?

Unia wrote:

Forgive me asking this, but what url? The

url=https://launchpad.net/slingshot-launcher

Would I then need to browse the launchpad website to the url holding the older revision's code?

Yes, that's the url I meant. I have no idea how launchpad works but I hate its interface with a passion ;P

Look at e.g. https://aur.archlinux.org/packages/go/g … s/PKGBUILD

source=(http://google-perftools.googlecode.com/files/$pkgname-$pkgver.tar.gz)

In this situation, changing the $pkgver would likely be enough unless the config options or patches don't apply to a previous version.

Offline

#5 2011-08-25 18:43:31

Unia
Member
From: Stockholm, Sweden
Registered: 2010-03-30
Posts: 2,486
Website

Re: [SOLVED] Edit bzr using PKGBUILD to install an older version?

But AFAIK, bzr doesn't work like that.. correct me if I'm wrong though, because as I said I don't get it at all


If you can't sit by a cozy fire with your code in hand enjoying its simplicity and clarity, it needs more work. --Carlos Torres

Offline

#6 2011-08-25 20:40:05

jomasti
Member
From: USA
Registered: 2010-08-17
Posts: 96

Re: [SOLVED] Edit bzr using PKGBUILD to install an older version?

I took a look at the manpage for bzr, and the checkout command has a revision option. So, maybe this change will work:

bzr co ${_bzrtrunk} ${_bzrmod} -r $pkgver

The current src folder should be removed so bzr doesn't try to update instead of checkout. Or you could change the bzr up to bzr revert with the revision option. I don't really know.

Offline

#7 2011-08-25 21:57:39

Stefan Husmann
Member
From: Germany
Registered: 2007-08-07
Posts: 1,391

Re: [SOLVED] Edit bzr using PKGBUILD to install an older version?

Doesn't do makepkg --holdver work for you?

If you know the revision number of a working commit, you can edit the PKGBUILD to set that number as $pkgver. Then run makepkg --holdver.

Offline

#8 2011-08-26 16:58:13

Unia
Member
From: Stockholm, Sweden
Registered: 2010-03-30
Posts: 2,486
Website

Re: [SOLVED] Edit bzr using PKGBUILD to install an older version?

jomasti wrote:

I took a look at the manpage for bzr, and the checkout command has a revision option. So, maybe this change will work:

bzr co ${_bzrtrunk} ${_bzrmod} -r $pkgver

The current src folder should be removed so bzr doesn't try to update instead of checkout. Or you could change the bzr up to bzr revert with the revision option. I don't really know.

This,

Stefan Husmann wrote:

Doesn't do makepkg --holdver work for you?

If you know the revision number of a working commit, you can edit the PKGBUILD to set that number as $pkgver. Then run makepkg --holdver.

and that, together worked! Thank you guys! Seems like rev 46 still doesn't work, but I'll try another rev!


If you can't sit by a cozy fire with your code in hand enjoying its simplicity and clarity, it needs more work. --Carlos Torres

Offline

Board footer

Powered by FluxBB