From owner-freebsd-ports@FreeBSD.ORG Fri Aug 1 19:03:18 2008 Return-Path: Delivered-To: freebsd-ports@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E0280106564A for ; Fri, 1 Aug 2008 19:03:18 +0000 (UTC) (envelope-from sgk@troutmask.apl.washington.edu) Received: from troutmask.apl.washington.edu (troutmask.apl.washington.edu [128.208.78.105]) by mx1.freebsd.org (Postfix) with ESMTP id C24758FC1A for ; Fri, 1 Aug 2008 19:03:18 +0000 (UTC) (envelope-from sgk@troutmask.apl.washington.edu) Received: from troutmask.apl.washington.edu (localhost.apl.washington.edu [127.0.0.1]) by troutmask.apl.washington.edu (8.14.2/8.14.2) with ESMTP id m71J3IWm050028 for ; Fri, 1 Aug 2008 12:03:18 -0700 (PDT) (envelope-from sgk@troutmask.apl.washington.edu) Received: (from sgk@localhost) by troutmask.apl.washington.edu (8.14.2/8.14.2/Submit) id m71J3IHP050027 for freebsd-ports@freebsd.org; Fri, 1 Aug 2008 12:03:18 -0700 (PDT) (envelope-from sgk) Date: Fri, 1 Aug 2008 12:03:18 -0700 From: Steve Kargl To: freebsd-ports@freebsd.org Message-ID: <20080801190318.GA49968@troutmask.apl.washington.edu> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.4.2.3i Subject: [PATCH] Fix biology/molden X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 01 Aug 2008 19:03:19 -0000 diff -urN molden.old/Makefile molden/Makefile --- molden.old/Makefile 2008-08-01 11:06:14.000000000 -0700 +++ molden/Makefile 2008-04-25 15:53:23.000000000 -0700 @@ -28,9 +28,9 @@ USE_FORTRAN= yes -#.if ${OSVERSION} >= 800030 -#BROKEN= does not compile -#.endif +.if ${OSVERSION} >= 800030 +BROKEN= does not compile +.endif post-patch: ${REINPLACE_CMD} -e 's,malloc.h,stdlib.h,' ${WRKSRC}/xwin.c diff -urN molden.old/files/patch-xwin.c molden/files/patch-xwin.c --- molden.old/files/patch-xwin.c 2008-08-01 11:43:00.000000000 -0700 +++ molden/files/patch-xwin.c 1969-12-31 16:00:00.000000000 -0800 @@ -1,114 +0,0 @@ ---- xwin.c.orig 2008-08-01 11:34:19.000000000 -0700 -+++ xwin.c 2008-08-01 11:34:32.000000000 -0700 -@@ -3177,7 +3177,7 @@ - static int *icopth; - static int *icoptl; - static int *icoptm; --static int linkat = 0; -+static int link_at = 0; - - static QBOXSTRU IANZboxes[MAXAT]; - static QBOXSTRU IZboxes[MAXAT][4]; -@@ -11622,7 +11622,7 @@ - if (ioniom == 1) { - int ism, isl; - -- linkat = 0; -+ link_at = 0; - - /* Counting the number of Link atoms between H and lower - levels*/ -@@ -11635,10 +11635,10 @@ - if (ionij != 0) continue; - nconn = atomptr->iconn[j][0]; - for (k=1;k<=nconn;k++) { -- if (ityp[atomptr->iconn[j][k]-1]/10000 > 0) linkat++; -+ if (ityp[atomptr->iconn[j][k]-1]/10000 > 0) link_at++; - } - } -- linkat += 20000; -+ link_at += 20000; - *itotc = *icopth; - *imult = *ispopth; - if (CheckChargeMult()) { -@@ -11659,7 +11659,7 @@ - - } else if (ioniom == 2) { - -- linkat = 0; -+ link_at = 0; - - /* Counting the number of Link atoms between H and - lower levels*/ -@@ -11669,10 +11669,10 @@ - if(ionij != 0) continue; - nconn = atomptr->iconn[j][0]; - for (k=1;k<=nconn;k++) { -- if (ityp[atomptr->iconn[j][k]-1]/10000 > 0) linkat++; -+ if (ityp[atomptr->iconn[j][k]-1]/10000 > 0) link_at++; - } - } -- linkat += 20000; -+ link_at += 20000; - *itotc = *icopth; - *imult = *ispopth; - if (CheckChargeMult()) { -@@ -11684,7 +11684,7 @@ - break; - */ - } -- linkat = 0; -+ link_at = 0; - - /* Counting the number of Link atoms between H+M and - lower levels*/ -@@ -11694,10 +11694,10 @@ - if (ionij == 2) continue; - nconn = atomptr->iconn[j][0]; - for (k=1;k<=nconn;k++) { -- if (ityp[atomptr->iconn[j][k]-1]/10000 == 2) linkat++; -+ if (ityp[atomptr->iconn[j][k]-1]/10000 == 2) link_at++; - } - } -- linkat += 20000; -+ link_at += 20000; - *itotc = *icoptm; - *imult = *ispoptm; - if (CheckChargeMult()) { -@@ -11712,7 +11712,7 @@ - icopt = *icoptl+3; - ispopt = *ispoptl-1; - } -- linkat = 0; -+ link_at = 0; - *itotc = icopt - 3; - *imult = ispopt + 1; - *ito = itopt[jmode] + 1; -@@ -11964,10 +11964,10 @@ - ionil = 0; - - if (ioniom) { -- ionil = 3 - (linkat / 10000); -- linkat -= (linkat / 10000) * 10000; -+ ionil = 3 - (link_at / 10000); -+ link_at -= (link_at / 10000) * 10000; - } else { -- linkat = 0; -+ link_at = 0; - } - - if (*zmptr.ihaszm) { -@@ -11990,10 +11990,10 @@ - } - } - /* -- fprintf(stderr,"ionil %d ne %d itotc %d linkat %d mult %d\n", -- ionil,ne,*itotc,linkat,*imult); -+ fprintf(stderr,"ionil %d ne %d itotc %d link_at %d mult %d\n", -+ ionil,ne,*itotc,link_at,*imult); - */ -- ne = ne - *itotc + linkat; -+ ne = ne - *itotc + link_at; - if (ne % 2 == *imult % 2) return(1); - return(0); - }