From e015922c8525cc3d7cf7e71ea6e3ff8a7e3e07bd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=BD=99=E8=AF=97?= Date: Thu, 20 Jun 2024 02:51:26 +0000 Subject: [PATCH] del useless if condition old: if ! ./configure : configure failed cat objs/autoconf.err exit 1 fi MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit new: ./configure Signed-off-by: 余诗 --- nginx.spec | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/nginx.spec b/nginx.spec index 1e4948c..1b9d6e8 100644 --- a/nginx.spec +++ b/nginx.spec @@ -164,7 +164,7 @@ mv ../%{name}-%{version}-%{release}-src . export DESTDIR=%{buildroot} nginx_ldopts="$RPM_LD_FLAGS -Wl,-E -Wl,-z,relro -Wl,-z,now -Wl,-z,noexecstack" nginx_ccopts="-fPIC -D_FORTIFY_SOURCE=2 -O2 -Wtrampolines -fsigned-char" -if ! ./configure \ +./configure \ --prefix=%{_datadir}/nginx --sbin-path=%{_sbindir}/nginx --modules-path=%{_libdir}/nginx/modules \ --conf-path=%{_sysconfdir}/nginx/nginx.conf --error-log-path=%{_localstatedir}/log/nginx/error.log \ --http-log-path=%{_localstatedir}/log/nginx/access.log \ @@ -189,11 +189,7 @@ if ! ./configure \ --with-http_perl_module=dynamic --with-http_auth_request_module \ --with-mail=dynamic --with-mail_ssl_module --with-pcre --with-pcre-jit --with-stream=dynamic \ --with-stream_ssl_module --with-google_perftools_module --with-debug \ - --with-cc-opt="%{optflags} $(pcre2-config --cflags) $nginx_ccopts" --with-ld-opt="$nginx_ldopts"; then - : configure failed - cat objs/autoconf.err - exit 1 -fi + --with-cc-opt="%{optflags} $(pcre2-config --cflags) $nginx_ccopts" --with-ld-opt="$nginx_ldopts" %make_build -- Gitee