From owner-freebsd-standards@FreeBSD.ORG Mon Feb 7 19:37:40 2011 Return-Path: Delivered-To: freebsd-standards@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8F7A01065675 for ; Mon, 7 Feb 2011 19:37:40 +0000 (UTC) (envelope-from bf1783@googlemail.com) Received: from mail-yx0-f182.google.com (mail-yx0-f182.google.com [209.85.213.182]) by mx1.freebsd.org (Postfix) with ESMTP id 4B6B28FC15 for ; Mon, 7 Feb 2011 19:37:39 +0000 (UTC) Received: by yxh35 with SMTP id 35so1965581yxh.13 for ; Mon, 07 Feb 2011 11:37:39 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=gamma; h=domainkey-signature:mime-version:reply-to:date:message-id:subject :from:to:cc:content-type; bh=IlVoKlmz6G+D/LARRNcThIOtQehPzvEdq75MpmdX9/E=; b=xVGU65VYXvQBDO4qWO0+hqecYz2wXnOxW1br8uso7wav+yAoN3Zrc/PmeLXaEqhR59 GNH/5xiS/cjToYraLK9oozpCurnnw+gKRYI2YXprae/ngMUQJ1/9E5o+lJOYOcqqIy0o mzxEq/0aFmpFXlb9WsMsKluwLQhDXsvkCNrqI= DomainKey-Signature: a=rsa-sha1; c=nofws; d=googlemail.com; s=gamma; h=mime-version:reply-to:date:message-id:subject:from:to:cc :content-type; b=jqcf8kQ99cv78C+ed6LcQNpnKiMRrZKyctwMnYuyLKgG3UmundUOWp2ANBE8yZ+dDy pKOyF3ldG5jAbn/1mvH/6ho0pBB9HyHibDxpMvBO0vRPb+Q94RsOtaSZJQ9NUBPuU+O/ nLY6EMLLxpG1BdtB6JibiMRcLrYw+f4vG+FWk= MIME-Version: 1.0 Received: by 10.236.109.52 with SMTP id r40mr30537426yhg.52.1297105370976; Mon, 07 Feb 2011 11:02:50 -0800 (PST) Received: by 10.236.110.52 with HTTP; Mon, 7 Feb 2011 11:02:50 -0800 (PST) Date: Mon, 7 Feb 2011 14:02:50 -0500 Message-ID: From: "b. f." To: Rainer Hurling Content-Type: text/plain; charset=ISO-8859-1 Cc: freebsd-standards@FreeBSD.org Subject: Re: Support for C99 complex type required X-BeenThere: freebsd-standards@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: bf1783@gmail.com List-Id: Standards compliance List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 07 Feb 2011 19:37:40 -0000 > For more than a decade now it was possible to install the statistical > program R (http://cran.r-project.org/) from the sources, even without > patching. Since fortran was removed from the system, lang/gcc44 or > lang/gcc45 has to be installed before. In addition a nice port exists > for years now: math/R. > > With the new development version of R > > ftp://ftp.stat.math.ethz.ch/Software/R/R-devel.tar.gz > > the configure script stops complaining about missing C99 complex types. > This is reproducable with only untaring the sources and starting > configure script in R-devel with ./configure. > > There was a discussion on the R-devel mailing list about it. The > developers came to the conclusion that there is no support for complex > functions complied with C99 standard in FreeBSD. > > http://gcc.gnu.org/gcc-4.2/c99status.html > > As far as I can see (I am not a programmer) FreeBSD is using the old c99 > wrapper file in /usr/bin. Am I right that lang/gcc45 should support such > complex functions? > > http://gcc.gnu.org/gcc-4.5/c99status.html > > Is there any way to get access to C99 complex functions of gcc-4.5.3 or > newer at least within a port? I am the math/R maintainer, and I do not subscribe to this list, although I occasionally read it. Therefore it would be better to ask me directly regarding questions about R, even if they are an appropriate, in a wider sense, for this list. Yes, you can use some of the C99 complex machinery, enough to satisfy R, which provides crude implementations of some of it if you have no support for it otherwise (in, e.g., src/main/complex.c). But you should use lang/gcc4* and the appropriate compiler flags -- if you are using /usr/bin/c99, you are using the wrong compiler suite. The port sets USE_FORTRAN=yes, which points R in the right direction. If you are not a programmer, why not just use the port? Or, if you really need the development version, why not use the port as a basis for your own locally-patched port? Generally speaking, you cannot expect to build software that is largely developed on other platforms without some modifications. In any event, I too would like to see better support in the base system for C99 math, which is being used by an increasing number of software packages. b.