NetBSD Problem Report #45500
From www@NetBSD.org Wed Oct 19 19:03:11 2011
Return-Path: <www@NetBSD.org>
Received: from mail.netbsd.org (mail.netbsd.org [204.152.190.11])
by www.NetBSD.org (Postfix) with ESMTP id A969A63D5D9
for <gnats-bugs@gnats.NetBSD.org>; Wed, 19 Oct 2011 19:03:11 +0000 (UTC)
Message-Id: <20111019190311.1890263B955@www.NetBSD.org>
Date: Wed, 19 Oct 2011 19:03:11 +0000 (UTC)
From: iam@juanfra.info
Reply-To: iam@juanfra.info
To: gnats-bugs@NetBSD.org
Subject: Support for DragonFly in benchmarks/libmicro
X-Send-Pr-Version: www-1.0
>Number: 45500
>Category: pkg
>Synopsis: Support for DragonFly in benchmarks/libmicro
>Confidential: no
>Severity: critical
>Priority: high
>Responsible: marino
>State: closed
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Wed Oct 19 19:05:00 +0000 2011
>Closed-Date: Mon Nov 07 07:44:54 +0000 2011
>Last-Modified: Mon Nov 07 07:44:54 +0000 2011
>Originator: Juan Francisco Cantero Hurtado
>Release: DragonFlyBSD 2.12
>Organization:
>Environment:
DragonFly sobremesa.mc 2.13-DEVELOPMENT DragonFly 7d50db8-DEVELOPMENT #0: Wed Oct 19 21:39:37 CEST 2011 root@sobremesa.mc:/usr/obj/usr/src/sys/GENERIC i386
>Description:
benchmarks/libmicro hasn't support for DragonFly. The problem is the lack of the specific Makefile.
>How-To-Repeat:
The compilation fail because the lack of Makefile.DragonFly.
>Fix:
Download http://juanfra.info/bugs-y-listas/libmicro-dragonfly/Makefile.DragonFly .
You need modify the pkgsrc files for add the file Makefile.DragonFly to the work directory. Please, add the file to patches, no direct download from my server.
>Release-Note:
>Audit-Trail:
From: Juan Francisco Cantero Hurtado <iam@juanfra.info>
To: gnats-bugs@NetBSD.org
Cc:
Subject: Re: pkg/45500
Date: Thu, 20 Oct 2011 23:01:48 +0200
The problem is more important than I thought and is for all the
operating systems.
files/run-libmicro is a shell script pointing to
/usr/pkgsrc/benchamarks/libmicro/work/.destdir/libexec/libmicro.
I've fixed the problems:
http://juanfra.info/bugs-y-listas/libmicro-dragonfly/run-libmicro
Also, I've converted Makefile.DragonFly to a patch file:
http://juanfra.info/bugs-y-listas/libmicro-dragonfly/patch-al
http://juanfra.info/bugs-y-listas/libmicro-dragonfly/distinfo
Responsible-Changed-From-To: pkg-manager->marino
Responsible-Changed-By: marino@NetBSD.org
Responsible-Changed-When: Sun, 30 Oct 2011 14:51:04 +0000
Responsible-Changed-Why:
I'll take it.
From: John Marino <netbsd@marino.st>
To: gnats-bugs@NetBSD.org
Cc:
Subject: Re: pkg/45500 benchmarks/libmicro doesn't compile on dfly64
Date: Tue, 01 Nov 2011 00:01:14 +0100
Hi Juan,
I know your patches didn't cause the following error, but
benchmarks/libmicro doesn't build on x86_64-dragonfly2.13. Have you
only been building this on i386?
The error I'm seeing is:
gcc -c -O -DUSE_SEMOP -DUSE_SEMOP -D_REENTRANT -D_REENTRANT
../getcontext.c -o getcontext.o
gcc -o getcontext getcontext.o -O -DUSE_SEMOP libmicro.a -lpthread -lm
getcontext.o: In function `benchmark':
getcontext.c:(.text+0x23): undefined reference to `getcontext'
getcontext.c:(.text+0x2d): undefined reference to `getcontext'
getcontext.c:(.text+0x37): undefined reference to `getcontext'
getcontext.c:(.text+0x41): undefined reference to `getcontext'
getcontext.c:(.text+0x4b): undefined reference to `getcontext'
getcontext.o:getcontext.c:(.text+0x55): more undefined references to
`getcontext' follow
gmake[1]: *** [getcontext] Error 1
rm close_tcp.o cascade_lockf.o cascade_fcntl.o cascade_cond.o
getcontext.o file_lock.o fcntl_ndelay.o exp.o fork.o close.o
cascade_flock.o fcntl.o dup.o bind.o connection.o chdir.o exec.o
cascade_mutex.o exit.o
gmake[1]: Leaving directory
`/usr/obj/psworkzone/benchmarks/libmicro/work/libMicro-0.4.0/bin-x86_64'
gmake: *** [default] Error 2
*** Error code 2
Stop.
bmake: stopped in /usr/pkgsrc/benchmarks/libmicro
*** Error code 1
Regards.
John
From: Juan Francisco Cantero Hurtado <iam@juanfra.info>
To: gnats-bugs@NetBSD.org
Cc:
Subject: Re: pkg/45500 benchmarks/libmicro doesn't compile on dfly64
Date: Tue, 1 Nov 2011 04:42:55 +0100
On Mon, Oct 31, 2011 at 11:05:03PM +0000, John Marino wrote:
>
> Hi Juan,
>
> I know your patches didn't cause the following error, but
> benchmarks/libmicro doesn't build on x86_64-dragonfly2.13. Have you
> only been building this on i386?
>
> The error I'm seeing is:
> gcc -c -O -DUSE_SEMOP -DUSE_SEMOP -D_REENTRANT -D_REENTRANT
> ../getcontext.c -o getcontext.o
> gcc -o getcontext getcontext.o -O -DUSE_SEMOP libmicro.a -lpthread -lm
> getcontext.o: In function `benchmark':
> getcontext.c:(.text+0x23): undefined reference to `getcontext'
> getcontext.c:(.text+0x2d): undefined reference to `getcontext'
> getcontext.c:(.text+0x37): undefined reference to `getcontext'
> getcontext.c:(.text+0x41): undefined reference to `getcontext'
> getcontext.c:(.text+0x4b): undefined reference to `getcontext'
> getcontext.o:getcontext.c:(.text+0x55): more undefined references to
> `getcontext' follow
> gmake[1]: *** [getcontext] Error 1
> rm close_tcp.o cascade_lockf.o cascade_fcntl.o cascade_cond.o
> getcontext.o file_lock.o fcntl_ndelay.o exp.o fork.o close.o
> cascade_flock.o fcntl.o dup.o bind.o connection.o chdir.o exec.o
> cascade_mutex.o exit.o
> gmake[1]: Leaving directory
> `/usr/obj/psworkzone/benchmarks/libmicro/work/libMicro-0.4.0/bin-x86_64'
> gmake: *** [default] Error 2
> *** Error code 2
>
> Stop.
> bmake: stopped in /usr/pkgsrc/benchmarks/libmicro
> *** Error code 1
Yes, only in i386. My fault. Sorry.
The libc in dfly/amd64 hasn't "getcontext", only
lib/libc/i386/sys/getcontext.S. I think the team worked in the i386
version of "getcontext" before of the creation of dfly/amd64 GSoC
project, but they not ported all libc to amd64
I've opened a bug in dfly bugtracker:
http://bugs.dragonflybsd.org/issue2179
References:
- lib/libc/i386/sys/getcontext.S
- Request for swapcontext and getcontext to be ported to our libc:
http://leaf.dragonflybsd.org/mailarchive/users/2006-12/msg00153.html
- Port DragonFly to the AMD64 architecture:
http://www.dragonflybsd.org/docs/developer/AMD64GSoC/
--
Tomorrow I'll review the problem and I'll give you a solution. The
problem is only with amd64, so I think the better is import run-libmicro
in pkgsrc because this is broke for all OS and create two Makefiles for
DragonFly. I think the fix in libc is hard, so I'll disable temporary
the code affected.
Thanks.
--
Juan Francisco Cantero Hurtado http://juanfra.info
From: Juan Francisco Cantero Hurtado <iam@juanfra.info>
To: gnats-bugs@NetBSD.org
Cc:
Subject: Re: pkg/45500 benchmarks/libmicro doesn't compile on dfly64
Date: Wed, 2 Nov 2011 20:42:30 +0100
The best solution for the problem with dfly/amd64 is modify the Makefile
of pkgsrc for delete Makefile.DragonFly in dfly/amd64 and copy
Makefile.DragonFly.amd64 with name Makefile.DragonFly in the workdir.
Add this file to files/ :
http://juanfra.info/bugs-y-listas/libmicro-dragonfly/Makefile.DragonFly.amd64
I don't remember what is the correct format for "if OS+architecture" in
the Makefiles of pkgsrc. Sorry.
--
Juan Francisco Cantero Hurtado http://juanfra.info
From: "John Marino" <marino@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc:
Subject: PR/45500 CVS commit: pkgsrc/benchmarks/libmicro
Date: Sun, 6 Nov 2011 00:03:27 +0000
Module Name: pkgsrc
Committed By: marino
Date: Sun Nov 6 00:03:27 UTC 2011
Modified Files:
pkgsrc/benchmarks/libmicro: distinfo
pkgsrc/benchmarks/libmicro/files: run-libmicro
Added Files:
pkgsrc/benchmarks/libmicro/patches: patch-al
Log Message:
PR#45500 benchmarks/libmicro: Add DragonFly support
This commit fixes the run-libmicro command which was broken for all
platforms. It was pointing at the destdir version instead of the
installed version.
It also provides a DragonFly-specific makefile which enables it to
build and run on DragonFly.
To generate a diff of this commit:
cvs rdiff -u -r1.1.1.1 -r1.2 pkgsrc/benchmarks/libmicro/distinfo
cvs rdiff -u -r1.1.1.1 -r1.2 pkgsrc/benchmarks/libmicro/files/run-libmicro
cvs rdiff -u -r0 -r1.1 pkgsrc/benchmarks/libmicro/patches/patch-al
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
State-Changed-From-To: open->feedback
State-Changed-By: marino@NetBSD.org
State-Changed-When: Sun, 06 Nov 2011 00:07:32 +0000
State-Changed-Why:
Juan, please confirm fix for DragonFly. It builds and executes on my
x86_64 machine just fine.
From: Juan Francisco Cantero Hurtado <iam@juanfra.info>
To: gnats-bugs@NetBSD.org
Cc:
Subject: Re: pkg/45500 (Support for DragonFly in benchmarks/libmicro)
Date: Mon, 7 Nov 2011 04:07:31 +0100
On Sun, Nov 06, 2011 at 12:07:33AM +0000, marino@NetBSD.org wrote:
> Juan, please confirm fix for DragonFly. It builds and executes on my
> x86_64 machine just fine.
libmicro compiles and works perfect in dfly/amd64 now. Your changes are
simpler and better than mine. My idea was too complex.
Thanks for your work :)
--
Juan Francisco Cantero Hurtado http://juanfra.info
State-Changed-From-To: feedback->closed
State-Changed-By: marino@NetBSD.org
State-Changed-When: Mon, 07 Nov 2011 07:44:54 +0000
State-Changed-Why:
Fix confirmed by submitter.
>Unformatted:
(Contact us)
$NetBSD: query-full-pr,v 1.39 2013/11/01 18:47:49 spz Exp $
$NetBSD: gnats_config.sh,v 1.8 2006/05/07 09:23:38 tsutsui Exp $
Copyright © 1994-2007
The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.