diff --git a/fix-compile-error-include-libtirpc-because-glibc-doe.patch b/fix-compile-error-include-libtirpc-because-glibc-doe.patch new file mode 100644 index 0000000000000000000000000000000000000000..9e554b72804b42864a2855262efb0bce76c3b0fd --- /dev/null +++ b/fix-compile-error-include-libtirpc-because-glibc-doe.patch @@ -0,0 +1,41 @@ +From 9fe49021d6e063d42a77dd2d79681bc4bc403476 Mon Sep 17 00:00:00 2001 +From: wangxiao65 <287608437@qq.com> +Date: Wed, 15 Jul 2020 11:22:47 +0800 +Subject: [PATCH] fix compile error, include libtirpc, because glibc does not + provide rpc. + +--- + Makefile | 4 ++-- + webbench.c | 2 +- + 2 files changed, 3 insertions(+), 3 deletions(-) + +diff --git a/Makefile b/Makefile +index 47196bc..8e19df7 100644 +--- a/Makefile ++++ b/Makefile +@@ -1,7 +1,7 @@ +-CFLAGS?= -Wall -ggdb -W -O ++CFLAGS?= -Wall -ggdb -W -O -I/usr/include/tirpc + CC?= gcc + LIBS?= +-LDFLAGS?= ++LDFLAGS?= -ltirpc + PREFIX?= /usr/local + VERSION=1.5 + TMPDIR=/tmp/webbench-$(VERSION) +diff --git a/webbench.c b/webbench.c +index fa1b02f..c12d831 100644 +--- a/webbench.c ++++ b/webbench.c +@@ -25,7 +25,7 @@ + + #include + #include +-#include ++#include + #include + #include + #include +-- +2.23.0 + diff --git a/webbench.spec b/webbench.spec index eba3ffdd8d6b149ef180e561736a06a9a0de2b28..f290cd18bad4040b58be71e487d82778214afd87 100644 --- a/webbench.spec +++ b/webbench.spec @@ -2,15 +2,16 @@ Name: webbench Version: 1.5 -Release: 1 +Release: 2 Summary: simple tool for benchmarking WWW or proxy servers License: GPL URL: http://home.tiscali.cz/~cz210552/webbench.html Source0: http://home.tiscali.cz/~cz210552/distfiles/%{name}-%{version}.tar.gz Patch0: webbench-remove-socket-file-and-reimplement-function.patch +Patch1: fix-compile-error-include-libtirpc-because-glibc-doe.patch -BuildRequires: gcc +BuildRequires: gcc libtirpc-devel %description Web Bench is very simple tool for benchmarking WWW or proxy servers. Uses fork() for simulating multiple clients and can use HTTP/0.9-HTTP/1.1 requests. This benchmark is not very realistic, but it can test if your HTTPD can realy handle that many clients at once (try to run some CGIs) without taking your machine down. Displays pages/min and bytes/sec. Can be used in more aggressive mode with -f switch @@ -19,6 +20,7 @@ Web Bench is very simple tool for benchmarking WWW or proxy servers. Uses fork() %setup -q -n %{name}-%{version}/ #remove unclear license file socket.c and reimplement socket function. %patch0 -p1 +%patch1 -p1 %build %make_build @@ -40,6 +42,8 @@ Web Bench is very simple tool for benchmarking WWW or proxy servers. Uses fork() %{_mandir}/* %changelog +* Wed Jul 15 2020 Wang Xiao - 1.5-2 +- Fix compile error, include BuildRequires libtirpc, because glibc does not provide rpc * Sun Mar 29 2020 Wei Xiong - Package init