You are not logged in.

#1 2013-05-21 15:38:31

Nothing4You
Member
From: Germany
Registered: 2013-03-02
Posts: 10

[SOLVED] `makepkg` doesn't merge fetched git changes

Hey there,

I'm using this PKGBUILD:

# Maintainer: Dmitry Korzhevin <dkorzhevin AT gmail DOT com>
# Contributor: Mark Foxwell <fastfret79@archlinux.org.uk>
# Contributor: Licia Todd <tigrmesh at aol dot com>
# Contributor: Tim Zebulla <amon at faumrahrer dot de>
# Contributor: Richard Schwab <mail NOSPAM w.tf-w.tf>

pkgname=weechat-git
pkgver=0.4.1.rc2.9.gb045a35
pkgrel=1
epoch=1
pkgdesc="Fast, light & extensible IRC client (curses UI)"
arch=('i686' 'x86_64')
url="http://www.weechat.org/"
license=('GPL3')
depends=('curl' 'gnutls' 'ncurses')
makedepends=('git' 'aspell' 'cmake' 'lua' 'perl' 'python2' 'ruby' 'tcl')
optdepends=('aspell' 'lua' 'perl' 'python2' 'ruby' 'tcl')
provides=('weechat')
conflicts=('weechat')
options=(!libtool !strip debug)
source=(git://git.sv.gnu.org/weechat.git)
md5sums=(SKIP)

pkgver() {
  cd weechat
  git describe | sed "s/^v//; s/-/./g"
}

build() {
  cd weechat
  mkdir build
  cd build
  cmake .. -DPREFIX=/usr \
        -DPYTHON_EXECUTABLE=/usr/bin/python2 \
        -DPYTHON_LIBRARY=/usr/lib/libpython2.7.so
}

package() {
  cd weechat/build
  make DESTDIR="$pkgdir/" install
}

When I run `makepkg` and there are updates it fetches the updates, then tells me I'd already have the newest version.
When I manually check out ~/build/weechat-git-custom/weechat (this is the git repo), then I see that the master branch doesn't have anything new since I cloned it.
When I `git checkout origin/master` I can see all the changes with `git log` because they were fetched.
Manually doing `git pull` in the repo merges the updates, then I can just do `makepkg` in the package dir and it builds it correctly.

TL;DR: `makepkg` fetches git updates but it doesn't merge them.

Last edited by Nothing4You (2013-05-22 00:04:48)

Offline

#2 2013-05-21 15:55:21

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

Re: [SOLVED] `makepkg` doesn't merge fetched git changes

Is your source repo a bare repo or is this some existing clone that you had and have been using since before makepkg supported VCS?

Why are you "renaming" the repo when it's already going to be named weechat?

Offline

#3 2013-05-21 16:00:18

Nothing4You
Member
From: Germany
Registered: 2013-03-02
Posts: 10

Re: [SOLVED] `makepkg` doesn't merge fetched git changes

The source clone was cloned with the same PKGBUILD.
If by renaming you mean using weechat-git-custom as dir it's because it's not the weechat-git package from AUR and I usually keep the original AUR PKGBUILDs there, and I will most likely switch to the AUR package again when there were some changes done to that PKGBUILD.

Offline

#4 2013-05-21 16:16:27

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

Re: [SOLVED] `makepkg` doesn't merge fetched git changes

Nothing4You wrote:

If by renaming you mean using weechat-git-custom as dir it's because it's not the weechat-git package from AUR and I usually keep the original AUR PKGBUILDs there, and I will most likely switch to the AUR package again when there were some changes done to that PKGBUILD.

No, that isn't what I meant. Your source array is declared as "weechat::git://git.sv.gnu.org/weechat.git". This doesn't do anything because the repo will already be called 'weechat' in your SRCDEST.

Offline

#5 2013-05-21 16:29:12

Nothing4You
Member
From: Germany
Registered: 2013-03-02
Posts: 10

Re: [SOLVED] `makepkg` doesn't merge fetched git changes

Removed that from my PKGBUILD (and edited start post), that shouldn't matter for my problem though.

Offline

#6 2013-05-21 17:10:41

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

Re: [SOLVED] `makepkg` doesn't merge fetched git changes

I suspect you need to further investigate my first question about the status of the repo -- it must be a bare repo. The fact that you're able to run "git checkout" in the repo is wrong. It will invariably fail in a bare repo:

/mnt/Haven/sources/weechat $ git checkout master
fatal: This operation must be run in a work tree

Offline

#7 2013-05-21 17:35:57

Nothing4You
Member
From: Germany
Registered: 2013-03-02
Posts: 10

Re: [SOLVED] `makepkg` doesn't merge fetched git changes

You're right, it's indeed different after cloning it with makepkg. I might have been wrong and I probably just copied it from the older PKGBUILD.

I'll try doing it this way and mark this solved when there is the next upgrade and it works.

Thanks for the help.

Offline

#8 2013-05-22 00:04:27

Nothing4You
Member
From: Germany
Registered: 2013-03-02
Posts: 10

Re: [SOLVED] `makepkg` doesn't merge fetched git changes

Thanks, solved.

Offline

Board footer

Powered by FluxBB