NetBSD Problem Report #22857

Received: (qmail 9578 invoked by uid 605); 19 Sep 2003 14:43:56 -0000
Message-Id: <20030919144354.06F9711152@narn.netbsd.org>
Date: Fri, 19 Sep 2003 14:43:54 +0000 (UTC)
From: jonathan@perkin.org.uk
Sender: gnats-bugs-owner@NetBSD.org
Reply-To: jonathan@perkin.org.uk
To: gnats-bugs@gnats.NetBSD.org
Subject: Fix benchmarks/httperf on SunOS
X-Send-Pr-Version: www-1.0

>Number:         22857
>Category:       pkg
>Synopsis:       Fix benchmarks/httperf on SunOS
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    pkg-manager
>State:          closed
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Fri Sep 19 14:44:00 +0000 2003
>Closed-Date:    Fri Sep 19 18:06:52 +0000 2003
>Last-Modified:  Fri Sep 19 18:07:00 +0000 2003
>Originator:     Jonathan Perkin
>Release:        N/A
>Organization:
British Broadcasting Corporation
>Environment:
SunOS build1 5.9 Generic_112233-01 sun4u sparc SUNW,UltraSPARC-IIi-cEngine
>Description:
httperf needs the -lsocket -lnsl -lresolv dance on Solaris.

To do this, we need to genericise the supplied Makefile a bit.  In doing
so we may help a little if host compiler isn't gcc (untested as yet).
>How-To-Repeat:
/home/jonp/pkg/gcc-3.3/bin/gcc -g  httperf.o object.o call.o conn.o sess.o core.o event.o http.o timer.o lib/getopt.o lib/getopt1.o gen/libgen.a stat/libstat.a /lib/libm.so   -o httperf
Undefined                       first referenced
 symbol                             in file
socket                              core.o
gethostbyname                       core.o
bind                                core.o
setsockopt                          core.o
inet_aton                           core.o
getsockopt                          core.o
connect                             core.o
ld: fatal: Symbol referencing errors. No output written to httperf
collect2: ld returned 1 exit status
gmake: *** [httperf] Error 1
*** Error code 2
>Fix:
http://www.perkin.org.uk/projects/netbsd/httperf.diff

Index: Makefile
===================================================================
RCS file: /cvsroot/pkgsrc/benchmarks/httperf/Makefile,v
retrieving revision 1.4
diff -u -r1.4 Makefile
--- Makefile	2003/07/17 21:24:28	1.4
+++ Makefile	2003/09/19 14:36:28
@@ -13,6 +13,12 @@

 USE_GMAKE=	yes

+.include "../../mk/bsd.prefs.mk"
+
+.if ${OPSYS} == "SunOS"
+LDFLAGS+=	-lsocket -lnsl -lresolv
+.endif
+
 do-install:
 	${INSTALL_PROGRAM} ${WRKSRC}/httperf ${LOCALBASE}/bin/httperf
 	${INSTALL_MAN} ${WRKSRC}/httperf.man ${LOCALBASE}/man/man1/httperf.1
Index: distinfo
===================================================================
RCS file: /cvsroot/pkgsrc/benchmarks/httperf/distinfo,v
retrieving revision 1.2
diff -u -r1.2 distinfo
--- distinfo	2001/04/20 09:13:26	1.2
+++ distinfo	2003/09/19 14:36:28
@@ -2,3 +2,4 @@

 SHA1 (httperf-0.6.tar.gz) = 6e0bcc21e2a94061b231c50182528a17ba22f14f
 Size (httperf-0.6.tar.gz) = 85351 bytes
+SHA1 (patch-aa) = eb5e6431c62f1ec631a0d6b598de0e4029dc97fc
--- /dev/null	Fri Sep 19 15:36:14 2003
+++ patches/patch-aa	Fri Sep 19 15:34:45 2003
@@ -1,0 +1,17 @@
+$NetBSD$
+
+--- Makefile.orig	Tue Jun  2 04:06:52 1998
++++ Makefile	Fri Sep 19 15:34:28 2003
+@@ -38,9 +38,9 @@
+ CPPDEBUG := -DDEBUG $(CPPDEBUG)
+ CPPOPTIM := -DNDEBUG $(CPPOPTIM)
+ 
+-CPPFLAGS = -I. -Ilib $(CPP$(HOW))
+-CFLAGS = $(CONFIG) $(CFLAGS$(HOW))
+-LDFLAGS = $(LDFLAGS$(HOW))
++CPPFLAGS += -I. -Ilib $(CPP$(HOW))
++#CFLAGS = $(CONFIG) $(CFLAGS$(HOW))
++#LDFLAGS = $(LDFLAGS$(HOW))
+ 
+ HTTPERF = httperf object call conn sess core event http timer $(EXTRA)
+ 
>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->closed 
State-Changed-By: wiz 
State-Changed-When: Fri Sep 19 14:06:42 EDT 2003 
State-Changed-Why:  
Committed, thanks. 

From: Thomas Klausner <wiz@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc:  
Subject: pr/22857 CVS commit: pkgsrc/benchmarks/httperf
Date: Fri, 19 Sep 2003 18:06:39 +0000 (UTC)

 Module Name:	pkgsrc
 Committed By:	wiz
 Date:		Fri Sep 19 18:06:37 UTC 2003

 Modified Files:
 	pkgsrc/benchmarks/httperf: Makefile distinfo
 Added Files:
 	pkgsrc/benchmarks/httperf/patches: patch-aa

 Log Message:
 Make compile on Solaris. From Jonathan Perkin in PR 22857.


 To generate a diff of this commit:
 cvs rdiff -r1.4 -r1.5 pkgsrc/benchmarks/httperf/Makefile
 cvs rdiff -r1.2 -r1.3 pkgsrc/benchmarks/httperf/distinfo
 cvs rdiff -r0 -r1.1 pkgsrc/benchmarks/httperf/patches/patch-aa

 Please note that diffs are not public domain; they are subject to the
 copyright notices on the relevant files.

>Unformatted:

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.51 2026/08/10 02:28:17 riastradh Exp $
$NetBSD: gnats_config.sh,v 1.10 2026/05/13 22:00:09 riastradh Exp $
Copyright © 1994-2026 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.