Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fedora 28: Macro %_dracutdir has empty body #7326

Closed
tonyhutter opened this issue Mar 21, 2018 · 1 comment · Fixed by #7328
Closed

Fedora 28: Macro %_dracutdir has empty body #7326

tonyhutter opened this issue Mar 21, 2018 · 1 comment · Fixed by #7328
Assignees

Comments

@tonyhutter
Copy link
Contributor

tonyhutter commented Mar 21, 2018

System information

Type Version/Name
Distribution Name Fedora
Distribution Version 28 rawhide
Linux Kernel
Architecture x86-64
ZFS Version master
SPL Version master

Describe the problem you're observing

I'm unable to build pkg-utils on rawhide with --with-config=srpm:

$ ./autogen.sh && ./configure --with-config=srpm && make pkg-utils
make[3]: Entering directory '/home/hutter/fedora28'
sed -i 's/Release:[[:print:]]*/Release:      379_g272b5d730/' \
	zfs-0.7.0/META
make[3]: Leaving directory '/home/hutter/fedora28'
test -n "" \
|| find "zfs-0.7.0" -type d ! -perm -755 \
	-exec chmod u+rwx,go+rx {} \; -o \
  ! -type d ! -perm -444 -links 1 -exec chmod a+r {} \; -o \
  ! -type d ! -perm -400 -exec chmod a+r {} \; -o \
  ! -type d ! -perm -444 -exec /bin/sh /home/hutter/fedora28/config/install-sh -c -m a+r {} {} \; \
|| chmod -R a+r "zfs-0.7.0"
tardir=zfs-0.7.0 && ${TAR-tar} chof - "$tardir" | eval GZIP= gzip --best -c >zfs-0.7.0.tar.gz
make[2]: Leaving directory '/home/hutter/fedora28'
if test -d "zfs-0.7.0"; then find "zfs-0.7.0" -type d ! -perm -200 -exec chmod u+w {} ';' && rm -rf "zfs-0.7.0" || { sleep 5 && rm -rf "zfs-0.7.0"; }; else :; fi
make[2]: Entering directory '/home/hutter/fedora28'
make[2]: Leaving directory '/home/hutter/fedora28'
Wrote: /tmp/zfs-build-hutter-t97qZumm/SRPMS/zfs-0.7.0-379_g272b5d730.fc28.src.rpm
make[1]: Leaving directory '/home/hutter/fedora28'
make  pkg="zfs" \
	def='--define "_without_debug 1" --define "_without_debuginfo 1" --define "_without_asan 1" --define "_dracutdir " --define "_udevdir " --define "_udevruledir " --define "_initconfdir /etc/sysconfig"  ' rpm-common
make[1]: Entering directory '/home/hutter/fedora28'
make[2]: Entering directory '/home/hutter/fedora28'
make[2]: Leaving directory '/home/hutter/fedora28'
error: Macro %_dracutdir has empty body
make[1]: *** [Makefile:1226: rpm-common] Error 1
make[1]: Leaving directory '/home/hutter/fedora28'
make: *** [Makefile:1185: rpm-utils] Error 2

Describe how to reproduce the problem

./autogen.sh && ./configure --with-config=srpm && make pkg-utils

Include any warning/errors/backtraces from the system logs

@tonyhutter
Copy link
Contributor Author

This looks to be caused by ZFS_AC_CONFIG_USER not being run for SRPM configs.

        case "$ZFS_CONFIG" in
                kernel) ZFS_AC_CONFIG_KERNEL ;;
                user)   ZFS_AC_CONFIG_USER   ;;
                all)    ZFS_AC_CONFIG_USER
                        ZFS_AC_CONFIG_KERNEL ;;
                srpm)                        ;;
                *)
                AC_MSG_RESULT([Error!])
                AC_MSG_ERROR([Bad value "$ZFS_CONFIG" for --with-config,
                              user kernel|user|all|srpm]) ;;
        esac

ZFS_AC_CONFIG_USER sets _dracutdir via ZFS_AC_CONFIG_USER_DRACUT.

@tonyhutter tonyhutter self-assigned this Mar 21, 2018
tonyhutter added a commit to tonyhutter/zfs that referenced this issue Mar 21, 2018
If you run ./configure --with-config=srpm, it will not trigger
the user m4 scripts to populate the dracut and udev directories.
This causes a build error on Fedora 28.  Make the dracut and
udev lines conditional to get around this.

Signed-off-by: Tony Hutter <hutter2@llnl.gov>
Closes: openzfs#7326
tonyhutter added a commit to tonyhutter/zfs that referenced this issue Mar 23, 2018
If you run ./configure --with-config=srpm, it will not trigger
the user m4 scripts to populate the dracut and udev directories.
This causes a build error on Fedora 28.  Make the dracut and
udev lines conditional to get around this.

Signed-off-by: Tony Hutter <hutter2@llnl.gov>
Closes: openzfs#7326
behlendorf pushed a commit that referenced this issue Mar 25, 2018
If you run ./configure --with-config=srpm, it will not trigger
the user m4 scripts to populate the dracut and udev directories.
This causes a build error on Fedora 28.  Make the dracut and
udev lines conditional to get around this.

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Tony Hutter <hutter2@llnl.gov>
Closes #7326
Closes #7328
tonyhutter added a commit to tonyhutter/zfs that referenced this issue Mar 28, 2018
If you run ./configure --with-config=srpm, it will not trigger
the user m4 scripts to populate the dracut and udev directories.
This causes a build error on Fedora 28.  Make the dracut and
udev lines conditional to get around this.

Signed-off-by: Tony Hutter <hutter2@llnl.gov>
Closes: openzfs#7326
tonyhutter added a commit to tonyhutter/zfs that referenced this issue Apr 16, 2018
If you run ./configure --with-config=srpm, it will not trigger
the user m4 scripts to populate the dracut and udev directories.
This causes a build error on Fedora 28.  Make the dracut and
udev lines conditional to get around this.

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Tony Hutter <hutter2@llnl.gov>
Closes openzfs#7326
Closes openzfs#7328
tonyhutter added a commit to tonyhutter/zfs that referenced this issue May 4, 2018
If you run ./configure --with-config=srpm, it will not trigger
the user m4 scripts to populate the dracut and udev directories.
This causes a build error on Fedora 28.  Make the dracut and
udev lines conditional to get around this.

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Tony Hutter <hutter2@llnl.gov>
Closes openzfs#7326
Closes openzfs#7328
tonyhutter added a commit that referenced this issue May 10, 2018
If you run ./configure --with-config=srpm, it will not trigger
the user m4 scripts to populate the dracut and udev directories.
This causes a build error on Fedora 28.  Make the dracut and
udev lines conditional to get around this.

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Tony Hutter <hutter2@llnl.gov>
Closes #7326
Closes #7328
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant