Mock Version: 2.8 Mock Version: 2.8 Mock Version: 2.8 ENTER ['do_with_status'](['bash', '--login', '-c', '/usr/bin/rpmbuild -bs --target x86_64 --nodeps /builddir/build/SPECS/logrotate.spec'], chrootPath='/var/lib/mock/dist-an23-build-156223-58313/root'env={'TERM': 'vt100', 'SHELL': '/bin/bash', 'HOME': '/builddir', 'HOSTNAME': 'mock', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'PROMPT_COMMAND': 'printf "\\033]0;\\007"', 'PS1': ' \\s-\\v\\$ ', 'LANG': 'C.UTF-8'}shell=Falselogger=timeout=86400uid=989gid=135user='mockbuild'nspawn_args=[]unshare_net=TrueprintOutput=False) Executing command: ['bash', '--login', '-c', '/usr/bin/rpmbuild -bs --target x86_64 --nodeps /builddir/build/SPECS/logrotate.spec'] with env {'TERM': 'vt100', 'SHELL': '/bin/bash', 'HOME': '/builddir', 'HOSTNAME': 'mock', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'PROMPT_COMMAND': 'printf "\\033]0;\\007"', 'PS1': ' \\s-\\v\\$ ', 'LANG': 'C.UTF-8'} and shell False Building target platforms: x86_64 Building for target x86_64 setting SOURCE_DATE_EPOCH=1565136000 Wrote: /builddir/build/SRPMS/logrotate-3.8.6-19.an23.src.rpm Child return code was: 0 ENTER ['do_with_status'](['bash', '--login', '-c', '/usr/bin/rpmbuild -bb --target x86_64 --nodeps /builddir/build/SPECS/logrotate.spec'], chrootPath='/var/lib/mock/dist-an23-build-156223-58313/root'env={'TERM': 'vt100', 'SHELL': '/bin/bash', 'HOME': '/builddir', 'HOSTNAME': 'mock', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'PROMPT_COMMAND': 'printf "\\033]0;\\007"', 'PS1': ' \\s-\\v\\$ ', 'LANG': 'C.UTF-8'}shell=Falselogger=timeout=86400uid=989gid=135user='mockbuild'nspawn_args=[]unshare_net=TrueprintOutput=False) Executing command: ['bash', '--login', '-c', '/usr/bin/rpmbuild -bb --target x86_64 --nodeps /builddir/build/SPECS/logrotate.spec'] with env {'TERM': 'vt100', 'SHELL': '/bin/bash', 'HOME': '/builddir', 'HOSTNAME': 'mock', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'PROMPT_COMMAND': 'printf "\\033]0;\\007"', 'PS1': ' \\s-\\v\\$ ', 'LANG': 'C.UTF-8'} and shell False Building target platforms: x86_64 Building for target x86_64 setting SOURCE_DATE_EPOCH=1565136000 Executing(%prep): /bin/sh -e /var/tmp/rpm-tmp.JH901R + umask 022 + cd /builddir/build/BUILD + cd /builddir/build/BUILD + rm -rf logrotate-3.8.6 + /usr/lib/rpm/rpmuncompress -x /builddir/build/SOURCES/logrotate-3.8.6.tar.gz + STATUS=0 + '[' 0 -ne 0 ']' + cd logrotate-3.8.6 + /usr/bin/chmod -Rf a+rX,u+w,g-w,o-w . + echo 'Patch #0 (logrotate-3.8.6-force.patch):' Patch #0 (logrotate-3.8.6-force.patch): + /usr/bin/patch --no-backup-if-mismatch -f -p1 -b --suffix .force --fuzz=0 (Stripping trailing CRs from patch; use --binary to disable.) patching file logrotate.c (Stripping trailing CRs from patch; use --binary to disable.) patching file test/test (Stripping trailing CRs from patch; use --binary to disable.) patching file test/test-config.53.in + echo 'Patch #1 (logrotate-3.8.6-r465.patch):' Patch #1 (logrotate-3.8.6-r465.patch): + /usr/bin/patch --no-backup-if-mismatch -f -p1 -b --suffix .r465 --fuzz=0 (Stripping trailing CRs from patch; use --binary to disable.) patching file logrotate.8 Patch #2 (logrotate-3.8.6-sortglob.patch): + echo 'Patch #2 (logrotate-3.8.6-sortglob.patch):' + /usr/bin/patch --no-backup-if-mismatch -f -p1 -b --suffix .sortglob --fuzz=0 patching file logrotate.c patching file test/test patching file test/test-config.54.in patching file test/test-config.55.in patching file test/test-config.56.in Patch #3 (logrotate-3.8.6-r460.patch): + echo 'Patch #3 (logrotate-3.8.6-r460.patch):' + /usr/bin/patch --no-backup-if-mismatch -f -p1 -b --suffix .r460 --fuzz=0 patching file config.c patching file logrotate.8 patching file logrotate.h patching file test/test patching file test/test-config.13.in + echo 'Patch #4 (logrotate-3.8.6-compress-subject.patch):' Patch #4 (logrotate-3.8.6-compress-subject.patch): + /usr/bin/patch --no-backup-if-mismatch -f -p1 -b --suffix .compressmail --fuzz=0 patching file logrotate.c patching file test/test patching file test/test-config.64.in patching file test/test-config.65.in Patch #5 (logrotate-3.8.6-olddircopy.patch): + echo 'Patch #5 (logrotate-3.8.6-olddircopy.patch):' + /usr/bin/patch --no-backup-if-mismatch -f -p1 -b --suffix .olddircopy --fuzz=0 patching file config.c Patch #6 (logrotate-3.8.6-state-clean.patch): + echo 'Patch #6 (logrotate-3.8.6-state-clean.patch):' + /usr/bin/patch --no-backup-if-mismatch -f -p1 -b --suffix .stateclean --fuzz=0 patching file logrotate.c patching file test/test patching file test/test-config.67.in patching file test/test-config.68.in Patch #7 (logrotate-3.8.6-statusfile.patch): + echo 'Patch #7 (logrotate-3.8.6-statusfile.patch):' + /usr/bin/patch --no-backup-if-mismatch -f -p1 --fuzz=0 patching file config.h patching file examples/logrotate.cron patching file logrotate.8 + echo 'Patch #9 (logrotate-3.8.6-diagnostic.patch):' Patch #9 (logrotate-3.8.6-diagnostic.patch): + /usr/bin/patch --no-backup-if-mismatch -f -p1 --fuzz=0 patching file logrotate.8 Hunk #1 succeeded at 239 (offset 1 line). patching file logrotate.c patching file test/test patching file test/test-config.61.in patching file logrotate.c patching file logrotate.c patching file log.c patching file log.h patching file logrotate.c patching file test/test patching file logrotate.c patching file logrotate.c patching file logrotate.c Patch #10 (logrotate-3.8.6-olddir-missingok.patch): + echo 'Patch #10 (logrotate-3.8.6-olddir-missingok.patch):' + /usr/bin/patch --no-backup-if-mismatch -f -p1 --fuzz=0 patching file config.c patching file test/test patching file test/test-config.69.in Patch #11 (logrotate-3.8.6-longdate-crash.patch): + echo 'Patch #11 (logrotate-3.8.6-longdate-crash.patch):' + /usr/bin/patch --no-backup-if-mismatch -f -p1 --fuzz=0 patching file logrotate.c Patch #12 (logrotate-3.8.6-createolddir.patch): + echo 'Patch #12 (logrotate-3.8.6-createolddir.patch):' + /usr/bin/patch --no-backup-if-mismatch -f -p1 --fuzz=0 patching file config.c patching file config.c Patch #13 (logrotate-3.8.6-selinux.patch): + echo 'Patch #13 (logrotate-3.8.6-selinux.patch):' + /usr/bin/patch --no-backup-if-mismatch -f -p1 --fuzz=0 patching file logrotate.c patching file logrotate.c + echo 'Patch #14 (logrotate-3.8.6-su-username.patch):' Patch #14 (logrotate-3.8.6-su-username.patch): + /usr/bin/patch --no-backup-if-mismatch -f -p1 --fuzz=0 patching file config.c Patch #15 (logrotate-3.8.6-copy-and-copytruncate.patch): + echo 'Patch #15 (logrotate-3.8.6-copy-and-copytruncate.patch):' + /usr/bin/patch --no-backup-if-mismatch -f -p1 --fuzz=0 patching file logrotate.c patching file test/test patching file test/test-config.73.in Patch #16 (logrotate-3.8.6-weekly.patch): + echo 'Patch #16 (logrotate-3.8.6-weekly.patch):' + /usr/bin/patch --no-backup-if-mismatch -f -p1 --fuzz=0 patching file config.c patching file logrotate.8 patching file logrotate.c patching file logrotate.h Patch #17 (logrotate-3.8.6-config-mode-err.patch): + echo 'Patch #17 (logrotate-3.8.6-config-mode-err.patch):' + /usr/bin/patch --no-backup-if-mismatch -f -p1 --fuzz=0 patching file config.c Patch #18 (logrotate-3.8.6-upstream-url.patch): + echo 'Patch #18 (logrotate-3.8.6-upstream-url.patch):' + /usr/bin/patch --no-backup-if-mismatch -f -p1 --fuzz=0 patching file logrotate.8 Patch #19 (logrotate-3.8.6-monthly-dst.patch): + echo 'Patch #19 (logrotate-3.8.6-monthly-dst.patch):' + /usr/bin/patch --no-backup-if-mismatch -f -p1 --fuzz=0 patching file logrotate.8 patching file logrotate.c Patch #20 (logrotate-3.8.6-unlink-on-failure.patch): + echo 'Patch #20 (logrotate-3.8.6-unlink-on-failure.patch):' + /usr/bin/patch --no-backup-if-mismatch -f -p1 --fuzz=0 patching file logrotate.c Patch #21 (logrotate-3.8.6-rename-existing.patch): + echo 'Patch #21 (logrotate-3.8.6-rename-existing.patch):' + /usr/bin/patch --no-backup-if-mismatch -f -p1 --fuzz=0 patching file logrotate.c patching file test/test patching file test/test-config.72.in patching file logrotate.c patching file logrotate.c + echo 'Patch #22 (logrotate-3.8.6-config-error.patch):' Patch #22 (logrotate-3.8.6-config-error.patch): + /usr/bin/patch --no-backup-if-mismatch -f -p1 --fuzz=0 patching file config.c patching file config.c patching file config.c patching file logrotate.c + RPM_EC=0 ++ jobs -p + exit 0 Executing(%build): /bin/sh -e /var/tmp/rpm-tmp.jaj8Rf + umask 022 + cd /builddir/build/BUILD + CFLAGS='-O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/anolis/anolis-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/anolis/anolis-annobin-cc1 -m64 -march=x86-64-v2 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection' + export CFLAGS + CXXFLAGS='-O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/anolis/anolis-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/anolis/anolis-annobin-cc1 -m64 -march=x86-64-v2 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection' + export CXXFLAGS + FFLAGS='-O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/anolis/anolis-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/anolis/anolis-annobin-cc1 -m64 -march=x86-64-v2 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -I/usr/lib64/gfortran/modules' + export FFLAGS + FCFLAGS='-O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/anolis/anolis-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/anolis/anolis-annobin-cc1 -m64 -march=x86-64-v2 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -I/usr/lib64/gfortran/modules' + export FCFLAGS + LDFLAGS='-Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/anolis/anolis-hardened-ld -specs=/usr/lib/rpm/anolis/anolis-annobin-cc1 -Wl,--build-id=sha1 ' + export LDFLAGS + LT_SYS_LIBRARY_PATH=/usr/lib64: + export LT_SYS_LIBRARY_PATH + CC=gcc + export CC + CXX=g++ + export CXX + cd logrotate-3.8.6 + make -j64 'RPM_OPT_FLAGS=-O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/anolis/anolis-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/anolis/anolis-annobin-cc1 -m64 -march=x86-64-v2 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection' WITH_SELINUX=yes WITH_ACL=yes gcc -E -Wall -D_GNU_SOURCE -DLinux -DVERSION=\"3.8.6\" -O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/anolis/anolis-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/anolis/anolis-annobin-cc1 -m64 -march=x86-64-v2 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -DWITH_SELINUX -DWITH_ACL -M logrotate.c log.c config.c basenames.c > .depend gcc -Wall -D_GNU_SOURCE -DLinux -DVERSION=\"3.8.6\" -O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/anolis/anolis-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/anolis/anolis-annobin-cc1 -m64 -march=x86-64-v2 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -DWITH_SELINUX -DWITH_ACL -c -o logrotate.o logrotate.c gcc -Wall -D_GNU_SOURCE -DLinux -DVERSION=\"3.8.6\" -O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/anolis/anolis-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/anolis/anolis-annobin-cc1 -m64 -march=x86-64-v2 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -DWITH_SELINUX -DWITH_ACL -c -o log.o log.c gcc -Wall -D_GNU_SOURCE -DLinux -DVERSION=\"3.8.6\" -O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/anolis/anolis-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/anolis/anolis-annobin-cc1 -m64 -march=x86-64-v2 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -DWITH_SELINUX -DWITH_ACL -c -o config.o config.c gcc -Wall -D_GNU_SOURCE -DLinux -DVERSION=\"3.8.6\" -O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/anolis/anolis-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/anolis/anolis-annobin-cc1 -m64 -march=x86-64-v2 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -DWITH_SELINUX -DWITH_ACL -c -o basenames.o basenames.c echo "1" > ./test/test.ACL ; echo "1" > ./test/test.SELINUX ; logrotate.c:30:1: warning: 'security_context_t' is deprecated [-Wdeprecated-declarations] 30 | static security_context_t prev_context = NULL; | ^~~~~~ logrotate.c: In function 'setSecCtx': logrotate.c:257:5: warning: 'security_context_t' is deprecated [-Wdeprecated-declarations] 257 | security_context_t srcCtx; | ^~~~~~~~~~~~~~~~~~ logrotate.c:276:5: warning: 'security_context_t' is deprecated [-Wdeprecated-declarations] 276 | if (getfscreatecon_raw((security_context_t *)pPrevCtx) < 0) { | ^~ logrotate.c: In function 'restoreSecCtx': logrotate.c:302:5: warning: 'security_context_t' is deprecated [-Wdeprecated-declarations] 302 | const security_context_t prevCtx = (security_context_t) *pPrevCtx; | ^~~~~ logrotate.c:302:5: warning: 'security_context_t' is deprecated [-Wdeprecated-declarations] logrotate.c: In function 'prerotateSingleLog': logrotate.c:1243:13: warning: 'security_context_t' is deprecated [-Wdeprecated-declarations] 1243 | security_context_t oldContext = NULL; | ^~~~~~~~~~~~~~~~~~ logrotate.c: In function 'rotateSingleLog': logrotate.c:1513:9: warning: 'security_context_t' is deprecated [-Wdeprecated-declarations] 1513 | security_context_t savedContext = NULL; | ^~~~~~~~~~~~~~~~~~ logrotate.c:1524:25: warning: 'security_context_t' is deprecated [-Wdeprecated-declarations] 1524 | security_context_t oldContext = NULL; | ^~~~~~~~~~~~~~~~~~ logrotate.c: In function 'writeState': logrotate.c:1990:13: warning: 'security_context_t' is deprecated [-Wdeprecated-declarations] 1990 | security_context_t oldContext; | ^~~~~~~~~~~~~~~~~~ config.c: In function 'strndup': config.c:87:10: warning: 'nonnull' argument 's' compared to NULL [-Wnonnull-compare] 87 | if(!s) | ^ logrotate.c: In function 'prerotateSingleLog': logrotate.c:1142:9: warning: 'strncat' specified bound depends on the length of the source argument [-Wstringop-overflow=] 1142 | strncat(tempstr, rotNames->baseName, | ^ logrotate.c:1143:17: note: length computed here 1143 | strlen(rotNames->baseName) - strlen(log->extension)); | ^~~~~~~~~~~~~~~~~~~~~~~~~~ gcc -Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/anolis/anolis-hardened-ld -specs=/usr/lib/rpm/anolis/anolis-annobin-cc1 -Wl,--build-id=sha1 logrotate.o log.o config.o basenames.o -lpopt -lselinux -lacl -o logrotate /usr/bin/ld: config.o (symbol from plugin): in function `logs': (.text+0x0): multiple definition of `logs'; logrotate.o (symbol from plugin):(.text+0x0): first defined here logrotate.c: In function 'main': logrotate.c:1142:9: warning: '__builtin_strncat' specified bound depends on the length of the source argument [-Wstringop-overflow=] 1142 | strncat(tempstr, rotNames->baseName, | ^ In function 'prerotateSingleLog', inlined from 'rotateLogSet' at logrotate.c:1838:3, inlined from 'main' at logrotate.c:2434:9: logrotate.c:1143:17: note: length computed here 1143 | strlen(rotNames->baseName) - strlen(log->extension)); | ^ collect2: error: ld returned 1 exit status make: *** [: logrotate] Error 1 error: Bad exit status from /var/tmp/rpm-tmp.jaj8Rf (%build) RPM build errors: Bad exit status from /var/tmp/rpm-tmp.jaj8Rf (%build) Child return code was: 1 EXCEPTION: [Error()] Traceback (most recent call last): File "/usr/lib/python3.6/site-packages/mockbuild/trace_decorator.py", line 93, in trace result = func(*args, **kw) File "/usr/lib/python3.6/site-packages/mockbuild/util.py", line 600, in do_with_status raise exception.Error("Command failed: \n # %s\n%s" % (command, output), child.returncode) mockbuild.exception.Error: Command failed: # bash --login -c /usr/bin/rpmbuild -bb --target x86_64 --nodeps /builddir/build/SPECS/logrotate.spec