You are not logged in.

#1 2019-11-23 03:17:36

atomikegg
Member
Registered: 2019-08-14
Posts: 99

"hunks failed" on makepkg

Hi

Pure arch, new install. The following are installed:
git, nim, arch-install-scripts, git, gcc, base-devel, fakeroot, binutils

Trying to compile pakku, getting error:

$ git clone https://aur.archlinux.org/pakku.git
Cloning into 'pakku'...
remote: Enumerating objects: 65, done.
remote: Counting objects: 100% (65/65), done.
remote: Compressing objects: 100% (41/41), done.
remote: Total 65 (delta 24), reused 65 (delta 24)
Unpacking objects: 100% (65/65), done.

$ cd pakku/
$ makepkg -si
==> Making package: pakku 0.13-2 (Sat Nov 23 02:27:24 2019)
==> Checking runtime dependencies...
==> Checking buildtime dependencies...
==> Retrieving sources...
  -> Downloading pakku-0.13.tar.xz...
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100   608    0   608    0     0   1747      0 --:--:-- --:--:-- --:--:--  1742
100 56536  100 56536    0     0  47709      0  0:00:01  0:00:01 --:--:--  416k
==> Validating source files with sha256sums...
    pakku-0.13.tar.xz ... Passed
==> Extracting sources...
  -> Extracting pakku-0.13.tar.xz with bsdtar
==> Starting build()...
GEN: completion/bash
1 out of 4 hunks FAILED
make: *** [Makefile:90: completion/bash] Error 1
==> ERROR: A failure occurred in build().
    Aborting...

i noticed i was able to makepkg with no probs on https://aur.archlinux.org/xfce4-panel-profiles.git
So this seems a problem specific to pakku. 

i tried pakku again with `-L` logging flag, but the output log contains only the same messages that were displayed on the console.

I never altered the contents of makepkg.conf. Here's that:

#!/hint/bash
#
# /etc/makepkg.conf
#

#########################################################################
# SOURCE ACQUISITION
#########################################################################
#
#-- The download utilities that makepkg should use to acquire sources
#  Format: 'protocol::agent'
DLAGENTS=('file::/usr/bin/curl -gqC - -o %o %u'
          'ftp::/usr/bin/curl -gqfC - --ftp-pasv --retry 3 --retry-delay 3 -o %o %u'
          'http::/usr/bin/curl -gqb "" -fLC - --retry 3 --retry-delay 3 -o %o %u'
          'https::/usr/bin/curl -gqb "" -fLC - --retry 3 --retry-delay 3 -o %o %u'
          'rsync::/usr/bin/rsync --no-motd -z %u %o'
          'scp::/usr/bin/scp -C %u %o')

# Other common tools:
# /usr/bin/snarf
# /usr/bin/lftpget -c
# /usr/bin/wget

#-- The package required by makepkg to download VCS sources
#  Format: 'protocol::package'
VCSCLIENTS=('bzr::bzr'
            'git::git'
            'hg::mercurial'
            'svn::subversion')

#########################################################################
# ARCHITECTURE, COMPILE FLAGS
#########################################################################
#
CARCH="x86_64"
CHOST="x86_64-pc-linux-gnu"

#-- Compiler and Linker Flags
CPPFLAGS="-D_FORTIFY_SOURCE=2"
CFLAGS="-march=x86-64 -mtune=generic -O2 -pipe -fno-plt"
CXXFLAGS="-march=x86-64 -mtune=generic -O2 -pipe -fno-plt"
LDFLAGS="-Wl,-O1,--sort-common,--as-needed,-z,relro,-z,now"
#-- Make Flags: change this for DistCC/SMP systems
#MAKEFLAGS="-j2"
#-- Debugging flags
DEBUG_CFLAGS="-g -fvar-tracking-assignments"
DEBUG_CXXFLAGS="-g -fvar-tracking-assignments"

#########################################################################
# BUILD ENVIRONMENT
#########################################################################
#
# Defaults: BUILDENV=(!distcc !color !ccache check !sign)
#  A negated environment option will do the opposite of the comments below.
#
#-- distcc:   Use the Distributed C/C++/ObjC compiler
#-- color:    Colorize output messages
#-- ccache:   Use ccache to cache compilation
#-- check:    Run the check() function if present in the PKGBUILD
#-- sign:     Generate PGP signature file
#
BUILDENV=(!distcc color !ccache check !sign)
#
#-- If using DistCC, your MAKEFLAGS will also need modification. In addition,
#-- specify a space-delimited list of hosts running in the DistCC cluster.
#DISTCC_HOSTS=""
#
#-- Specify a directory for package building.
#BUILDDIR=/tmp/makepkg

#########################################################################
# GLOBAL PACKAGE OPTIONS
#   These are default values for the options=() settings
#########################################################################
#
# Default: OPTIONS=(!strip docs libtool staticlibs emptydirs !zipman !purge !debug)
#  A negated option will do the opposite of the comments below.
#
#-- strip:      Strip symbols from binaries/libraries
#-- docs:       Save doc directories specified by DOC_DIRS
#-- libtool:    Leave libtool (.la) files in packages
#-- staticlibs: Leave static library (.a) files in packages
#-- emptydirs:  Leave empty directories in packages
#-- zipman:     Compress manual (man and info) pages in MAN_DIRS with gzip
#-- purge:      Remove files specified by PURGE_TARGETS
#-- debug:      Add debugging flags as specified in DEBUG_* variables
#
OPTIONS=(strip docs !libtool !staticlibs emptydirs zipman purge !debug)

#-- File integrity checks to use. Valid: md5, sha1, sha256, sha384, sha512
INTEGRITY_CHECK=(md5)
#-- Options to be used when stripping binaries. See `man strip' for details.
STRIP_BINARIES="--strip-all"
#-- Options to be used when stripping shared libraries. See `man strip' for details.
STRIP_SHARED="--strip-unneeded"
#-- Options to be used when stripping static libraries. See `man strip' for details.
STRIP_STATIC="--strip-debug"
#-- Manual (man and info) directories to compress (if zipman is specified)
MAN_DIRS=({usr{,/local}{,/share},opt/*}/{man,info})
#-- Doc directories to remove (if !docs is specified)
DOC_DIRS=(usr/{,local/}{,share/}{doc,gtk-doc} opt/*/{doc,gtk-doc})
#-- Files to be removed from all packages (if purge is specified)
PURGE_TARGETS=(usr/{,share}/info/dir .packlist *.pod)
#-- Directory to store source code in for debug packages
DBGSRCDIR="/usr/src/debug"

#########################################################################
# PACKAGE OUTPUT
#########################################################################
#
# Default: put built package and cached source in build directory
#
#-- Destination: specify a fixed directory where all packages will be placed
#PKGDEST=/home/packages
#-- Source cache: specify a fixed directory where source files will be cached
#SRCDEST=/home/sources
#-- Source packages: specify a fixed directory where all src packages will be placed
#SRCPKGDEST=/home/srcpackages
#-- Log files: specify a fixed directory where all log files will be placed
#LOGDEST=/home/makepkglogs
#-- Packager: name/email of the person or organization building packages
#PACKAGER="John Doe <john@doe.com>"
#-- Specify a key to use for package signing
#GPGKEY=""

#########################################################################
# COMPRESSION DEFAULTS
#########################################################################
#
COMPRESSGZ=(gzip -c -f -n)
COMPRESSBZ2=(bzip2 -c -f)
COMPRESSXZ=(xz -c -z -)
COMPRESSZST=(zstd -c -z -q -)
COMPRESSLRZ=(lrzip -q)
COMPRESSLZO=(lzop -q)
COMPRESSZ=(compress -c -f)
COMPRESSLZ4=(lz4 -q)
COMPRESSLZ=(lzip -c -f)

#########################################################################
# EXTENSION DEFAULTS
#########################################################################
#
PKGEXT='.pkg.tar.xz'
SRCEXT='.src.tar.gz'

Is this a compatibility issue with the kernel? Some other dependency needed?
Please let me know what other info i can share, to help solve this.

thx

Last edited by atomikegg (2019-11-23 03:26:52)

Offline

#2 2019-11-23 03:29:07

loqs
Member
Registered: 2014-03-06
Posts: 17,324

Re: "hunks failed" on makepkg

Did you read the comments on https://aur.archlinux.org/packages/pakku/ ?

Offline

#3 2019-11-24 15:53:28

atomikegg
Member
Registered: 2019-08-14
Posts: 99

Re: "hunks failed" on makepkg

Yes i did, and sounds like there's a known problem which, if it is the same problem i'm seeing, that's fine, i'll wait for fixes to come through normal upgrades. I just wanted to ensure the problem was with pakku, and not with my arch.

pakku is working fine on another of my arch installs, i don't understand why it would work on one arch but not another, they are almost identical arch installs. That's why i thought the issue might be with my OS, not pakku.

Re the comments on the AUR page:
- i don't understand any of this well enough to understand if the comments are about my issue or a different issue.
- seems there are different opinions about the cause and fix. I can't tell which are related to my issue and which aren't.
- the current fixes are all workarounds, may include patching something, downgrading something else, and/or copying a file over from another OS.
Workarounds make me nervous.

Possible causes/fixes:

- Could be a nim problem. Downgrading nim might fix it, but downgrading individual packages makes me feel confused about the state of the OS, worried that `-Syu` will overwrite the downgrade.

- Some mention a compile issue (similar to what i'm seeing). Others mention a runtime issue. I don't know if these two issues are related or not.

- could require a patch, nim might break the patch, maybe i need to downgrade nim plus apply the patch?
https://github.com/kitsunyan/pakku/pull/49

- one person says linking fixes it, another says linking can break things. Maybe an unrelated issue.

- another says to copy over bash_completion from another OS is a workaround, but that's an older comment, maybe an unrelated issue.

Again, just wanted to ensure the problem was with packages, and not with my arch. I prefer to keep things simple, so as long as my arch isn't broken, i'd rather just wait for fixes in the standard packages, and do the manual `git clone ... makepkg` process without pakku for now.

Hope this makes sense. Thx

Offline

#4 2019-11-24 16:11:13

loqs
Member
Registered: 2014-03-06
Posts: 17,324

Re: "hunks failed" on makepkg

atomikegg wrote:

Yes i did, and sounds like there's a known problem which, if it is the same problem i'm seeing, that's fine, i'll wait for fixes to come through normal upgrades. I just wanted to ensure the problem was with pakku, and not with my arch.

pakku is working fine on another of my arch installs, i don't understand why it would work on one arch but not another, they are almost identical arch installs. That's why i thought the issue might be with my OS, not pakku.

Most likely pakku was built on that system before the 5.2 update.

atomikegg wrote:

- could require a patch, nim might break the patch, maybe i need to downgrade nim plus apply the patch?
https://github.com/kitsunyan/pakku/pull/49

The issue is not connected to nim.  pakku does not ship bash / zsh completions [1] it takes completions supplied by pacman [2] deletes parts of them,  alters the result with sed then patches the result of that.
This very fragile approach broke with pacman 5.2 which changed the bash completion pacman used.

[1] https://github.com/kitsunyan/pakku/tree … completion
[2] https://github.com/kitsunyan/pakku/blob … on/make.sh

Offline

#5 2019-12-08 02:00:40

atomikegg
Member
Registered: 2019-08-14
Posts: 99

Re: "hunks failed" on makepkg

loqs wrote:

pakku does not ship bash / zsh completions [1] it takes completions supplied by pacman [2] deletes parts of them,  alters the result with sed then patches the result of that.
This very fragile approach broke with pacman 5.2 which changed the bash completion pacman used.

Thx for feedback. Is there a less fragile aur front-end?

thx

Offline

#6 2019-12-08 02:15:49

merlock
Member
Registered: 2018-10-30
Posts: 235

Re: "hunks failed" on makepkg

Arguably, the best thing that I did when I started my Arch journey was to skip out an all of the pacman 'wrappers' and learned to do AUR stuff via the command line.


Eenie meenie, chili beanie, the spirits are about to speak -- Bullwinkle J. Moose
It's a big club...and you ain't in it -- George Carlin
Registered Linux user #149839
perl -e 'print$i=pack(c5,(41*2),sqrt(7056),(unpack(c,H)-2),oct(115),10); '

Offline

#7 2020-01-16 21:57:11

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

Re: "hunks failed" on makepkg

Downgrade nim to 0.18something (only needed for building) and build pakku-git. Afterwards you might upgrade nim again.

Offline

#8 2020-01-16 22:06:21

loqs
Member
Registered: 2014-03-06
Posts: 17,324

Re: "hunks failed" on makepkg

Stefan Husmann wrote:

Downgrade nim to 0.18something (only needed for building) and build pakku-git. Afterwards you might upgrade nim again.

How would downgrading nim fix an issue caused by an update to pacman's bash completion?

Offline

Board footer

Powered by FluxBB