You are not logged in.

#1 2012-10-19 18:02:18

biltong
Member
From: South Africa
Registered: 2011-09-01
Posts: 116

[solved]makepkg -e ignoring the -e?

Trying to build a package that includes curl/types.h which has been removed from the curl package, but every time I comment out the include and run makepkg -e it re-extracts from the source file and overwrites my changes anyway. I thought the entire point of the -e option was to use the existing src/ directory as-is? That's what it says it does with makepkg --help:

$ makepkg --help
makepkg (pacman) 4.0.3

Usage: /usr/bin/makepkg [options]

Options:
  -A, --ignorearch Ignore incomplete arch field in PKGBUILD
  -c, --clean      Clean up work files after build
  -d, --nodeps     Skip all dependency checks
  -e, --noextract  Do not extract source files (use existing src/ dir)
  -f, --force      Overwrite existing package
  -g, --geninteg   Generate integrity checks for source files
  -h, --help       Show this help message and exit
  -i, --install    Install package after successful build
  -L, --log        Log package build process
<snip>

Last edited by biltong (2012-10-20 15:49:20)

Offline

#2 2012-10-19 19:20:16

Trilby
Forum Moderator
From: Massachusetts, USA
Registered: 2011-11-29
Posts: 13,690
Website

Re: [solved]makepkg -e ignoring the -e?

Which package?  Is it a vcs package (git,hg,svn ...)?

Edit: you are correct about the "-e" option, and it works perfectly here.  But the reason I asked about whether it was a vcs package was that these do not have source tarballs to extract, the source is downloaded in the build function, so you'd have to apply a sed/patch after the vcs line(s) in the PKGBUILD.

Last edited by Trilby (2012-10-19 19:21:35)


InterrobangSlider
• How's my coding? See this page.
• How's my moderating? Feel free to email any concerns, complaints, or objections.

Offline

#3 2012-10-20 09:10:06

biltong
Member
From: South Africa
Registered: 2011-09-01
Posts: 116

Re: [solved]makepkg -e ignoring the -e?

The package is littleblackbox (https://aur.archlinux.org/packages.php?ID=44692) and you are right, it extracts the tar in build() so I'm either gonna have to edit the source or make a patch.

Offline

#4 2012-10-20 11:45:28

Trilby
Forum Moderator
From: Massachusetts, USA
Registered: 2011-11-29
Posts: 13,690
Website

Re: [solved]makepkg -e ignoring the -e?

That is not a vcs build.  There is an svn version of littleblackbox available, but this is for one of the versioned releases.

That PKGBUILD really does need some TLC though.  It should not try to re-extract the source tarball in the build function, this is what is causing your problems.

Here's a modified version that solves that issue:

pkgname=littleblackbox
pkgver=0.1.3
pkgrel=1
pkgdesc="security/penetration testing tool, search in a collection of thousands of private SSL keys extracted from various embedded devices"
arch=(any)
url="http://code.google.com/p/littleblackbox/wiki/FAQ"
license=('MIT')
depends=('openssl' 'libpcap' 'sqlite3')
source=('https://littleblackbox.googlecode.com/files/littleblackbox-0.1.3.tar.gz')
md5sums=('7ddc140beda3f98c34db644b01fc4d84')

build() {
cd $pkgname-$pkgver
rm -f bin/$pkgname 2>/dev/null
cd src
make distclean
./configure
make
}

package() {
cd $srcdir/$pkgname-$pkgver

install -m755 -d ${pkgdir}/usr/bin $pkgdir/usr/share/doc/$pkgname \
    $pkgdir/usr/share/licenses/$pkgname $pkgdir/usr/share/$pkgname

install -m755 bin/$pkgname ${pkgdir}/usr/bin
install -m644 bin/lbb.db $pkgdir/usr/share/$pkgname
ln -s /usr/share/$pkgname/lbb.db $pkgdir/usr/bin/lbb.db

install -m644 docs/LICENSE $pkgdir/usr/share/$pkgname

install -m644 docs/{FAQ,README,submission.txt} $pkgdir/usr/share/doc/$pkgname

msg "done"
}

# vim:set ts=2 sw=2 et:

Last edited by Trilby (2012-10-20 11:46:31)


InterrobangSlider
• How's my coding? See this page.
• How's my moderating? Feel free to email any concerns, complaints, or objections.

Offline

#5 2012-10-20 14:23:33

biltong
Member
From: South Africa
Registered: 2011-09-01
Posts: 116

Re: [solved]makepkg -e ignoring the -e?

Oh thanks smile I already put a "fixed" version up in a comment though, but I don't really know much about PKGBUILDs or how to write them, I just use them.

Last edited by biltong (2012-10-20 14:23:55)

Offline

#6 2012-10-20 14:32:24

WonderWoofy
Member
From: Los Gatos, CA
Registered: 2012-05-19
Posts: 8,412

Re: [solved]makepkg -e ignoring the -e?

Don't forget to mark your post as [Solved].

Offline

Board footer

Powered by FluxBB