You are not logged in.

#1 2016-11-09 15:02:10

Hi-Angel
Member
Registered: 2016-07-16
Posts: 43

[SOLVED] How to rerun makepkg without removing the source?

It doesn't seem to be a rare problem, but I can't find a relevant info.

Suppose for running makepkg, build failed (i.e. I was building wine-gallium, and got linking errors because of -flto).

Next I want to rerun makepkg without removing the source, ideally continuing the build (say, in case of -flto errors it's enough to remove the option from the linker to go unused).

However, simple rerunning the command doesn't help, because it have to apply patches. Fortunately, it sees that something wrong, and asks for whether to apply them, but unfortunately, for whatever reason it stops the build anyway. Here's an example:

$ makepkg               
==> Making package: wine-gaming-nine 1.9.22-1 (Wed Nov  9 17:41:37 MSK 2016)
==> Checking runtime dependencies...
==> Checking buildtime dependencies...
==> Retrieving sources...
  -> Found staging-1.9.22.tar.gz
  -> Found wine-d3d9-1.9.22.tar.gz
  -> Found 30-win32-aliases.conf
  -> Found heap_perf.patch
  -> Found increase_max_frag_samplers.patch
  -> Found keybindings.patch
  -> Found steam.patch
  -> Found wbemprox_query_v2.patch
==> Validating source files with sha1sums...
    staging-1.9.22.tar.gz ... Passed
    wine-d3d9-1.9.22.tar.gz ... Passed
    30-win32-aliases.conf ... Passed
    heap_perf.patch ... Passed
    increase_max_frag_samplers.patch ... Passed
    keybindings.patch ... Passed
    steam.patch ... Passed
    wbemprox_query_v2.patch ... Passed
==> Extracting sources...
  -> Extracting staging-1.9.22.tar.gz with bsdtar
  -> Extracting wine-d3d9-1.9.22.tar.gz with bsdtar
==> Starting prepare()...
patching file dlls/ntdll/loadorder.c
patching file programs/winecfg/resource.h
patching file programs/winecfg/staging.c
patching file programs/winecfg/winecfg.rc
patching file configure
patching file configure.ac
The next patch would create the file dlls/d3d9-nine/Makefile.in,
which already exists!  Assume -R? [n] n
Apply anyway? [n] n
Skipping patch.
1 out of 1 hunk ignored
The next patch would create the file dlls/d3d9-nine/d3d9-nine.spec,
which already exists!  Assume -R? [n] n
Apply anyway? [n] n
Skipping patch.
1 out of 1 hunk ignored
[…SNIPPED A BUNCH OF IDENTICAL "no-no" LINES…]
The next patch would create the file dlls/d3d9-nine/wndproc.h,
which already exists!  Assume -R? [n] n
Apply anyway? [n] n
Skipping patch.
1 out of 1 hunk ignored
patching file dlls/winex11.drv/init.c
patching file dlls/winex11.drv/x11drv.h
patching file include/config.h.in
==> ERROR: A failure occurred in prepare().
    Aborting...

So, how would I go about rerunning makepkg?

Last edited by Hi-Angel (2016-11-09 17:34:57)

Offline

#2 2016-11-09 15:45:12

Alad
Wiki Admin/IRC Op
From: Bagelstan
Registered: 2014-05-04
Posts: 2,412
Website

Re: [SOLVED] How to rerun makepkg without removing the source?

man makepkg | less -p noextract

Mods are just community members who have the occasionally necessary option to move threads around and edit posts. -- Trilby

Offline

#3 2016-11-09 16:04:29

Hi-Angel
Member
Registered: 2016-07-16
Posts: 43

Re: [SOLVED] How to rerun makepkg without removing the source?

Alad wrote:
man makepkg | less -p noextract

Thank you. Unfortunately now it says

$ makepkg -e                                                                             130 ↵
==> Making package: wine-gaming-nine 1.9.22-1 (Wed Nov  9 18:54:43 MSK 2016)
==> Checking runtime dependencies...
==> Checking buildtime dependencies...
==> WARNING: Using existing $srcdir/ tree
==> Removing existing $pkgdir/ directory...
==> Starting build()...
  -> Building Wine-64...
mkdir: cannot create directory ‘wine-gaming-nine-64-build’: File exists
==> ERROR: A failure occurred in build().
    Aborting...

I could probably just remove the dir, but — I checked with find'n'grep — it (and one for 32-bit arch) contains all of the object files, so a lot of purpose of rerunning makepkg goes unused, it would not continue the build.

Offline

#4 2016-11-09 16:40:16

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 29,523
Website

Re: [SOLVED] How to rerun makepkg without removing the source?

Report that to the AUR maintainer, they are using mkdir in build().  They should either put the mkdir in prepare() or use `mkdir -p` (or both!).  Or if necessary, the may need to remove any existing build directory before (re)creating it if old files could conflict with the new build.


"UNIX is simple and coherent..." - Dennis Ritchie, "GNU's Not UNIX" -  Richard Stallman

Offline

#5 2016-11-09 17:34:41

Hi-Angel
Member
Registered: 2016-07-16
Posts: 43

Re: [SOLVED] How to rerun makepkg without removing the source?

Ah, okay, thank you. Then, I guess, I can mark the topic as solved.

Offline

Board footer

Powered by FluxBB