From owner-freebsd-ports-bugs@FreeBSD.ORG Fri Jul 5 23:50:01 2013 Return-Path: Delivered-To: freebsd-ports-bugs@smarthost.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id CA343322 for ; Fri, 5 Jul 2013 23:50:01 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:1900:2254:206c::16:87]) by mx1.freebsd.org (Postfix) with ESMTP id AF3FE1B28 for ; Fri, 5 Jul 2013 23:50:01 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.7/8.14.7) with ESMTP id r65No1Td094584 for ; Fri, 5 Jul 2013 23:50:01 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.7/8.14.7/Submit) id r65No1DE094583; Fri, 5 Jul 2013 23:50:01 GMT (envelope-from gnats) Resent-Date: Fri, 5 Jul 2013 23:50:01 GMT Resent-Message-Id: <201307052350.r65No1DE094583@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-ports-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, "O. Hartmann" Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 0A33B1B1 for ; Fri, 5 Jul 2013 23:44:53 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from oldred.freebsd.org (oldred.freebsd.org [8.8.178.121]) by mx1.freebsd.org (Postfix) with ESMTP id EF3141AFD for ; Fri, 5 Jul 2013 23:44:52 +0000 (UTC) Received: from oldred.freebsd.org ([127.0.1.6]) by oldred.freebsd.org (8.14.5/8.14.7) with ESMTP id r65NiqPo037387 for ; Fri, 5 Jul 2013 23:44:52 GMT (envelope-from nobody@oldred.freebsd.org) Received: (from nobody@localhost) by oldred.freebsd.org (8.14.5/8.14.5/Submit) id r65NiqlQ037386; Fri, 5 Jul 2013 23:44:52 GMT (envelope-from nobody) Message-Id: <201307052344.r65NiqlQ037386@oldred.freebsd.org> Date: Fri, 5 Jul 2013 23:44:52 GMT From: "O. Hartmann" To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-3.1 Subject: ports/180337: devel/tnt: tnt_sparse_matrix_csr.h:97:3: error: no matching constructor for initialization of 'Array1D' X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 05 Jul 2013 23:50:01 -0000 >Number: 180337 >Category: ports >Synopsis: devel/tnt: tnt_sparse_matrix_csr.h:97:3: error: no matching constructor for initialization of 'Array1D' >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Fri Jul 05 23:50:00 UTC 2013 >Closed-Date: >Last-Modified: >Originator: O. Hartmann >Release: FreeBSD 10.0-CURRENT/amd64 and FreeBSD 9.1-STABLE/amd64 >Organization: FU Berlin >Environment: >Description: Compiling software packages utilizing port math/jama with CLANG (3.2/3.3) results in the error shown below. This error seems to be well known since 2011 (see for instance http://sourceforge.net/p/pymol/bugs/100/). [...] In file included from ForstnerOperator.cpp:7: In file included from /usr/local/include/tnt/jama_lu.h:4: In file included from /usr/local/include/tnt/tnt.h:55: /usr/local/include/tnt/tnt_sparse_matrix_csr.h:97:3: error: no matching constructor for initialization of 'Array1D' rowptr_(M, r), colind_(nz, c), dim1_(M), dim2_(N) {} ^ ~~~~ /usr/local/include/tnt/tnt_array1d.h:63:11: note: candidate constructor not viable: no known conversion from 'const int *' to 'const int' for 2nd argument; dereference the argument with * Array1D(int n, const T &a); ^ /usr/local/include/tnt/tnt_array1d.h:64:11: note: candidate constructor not viable: 2nd argument ('const int *') would lose const qualifier Array1D(int n, T *a); ^ /usr/local/include/tnt/tnt_array1d.h:61:11: note: candidate constructor not viable: requires 0 arguments, but 2 were provided Array1D(); ^ /usr/local/include/tnt/tnt_array1d.h:62:11: note: candidate constructor not viable: requires single argument 'n', but 2 arguments were provided explicit Array1D(int n); ^ /usr/local/include/tnt/tnt_array1d.h:65:14: note: candidate constructor not viable: requires single argument 'A', but 2 arguments were provided inline Array1D(const Array1D &A); ^ In file included from ForstnerOperator.cpp:7: In file included from /usr/local/include/tnt/jama_lu.h:4: In file included from /usr/local/include/tnt/tnt.h:55: /usr/local/include/tnt/tnt_sparse_matrix_csr.h:97:18: error: no matching constructor for initialization of 'Array1D' rowptr_(M, r), colind_(nz, c), dim1_(M), dim2_(N) {} ^ ~~~~~ /usr/local/include/tnt/tnt_array1d.h:63:11: note: candidate constructor not viable: no known conversion from 'const int *' to 'const int' for 2nd argument; dereference the argument with * Array1D(int n, const T &a); ^ /usr/local/include/tnt/tnt_array1d.h:64:11: note: candidate constructor not viable: 2nd argument ('const int *') would lose const qualifier Array1D(int n, T *a); ^ /usr/local/include/tnt/tnt_array1d.h:61:11: note: candidate constructor not viable: requires 0 arguments, but 2 were provided Array1D(); ^ /usr/local/include/tnt/tnt_array1d.h:62:11: note: candidate constructor not viable: requires single argument 'n', but 2 arguments were provided explicit Array1D(int n); ^ /usr/local/include/tnt/tnt_array1d.h:65:14: note: candidate constructor not viable: requires single argument 'A', but 2 arguments were provided inline Array1D(const Array1D &A); ^ >How-To-Repeat: Try compiling a client using the mentioned constructor with CLANG (I use a USGS specific planetary software package called ISIS3 which compiles well with GCC and fails with CLANG with the mentioned error). >Fix: As mentioned and suggested at http://sourceforge.net/p/pymol/bugs/100/, change file tnt/tnt_sparse_matrix_csr.h according --- tnt/tnt_sparse_matrix_csr.h.sav 2011-05-11 22:24:31.000000000 -0400 +++ tnt/tnt_sparse_matrix_csr.h 2011-05-11 22:29:32.000000000 -0400 @@ -49,8 +49,8 @@ private: Array1D val_; // data values (nz_ elements) - Array1D rowptr_; // row_ptr (dim_[0]+1 elements) - Array1D colind_; // col_ind (nz_ elements) + Array1D rowptr_; // row_ptr (dim_[0]+1 elements) + Array1D colind_; // col_ind (nz_ elements) int dim1_; // number of rows int dim2_; // number of cols Find a patched version of the ports Makefile and patched file attached. Patch attached with submission follows: diff -Nur tnt.orig/Makefile tnt/Makefile --- tnt.orig/Makefile 2013-07-05 21:37:29.000000000 +0200 +++ tnt/Makefile 2013-07-06 01:29:08.000000000 +0200 @@ -7,13 +7,14 @@ PORTNAME= tnt PORTVERSION= 1.2.6 +PORTREVISION= 1 CATEGORIES= devel math MASTER_SITES= http://math.nist.gov/tnt/ DISTNAME= ${PORTNAME}_126 .ifndef NOPORTDOCS DISTFILES=${DISTNAME}${EXTRACT_SUFX} tnt120doc.zip .endif -DIST_SUBDIR= tnt +DIST_SUBDIR= ${PORTNAME} EXTRACT_ONLY= ${DISTNAME}${EXTRACT_SUFX} MAINTAINER= erik@bz.bzflag.bz @@ -28,9 +29,14 @@ PORTDOCS= * .endif +extract: + @${MKDIR} ${WRKSRC} + @${EXTRACT_CMD} ${DISTDIR}/${DIST_SUBDIR}/${DISTNAME}${EXTRACT_SUFX} \ + -d ${WRKSRC} + do-install: ${MKDIR} ${PREFIX}/include/tnt - ${INSTALL_DATA} ${WRKDIR}/*.h ${PREFIX}/include/tnt + ${INSTALL_DATA} ${WRKSRC}/*.h ${PREFIX}/include/tnt .ifndef NOPORTDOCS ${MKDIR} ${DOCSDIR} ${EXTRACT_CMD} ${DISTDIR}/${DIST_SUBDIR}/tnt120doc \ diff -Nur tnt.orig/files/patch-tnt_sparse_matrix_csr.h tnt/files/patch-tnt_sparse_matrix_csr.h --- tnt.orig/files/patch-tnt_sparse_matrix_csr.h 1970-01-01 01:00:00.000000000 +0100 +++ tnt/files/patch-tnt_sparse_matrix_csr.h 2013-07-05 22:10:50.000000000 +0200 @@ -0,0 +1,13 @@ +--- tnt_sparse_matrix_csr.h.orig 2013-07-05 22:10:25.000000000 +0200 ++++ tnt_sparse_matrix_csr.h 2013-07-05 22:10:35.000000000 +0200 +@@ -49,8 +49,8 @@ + + private: + Array1D val_; // data values (nz_ elements) +- Array1D rowptr_; // row_ptr (dim_[0]+1 elements) +- Array1D colind_; // col_ind (nz_ elements) ++ Array1D rowptr_; // row_ptr (dim_[0]+1 elements) ++ Array1D colind_; // col_ind (nz_ elements) + + int dim1_; // number of rows + int dim2_; // number of cols >Release-Note: >Audit-Trail: >Unformatted: