NetBSD Problem Report #44764
From Wolfgang.Stukenbrock@nagler-company.com Thu Mar 24 12:42:44 2011
Return-Path: <Wolfgang.Stukenbrock@nagler-company.com>
Received: from mail.netbsd.org (mail.netbsd.org [204.152.190.11])
by www.NetBSD.org (Postfix) with ESMTP id D3C7463BEA4
for <gnats-bugs@gnats.NetBSD.org>; Thu, 24 Mar 2011 12:42:44 +0000 (UTC)
Message-Id: <20110324124237.06FEE1E80CE@test-s0.nagler-company.com>
Date: Thu, 24 Mar 2011 13:42:36 +0100 (CET)
From: Wolfgang.Stukenbrock@nagler-company.com
Reply-To: Wolfgang.Stukenbrock@nagler-company.com
To: gnats-bugs@gnats.NetBSD.org
Subject: poppler failed to compile on Solaris 2.8 from pkgsrc 2010Q4
X-Send-Pr-Version: 3.95
>Number: 44764
>Category: pkg
>Synopsis: poppler failed to compile on Solaris 2.8 from pkgsrc 2010Q4
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: reed
>State: closed
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Thu Mar 24 12:45:00 +0000 2011
>Closed-Date: Sat Dec 29 06:40:53 +0000 2018
>Last-Modified: Sat Dec 29 06:40:53 +0000 2018
>Originator: Dr. W. Stukenbrock
>Release: pkgsrc-2010Q4
>Organization:
Dr. Nagler & Company GmbH
>Environment:
Solaris 8
>Description:
On solaris 2.8 there are no fmin() and fmax() functions in libm.so.
So TextOutputDev.cc have unresolved externals ..
On Solaris 2.10 fmin and fmax are defined in math_iso99.h.
I have no Solaris 2.9 here, so I cannot check if fmin/fmax is
present there - sorry
>How-To-Repeat:
Try to compile poppler on Solaris 2.8.
>Fix:
The following patch will fix the problem.
Accedently there is no way to figure out the OS version when compiling
with gcc. Sunstudio compilers have __`name -s`_`uname -r` define (e.g. __SunOS_5_8)
but gcc has nothing like this.
So I choose the header-file definition in order to decide if we need
an own version or not.
Hope this will match any future Solaris version too ...
--- poppler/TextOutputDev.cc.orig 2011-03-24 11:56:33.736416000 +0100
+++ poppler/TextOutputDev.cc 2011-03-24 13:06:09.153971000 +0100
@@ -63,9 +63,9 @@
#include "ICSupport.h"
#endif
-#if defined(__DragonFly__) || defined(__NetBSD__)
+#if defined(__DragonFly__) || defined(__NetBSD__) || (defined(__sun) && defined(__SVR4))
#include <sys/param.h>
-#if !(defined(__DragonFly__) && __DragonFly_version >= 200204) && !(defined(__NetBSD__) && (__NetBSD_Version__ >= 599002100 || (__NetBSD_Version__ >= 501000000 && __NetBSD_Version__ < 599000000)))
+#if !(defined(__DragonFly__) && __DragonFly_version >= 200204) && !(defined(__NetBSD__) && (__NetBSD_Version__ >= 599002100 || (__NetBSD_Version__ >= 501000000 && __NetBSD_Version__ < 599000000))) && !(defined(__sun) && defined(_ISO_MATH_C99_H))
static double fmax(double x, double y) { if (isnan(x)) return y; if (isnan(y)) return x; return (x > y ? x : y);}
static double fmin(double x, double y) { if (isnan(x)) return y; if (isnan(y)) return x; return (x < y ? x : y);}
#endif
>Release-Note:
>Audit-Trail:
[20110327 shattered] edited Environment: field
Responsible-Changed-From-To: pkg-manager->reed
Responsible-Changed-By: gls@NetBSD.org
Responsible-Changed-When: Thu, 24 Mar 2011 21:12:06 +0000
Responsible-Changed-Why:
Over to maintainer. Forward to solaris-pkg-people if required.
Thanks!
State-Changed-From-To: open->closed
State-Changed-By: maya@NetBSD.org
State-Changed-When: Sat, 29 Dec 2018 06:40:53 +0000
State-Changed-Why:
Stale bug report: poppler now requires C++14. It isn't possible to get this without a good chunk of C99.
poppler should not be providing fallback functions like this.
thanks for the patch and sorry it was not applied at the time.
>Unformatted:
(Contact us)
$NetBSD: query-full-pr,v 1.43 2018/01/16 07:36:43 maya Exp $
$NetBSD: gnats_config.sh,v 1.9 2014/08/02 14:16:04 spz Exp $
Copyright © 1994-2017
The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.