NetBSD Problem Report #35533

From www@NetBSD.org  Wed Jan 31 22:14:21 2007
Return-Path: <www@NetBSD.org>
Received: by narn.NetBSD.org (Postfix, from userid 31301)
	id 45F6163B99E; Wed, 31 Jan 2007 22:14:21 +0000 (UTC)
Message-Id: <20070131221421.45F6163B99E@narn.NetBSD.org>
Date: Wed, 31 Jan 2007 22:14:21 +0000 (UTC)
From: mjanos5@freemail.hu
Reply-To: mjanos5@freemail.hu
To: gnats-bugs@NetBSD.org
Subject: gnuplot: 'pause' command doesn't work on NetBSD
X-Send-Pr-Version: www-1.0

>Number:         35533
>Category:       pkg
>Synopsis:       gnuplot: 'pause' command doesn't work on NetBSD
>Confidential:   no
>Severity:       serious
>Priority:       high
>Responsible:    garbled
>State:          closed
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Wed Jan 31 22:15:00 +0000 2007
>Closed-Date:    Fri Feb 02 17:54:53 +0000 2007
>Last-Modified:  Fri Feb 02 17:54:53 +0000 2007
>Originator:     Mátyás János
>Release:        NetBSD 3.1.0 i386
>Organization:
>Environment:
>Description:
In graphics/gnuplot the 'pause' command does nothing.

I think the problem is with #define GP_SLEEP in src/stdfn.h, it doesn't detects properly how to sleep on this platform.

I didn't tested, but the same problem should present at graphics/gnuplot-nox11 package.
>How-To-Repeat:
Start gnuplot, then type in:

gnuplot> pause 10

This should wait 10 seconds, but nothing hapens. You get back the prompt immediately.
>Fix:
This worked for me (apply it in work.*/gnuplot-4.0.0 directory):

--- src/command.c       2004-04-13 15:00:01.000000000 +0200
+++ /tmp/command.c      2007-01-30 14:47:50.000000000 +0100
@@ -994,7 +994,7 @@
 #endif /* !(_Windows || OS2 || _Macintosh || MTOS || ATARI) */
     }
     if (sleep_time > 0)
-       GP_SLEEP(sleep_time);
+       sleep(sleep_time);

     if (text != 0 && sleep_time >= 0)
        fputc('\n', stderr);

>Release-Note:

>Audit-Trail:

Responsible-Changed-From-To: pkg-manager->garbled
Responsible-Changed-By: wiz@netbsd.org
Responsible-Changed-When: Thu, 01 Feb 2007 07:38:19 +0000
Responsible-Changed-Why:
Over to maintainer.


State-Changed-From-To: open->analyzed
State-Changed-By: drochner@netbsd.org
State-Changed-When: Thu, 01 Feb 2007 11:51:08 +0000
State-Changed-Why:
the reason is that usleep() is used if present which is only good for
sleep times less than a second


State-Changed-From-To: analyzed->feedback
State-Changed-By: drochner@netbsd.org
State-Changed-When: Thu, 01 Feb 2007 12:19:37 +0000
State-Changed-Why:
should be fixed in gnuplot-4.0.0nb7 (and gnuplot-nox11-4.0.0nb6),
can you confirm?


From: Matthias Drochner <drochner@netbsd.org>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: PR/35533 CVS commit: pkgsrc/graphics
Date: Thu,  1 Feb 2007 12:15:39 +0000 (UTC)

 Module Name:	pkgsrc
 Committed By:	drochner
 Date:		Thu Feb  1 12:15:39 UTC 2007

 Modified Files:
 	pkgsrc/graphics/gnuplot: Makefile Makefile.common distinfo
 	pkgsrc/graphics/gnuplot-nox11: Makefile
 	pkgsrc/graphics/gnuplot/patches: patch-aa
 Removed Files:
 	pkgsrc/graphics/gnuplot-nox11: distinfo

 Log Message:
 -don't use usleep() for the "pause" command, this does only work
  for sleep times less than a second (see SUSv3)
  fixes PR pkg/35533 by Matyas Janos
 -share patches between gnuplot{,-nox11}
 -bump PKGREVISION


 To generate a diff of this commit:
 cvs rdiff -r1.36 -r1.37 pkgsrc/graphics/gnuplot/Makefile
 cvs rdiff -r1.8 -r1.9 pkgsrc/graphics/gnuplot/Makefile.common
 cvs rdiff -r1.7 -r1.8 pkgsrc/graphics/gnuplot/distinfo
 cvs rdiff -r1.11 -r1.12 pkgsrc/graphics/gnuplot-nox11/Makefile
 cvs rdiff -r1.3 -r0 pkgsrc/graphics/gnuplot-nox11/distinfo
 cvs rdiff -r1.7 -r1.8 pkgsrc/graphics/gnuplot/patches/patch-aa

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

From: =?ISO-8859-2?Q?M=E1ty=E1s_J=E1nos?= <mjanos5@freemail.hu>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: pkg/35533 (gnuplot: 'pause' command doesn't work on NetBSD)
Date: Fri, 2 Feb 2007 03:36:12 +0100

 On Thu,  1 Feb 2007 12:19:39 +0000 (UTC)
 drochner@netbsd.org wrote:

 > should be fixed in gnuplot-4.0.0nb7 (and gnuplot-nox11-4.0.0nb6),
 > can you confirm?

 Yes, it works. I tested the patch from gnuplot HEAD. I didn't tested
 gnuplot-nox11.

State-Changed-From-To: feedback->closed
State-Changed-By: drochner@netbsd.org
State-Changed-When: Fri, 02 Feb 2007 17:54:53 +0000
State-Changed-Why:
submitter confirmed


>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.