i've created a custom macro file, packaged as a COPR pkg ( 
pgfed/pgnd-rpmbuild-macros ), for reference/(re)use in my _other_ COPR builds.  
it contains a macro def'n, "%_pgnd_macros"

if I install the pkg locally,

        rpm -ql pgnd-rpmbuild-macros
                /usr/lib/rpm/macros.d
                /usr/lib/rpm/macros.d/macros.pgnd-rpmbuild

and reference it in a test.spec

        cat test.spec

                %{_pgnd_macros}

                Name:              test
                Release:           %{dist}
                Summary:           test
                License:           MIT
                Version:           1
                BuildArch: noarch

                %description
                ...

any/all of its macro defs/expansions are available, as intended, and can be 
used throughout the build.
same for local mock builds.

next, to get my COPR builds to use it, @ COPR: Home >> pgfed >> [project] >> 
Settings >> Project Details 

, i've set:

        External Repositories: 
copr://pgfed/pgnd-rpmbuild-macros/fedora-$releasever-$basearch/

and, for the specific buildroot, @ COPR: Home >> pgfed >> [project] >> Edit >> 
fedora-32-x86_64 

, i've set:

        Packages: git coreutils rpm pgnd-rpmbuild-macros

once save, @ the project Overview,

        External Repository List
        The following repositories are accessible during builds
            copr://pgfed/pgnd-rpmbuild-macros/fedora-$releasever-$basearch/

On build exec @ COPR, the build fails

        ...
        stderr: error: line 1: Unknown tag: %{_pgnd_macros}
        can't parse specfile

here's a specific example,

        https://copr.fedorainfracloud.org/coprs/pgfed/redis-6/build/1601289/
        
https://download.copr.fedorainfracloud.org/results/pgfed/redis-6/srpm-builds/01601289/builder-live.log.gz

what additional/changed config is required to get my 'other' COPR builds to 
correctly include/use my DIY-macros?
_______________________________________________
buildsys mailing list -- buildsys@lists.fedoraproject.org
To unsubscribe send an email to buildsys-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/buildsys@lists.fedoraproject.org

Reply via email to