[aur-general] Issue with proper packaging

Michael Kogan michael.kogan at gmx.net
Wed Feb 21 13:18:54 UTC 2018


I think, Konstantin refers to
https://aur.archlinux.org/cgit/aur.git/tree/PKGBUILD?h=simpletools

Konstantin, I think, you are missing the make command (at least I only see
cmake and make install commands. It should look something like

build() {
    mkdir -p "${srcdir}/${pkgname}/build"
    cd "${srcdir}/${pkgname}/build"
    msg2 'Configuring...'
    cmake -C "${srcdir}/settings.cmake" "${srcdir}/${pkgname}"
        make
}


package() {
    # make install target is lost if done in prepare() or build()
    # do everything here...
    install -d "${pkgdir}/usr/lib/"
    msg2 'Compiling & Installing...'
    make DESTDIR="${pkgdir}" install

   # further commands

}

I haven't tested it though, because root has a lot of dependencies.

2018-02-21 14:14 GMT+01:00 Bruno Pagani via aur-general <
aur-general at archlinux.org>:

> Le 21/02/2018 à 13:55, Konstantin Gizdov a écrit :
>
> > Hi,
> >
> > I'm having trouble making a package under the Arch Packaging Standards.
> The
> > package in question is `simpletools`.
> >
> > The problem I'm having is that if I use `prepare()` & `build()`
> directives
> > as intended, then the target `make install` does not exist when called
> from
> > inside `package()` directive. I'm wondering if this is an issue because
> of
> > the way `makepkg` pulls it over git and later handles it, or is it some
> > problem with the CMake configuration in the software itself?
> >
> > I haven't been able to replicate this in a manual way, because obviously
> > when run manually the configuration is persisted locally. Any comments?
> >
> > --
> > Regards,
> > Konstantin
>
> Can you provide the new PKGBUILD so we can see what is wrong? I guess
> the issue is you are not replacing makepkg at the right place in each
> function.
>
> Note that makepkg will indeed start in ${srcdir} at the beginning of
> each PKGBUILD functions (`prepare()`, `build()`, `package()`, `check()`).
>
> Regards,
> Bruno
>
>


More information about the aur-general mailing list