emacs-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[debbugs-tracker] bug#34054: closed (Error in compilation of pcresearch


From: GNU bug Tracking System
Subject: [debbugs-tracker] bug#34054: closed (Error in compilation of pcresearch if we have no pcre library)
Date: Sun, 20 Jan 2019 02:28:01 +0000

Your message dated Sat, 19 Jan 2019 18:27:02 -0800
with message-id <address@hidden>
and subject line Re: bug#34054: Error in compilation of pcresearch if we have 
no pcre library
has caused the debbugs.gnu.org bug report #34054,
regarding Error in compilation of pcresearch if we have no pcre library
to be marked as done.

(If you believe you have received this mail in error, please contact
address@hidden)


-- 
34054: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=34054
GNU Bug Tracking System
Contact address@hidden with problems
--- Begin Message --- Subject: Error in compilation of pcresearch if we have no pcre library Date: Sun, 13 Jan 2019 09:01:18 +0900
Hi,

I pulled current master of grep from git repository and built it on
fedora 29, and recieved following error.

When we have no pcre library, DIE() in Pcompile and Pexecute is called,
but noreturn attribute is set to their functions.

Thanks,
Norihiro


$ make
......
depbase=`echo pcresearch.o | sed 's|[^/]*$|.deps/&|;s|\.o$||'`;\
gcc -DHAVE_CONFIG_H -I. -I..  -I../lib -I../lib  -fno-common -W
-Waddress -Waggressive-loop-optimizations -Wall -Wattribute-alias
-Wattributes -Wbad-function-cast -Wbool-compare -Wbool-operation
-Wbuiltin-declaration-mismatch -Wbuiltin-macro-redefined -Wcast-align
-Wcast-align=strict -Wcast-function-type -Wchar-subscripts -Wclobbered
-Wcomment -Wcomments -Wcoverage-mismatch -Wcpp -Wdangling-else
-Wdate-time -Wdeprecated -Wdeprecated-declarations -Wdesignated-init
-Wdisabled-optimization -Wdiscarded-array-qualifiers -Wdiscarded-qualifiers
-Wdiv-by-zero -Wdouble-promotion -Wduplicated-branches -Wduplicated-cond
-Wduplicate-decl-specifier -Wempty-body -Wendif-labels -Wenum-compare
-Wexpansion-to-defined -Wextra -Wformat-contains-nul -Wformat-extra-args
-Wformat-nonliteral -Wformat-security -Wformat-signedness -Wformat-y2k
-Wformat-zero-length -Wframe-address -Wfree-nonheap-object -Whsa
-Wif-not-aligned -Wignored-attributes -Wignored-qualifiers -Wimplicit
-Wimplicit-function-declaration -Wimplicit-int -Wincompatible-pointer-types
-Winit-self -Wint-conversion -Wint-in-bool-context -Wint-to-pointer-cast
-Winvalid-memory-model -Winvalid-pch -Wlogical-not-parentheses
-Wlogical-op -Wmain -Wmaybe-uninitialized -Wmemset-elt-size 
-Wmemset-transposed-args
-Wmisleading-indentation -Wmissing-attributes -Wmissing-braces
-Wmissing-declarations -Wmissing-field-initializers -Wmissing-include-dirs
-Wmissing-parameter-type -Wmissing-prototypes -Wmultichar 
-Wmultistatement-macros
-Wnarrowing -Wnested-externs -Wnonnull -Wnonnull-compare -Wnull-dereference
-Wodr -Wold-style-declaration -Wold-style-definition -Wopenmp-simd
-Woverflow -Woverlength-strings -Woverride-init -Wpacked 
-Wpacked-bitfield-compat
-Wpacked-not-aligned -Wparentheses -Wpointer-arith -Wpointer-compare
-Wpointer-sign -Wpointer-to-int-cast -Wpragmas -Wpsabi -Wrestrict
-Wreturn-local-addr -Wreturn-type -Wscalar-storage-order -Wsequence-point
-Wshadow -Wshift-count-negative -Wshift-count-overflow -Wshift-negative-value
-Wsizeof-array-argument -Wsizeof-pointer-div -Wsizeof-pointer-memaccess
-Wstrict-aliasing -Wstrict-prototypes -Wstringop-truncation 
-Wsuggest-attribute=cold
-Wsuggest-attribute=const -Wsuggest-attribute=format -Wsuggest-attribute=malloc
-Wsuggest-attribute=noreturn -Wsuggest-attribute=pure -Wsuggest-final-methods
-Wsuggest-final-types -Wswitch -Wswitch-bool -Wswitch-unreachable
-Wsync-nand -Wtautological-compare -Wtrampolines -Wtrigraphs -Wtype-limits
-Wuninitialized -Wunknown-pragmas -Wunused -Wunused-but-set-parameter
-Wunused-but-set-variable -Wunused-function -Wunused-label 
-Wunused-local-typedefs
-Wunused-macros -Wunused-parameter -Wunused-result -Wunused-value
-Wunused-variable -Wvarargs -Wvariadic-macros -Wvector-operation-performance
-Wvolatile-register-var -Wwrite-strings 
-Walloc-size-larger-than=9223372036854775807
-Warray-bounds=2 -Wformat-overflow=2 -Wformat-truncation=2 
-Wimplicit-fallthrough=5
-Wnormalized=nfc -Wshift-overflow=2 -Wstringop-overflow=2 
-Wunused-const-variable=2
-Wvla-larger-than=4031 -Wno-missing-field-initializers -Wno-sign-compare
-Wno-unused-parameter -Wno-cast-function-type -Wno-logical-op
-Wno-format-nonliteral -Werror  -g -O2 -MT pcresearch.o -MD -MP -MF
$depbase.Tpo -c -o pcresearch.o pcresearch.c &&\ mv -f $depbase.Tpo
$depbase.Po

pcresearch.c: In function 'Pcompile':
pcresearch.c:114:1: error: function might be candidate for attribute
'noreturn' [-Werror=suggest-attribute=noreturn]
 Pcompile (char *pattern, size_t size, reg_syntax_t ignored)
 ^~~~~~~~
pcresearch.c: In function 'Pexecute':
pcresearch.c:209:1: error: function might be candidate for attribute
'noreturn' [-Werror=suggest-attribute=noreturn]
 Pexecute (void *vcp, char const *buf, size_t size, size_t *match_size,
 ^~~~~~~~
cc1: all warnings being treated as errors
make[2]: *** [Makefile:1507: pcresearch.o] Error 1
make[2]: Leaving directory '/home/staff/grep/src'
make[1]: *** [Makefile:1432: all-recursive] Error 1
make[1]: Leaving directory '/home/staff/grep'
make: *** [Makefile:1373: all] Error 2
$ env LC_ALL=C gcc -v
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/libexec/gcc/x86_64-redhat-linux/8/lto-wrapper
OFFLOAD_TARGET_NAMES=nvptx-none
OFFLOAD_TARGET_DEFAULT=1
Target: x86_64-redhat-linux
Configured with: ../configure --enable-bootstrap 
--enable-languages=c,c++,fortran,objc,obj-c++,ada,go,lto
--prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info
--with-bugurl=http://bugzilla.redhat.com/bugzilla --enable-shared
--enable-threads=posix --enable-checking=release --enable-multilib
--with-system-zlib --enable-__cxa_atexit --disable-libunwind-exceptions
--enable-gnu-unique-object --enable-linker-build-id 
--with-gcc-major-version-only
--with-linker-hash-style=gnu --enable-plugin --enable-initfini-array
--with-isl --enable-libmpx --enable-offload-targets=nvptx-none
--without-cuda-driver --enable-gnu-indirect-function --enable-cet
--with-tune=generic --with-arch_32=i686 --build=x86_64-redhat-linux
Thread model: posix
gcc version 8.2.1 20181215 (Red Hat 8.2.1-6) (GCC)




--- End Message ---
--- Begin Message --- Subject: Re: bug#34054: Error in compilation of pcresearch if we have no pcre library Date: Sat, 19 Jan 2019 18:27:02 -0800
On Sat, Jan 12, 2019 at 4:07 PM Norihiro Tanaka <address@hidden> wrote:
> I pulled current master of grep from git repository and built it on
> fedora 29, and recieved following error.
>
> When we have no pcre library, DIE() in Pcompile and Pexecute is called,
> but noreturn attribute is set to their functions.
...
> pcresearch.c: In function 'Pcompile':
> pcresearch.c:114:1: error: function might be candidate for attribute
> 'noreturn' [-Werror=suggest-attribute=noreturn]
>  Pcompile (char *pattern, size_t size, reg_syntax_t ignored)

Thank you for the report.
Technically, we could fix it by adding more ifdefs, but I think it
would not be worthwhile to accommodate this use case.

To resolve that, I suggest to install libpcre.
Otherwise, when building without PCRE support, please either avoid the
configure-time --enable-gcc-warnings option or invoke make with the
"WERROR_CFLAGS=" option to suppress -Werror.


--- End Message ---

reply via email to

[Prev in Thread] Current Thread [Next in Thread]