ACLOCAL_AMFLAGS=-I m4 arch_macrosfiles = $(RPMALLARCH:=.macros) pkg_gdata = \ macros \ rpmrc pkg_data_in = $(pkg_gdata:=.in) pkg_macrosd = macros.gnome pkg_macrosd_in = $(pkg_macrosd:=.in) pkg_gconfig = \ platform \ $(if $(CANONTARGETCPU32), platform32, ) pkg_scripts = \ devel.prov \ devel.req \ drop-ld-no-undefined-for-shared-lib-modules-in-libtool \ fix-dlsearch-path-in-libtool-for-multilib \ fix-libtool-from-moving-options-after-libs \ fix-libtool-ltmain-from-overlinking \ force-as-needed-for-shared-lib-in-libtool \ http.req \ multiarch.req \ perl_base.req \ perl.prov \ perl.req \ perl.req-from-meta \ php.prov \ php.req pkg_gscripts = \ find-provides \ find-requires pkg_scripts_in = $(pkg_gscripts:=.in) pkg_attr_defs = \ devel.attr \ multiarch.attr \ perl_base.attr \ perl_from_meta.attr \ php.attr redhat_scripts = \ brp-mangle-shebangs redhat_hardened = \ redhat-hardened-cc1 \ redhat-hardened-ld \ redhat-hardened-clang.cfg \ redhat-hardened-clang-ld.cfg BUILT_SOURCES = macros-perarch make_arch_macrosfiles.sh rpmgenplatform foobar_pkglibdir = @RPMVENDORDIR@ foobar_pkglibexecdir = @RPMVENDORDIR@ noinst_PROGRAMS = rpmeval rpmeval_SOURCES = rpmeval.c rpmeval_LDADD = -lrpmio -lrpm noinst_DATA = $(pkg_gconfig) foobar_pkglib_DATA = \ $(pkg_gdata) $(pkg_gconfig) foobar_pkglib_SCRIPTS = \ $(pkg_scripts) \ $(pkg_gscripts) EXTRA_DIST = \ $(pkg_data_in) \ $(pkg_macrosd_in) \ $(pkg_attr_defs) \ $(pkg_scripts) \ $(pkg_scripts_in) \ $(redhat_scripts) \ $(redhat_hardened) \ macros-perarch.in make_arch_macrosfiles.sh.in \ rpmgenplatform.in rpmrc.in \ rpm-spec-mode.el \ tests.sh tests/macros.sh edit = sed \ -e 's,@RPMVENDOR\@,$(RPMVENDOR),g' \ -e 's,@RPMVENDORDIR\@,$(RPMVENDORDIR),g' \ -e 's,@RPMCANONVENDOR\@,$(RPMCANONVENDOR),g' \ -e 's,@RPMLIBDIR\@,$(RPMLIBDIR),g' \ -e 's,@RPMSYSCONFDIR\@,$(RPMSYSCONFDIR),g'\ -e 's,@RPMOS\@,$(RPMOS),g' \ -e 's,@CANONTARGETCPU\@,$(CANONTARGETCPU),g' \ -e 's,@CANONTARGETGNU\@,$(CANONTARGETGNU),g' \ -e 's,@ARMV7CANONTARGETCPU\@,$(ARMV7CANONTARGETCPU),g' \ -e 's,@ARMV8CANONTARGETCPU\@,$(ARMV8CANONTARGETCPU),g' \ -e 's,@RPMALLARCH\@,$(RPMALLARCH),g' \ -e 's,@DISTSUFFIX\@,$(DISTSUFFIX),g' %: %.in Makefile $(edit) $< > $@ $(arch_macrosfiles): rpmrc macros-perarch make_arch_macrosfiles.sh arch=`echo $@ | sed 's,\\.macros,,'`; \ sh ./make_arch_macrosfiles.sh macros-perarch $$arch > $@ platform: rpmgenplatform Makefile perl rpmgenplatform $(CANONTARGETCPU) > $@ platform32: rpmgenplatform Makefile perl rpmgenplatform $(CANONTARGETCPU32) > $@ install-data-local: $(arch_macrosfiles) $(pkg_gconfig) $(pkg_macrosd) if ONLY_RPMRC echo "not installing per-arch macros which are already in rpmrc and standard rpm per-arch macros" else for i in $(RPMALLARCH); do \ $(mkinstalldirs) $(DESTDIR)$(RPMVENDORDIR)/platform/$${i}-$(RPMOS); \ $(install_sh_DATA) $${i}.macros $(DESTDIR)$(RPMVENDORDIR)/platform/$${i}-$(RPMOS)/macros; \ done endif [ -d $(DESTDIR)$(RPMSYSCONFDIR)/macros.d ] || $(mkinstalldirs) $(DESTDIR)$(RPMSYSCONFDIR)/macros.d for i in $(pkg_macrosd); do \ $(install_sh_DATA) $${i} $(DESTDIR)$(RPMLIBDIR)/macros.d/$${i}; \ done for i in $(pkg_attr_defs); do \ $(install_sh_DATA) $${i} $(DESTDIR)$(RPMLIBDIR)/fileattrs/$${i}; \ done for i in $(redhat_scripts); do \ $(install_sh_SCRIPT) $${i} $(DESTDIR)$(RPMLIBDIR)/redhat/$${i}; \ done for i in $(redhat_hardened); do \ $(install_sh_DATA) $${i} $(DESTDIR)$(RPMLIBDIR)/redhat/$${i}; \ done if RPMPLATFORM for i in $(pkg_gconfig); do \ $(install_sh_DATA) $${i} $(DESTDIR)$(RPMSYSCONFDIR)/$${i}; \ done $(install_sh_SCRIPT) rpmgenplatform $(DESTDIR)$(bindir)/rpmgenplatform endif .PHONY: test test: $(pkg_gdata) $(pkg_gscripts) $(arch_macrosfiles) $(pkg_gconfig) sh tests.sh CLEANFILES = $(pkg_gdata) $(pkg_gscripts) $(arch_macrosfiles) $(pkg_gconfig)\ macros-perarch $(pkg_macrosd) \ make_arch_macrosfiles.sh