Description of problem: ENTER ['do'](['bash', '--login', '-c', '/usr/bin/rpmbuild -bb --target noarch --nodeps /builddir/build/SPECS/octave-statistics.spec'], logger=<mockbuild.trace_decorator.getLog object at 0x3fff945826d8>timeout=172800user='mockbuild'printOutput=Falseenv={'SHELL': '/bin/bash', 'HOME': '/builddir', 'PROMPT_COMMAND': 'printf "\\033]0;<mock-chroot>\\007"', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'LANG': 'en_US.UTF-8', 'TERM': 'vt100', 'PS1': '<mock-chroot> \\s-\\v\\$ ', 'HOSTNAME': 'mock'}gid=425uid=1000shell=FalsechrootPath='/var/lib/mock/f27-build-9511079-776071/root'nspawn_args=[]) Executing command: ['bash', '--login', '-c', '/usr/bin/rpmbuild -bb --target noarch --nodeps /builddir/build/SPECS/octave-statistics.spec'] with env {'SHELL': '/bin/bash', 'HOME': '/builddir', 'PROMPT_COMMAND': 'printf "\\033]0;<mock-chroot>\\007"', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'LANG': 'en_US.UTF-8', 'TERM': 'vt100', 'PS1': '<mock-chroot> \\s-\\v\\$ ', 'HOSTNAME': 'mock'} and shell False octave_cmd: invalid option -- 'n' error: Unknown option n in octave_cmd() error: line 31: %octave_pkg_install %install %octave_pkg_install %octave_pkg_install \ mkdir -p %{buildroot}%{octprefix} \ mkdir -p %{buildroot}%{octarchprefix} \ %octave_cmd pkg("prefix","%{buildroot}%{octprefix}","%{buildroot}%{octarchprefix}");pkg("global_list",fullfile("%{buildroot}%{octshareprefix}","octave_packages"));pkg("local_list",fullfile("%{buildroot}%{octshareprefix}","octave_packages"));pkg("install","-nodeps","-verbose","%{_builddir}/%{buildsubdir}/build/%{octpkg}-%{version}-%{octave_tar_suffix}.tar.gz");unlink(pkg("local_list"));unlink(pkg("global_list")); \ if [ -e %{buildroot}%{octpkgdir}/packinfo/on_uninstall.m ] \ then \ mv %{buildroot}%{octpkgdir}/packinfo/on_uninstall.m %{buildroot}%{octpkgdir}/packinfo/on_uninstall.m.orig \ fi \ echo "function on_uninstall (desc)" > %{buildroot}%{octpkgdir}/packinfo/on_uninstall.m \ echo " error ('Can not uninstall %s installed by the redhat package manager', desc.name);" >> %{buildroot}%{octpkgdir}/packinfo/on_uninstall.m \ echo "endfunction" >> %{buildroot}%{octpkgdir}/packinfo/on_uninstall.m \ if [ -e %{_builddir}/%{buildsubdir}/build/%{octpkg}-%{version}/octave-%{octpkg}.metainfo.xml ] \ then \ echo "Found octave-%{octpkg}.metainfo.xml" \ mkdir -p %{buildroot}/%{_datadir}/appdata \ cp -p %{_builddir}/%{buildsubdir}/build/%{octpkg}-%{version}/octave-%{octpkg}.metainfo.xml %{buildroot}/%{_datadir}/appdata/ \ appstream-util validate-relax --nonet %{buildroot}/%{_datadir}/appdata/octave-%{octpkg}.metainfo.xml \ fi \ %{nil} %octave_cmd() octave -H -q --no-window-system --no-site-file --eval '%*'; Version-Release number of selected component (if applicable): 4.13.90-0.git14002.2.fc27
Yup. The problem is the new macro argument quoting support, which cannot be turned off or escaped otherwise. After sleeping over this, starting to remember various other macro constructs that are going to be affected... and as if on cue, in comes bug 1481133. It's fairly clear that the behavior is just too incompatible with widely used macros, it needs a different syntax or some kind of opt-in behavior.
*** Bug 1481133 has been marked as a duplicate of this bug. ***
Macro argument quoting is now disabled in rpm >= 4.13.90-0.git14002.3.fc27. Back to the drawing board upstream (https://github.com/rpm-software-management/rpm/issues/222)
I guess the rubygem-sdoc build failure [1] is of the same nature, so probably other rubygem- packages are broken now as well ... [1] https://apps.fedoraproject.org/koschei/package/rubygem-sdoc?collection=f27
And svnmailer, where it doesn't like: %py2_install "--install-data=%{_datadir}" https://apps.fedoraproject.org/koschei/package/svnmailer?collection=f27
This bug appears to have been reported against 'rawhide' during the Fedora 27 development cycle. Changing version to '27'.
To summarize, the single/double quoting support of macro arguments was reverted as it simply broke too much stuff. Rpm 4.14.0 rc1 and newer support an alternative way of quoting macro arguments: a new special-purpose %{quote:...} macro, which allows passing empty arguments and arguments with spaces as single arguments. For example, with the following parametric macro definition: %args() echo argc %#: %{?1:"%1"} %{?2:"%2"} [pmatilai@sopuli ~]$ rpm --eval "%args %{nil}" argc 0: [pmatilai@sopuli ~]$ rpm --eval "%args %{quote:%{nil}}" argc 1: "" [pmatilai@sopuli ~]$ rpm --eval "%args some text" argc 2: "some" "text" [pmatilai@sopuli ~]$ rpm --eval "%args %{quote:some text}" argc 1: "some text"