[Midnightbsd-cvs] mports: mports/finance: Add opentaxsolver.

laffer1 at midnightbsd.org laffer1 at midnightbsd.org
Mon Apr 28 22:17:28 EDT 2008


Log Message:
-----------
Add opentaxsolver.  (technically a bit late for this year)

Modified Files:
--------------
    mports/finance:
        Makefile (r1.1 -> r1.2)

Added Files:
-----------
    mports/finance/opentaxsolver:
        Makefile (r1.1)
        distinfo (r1.1)
        pkg-descr (r1.1)
        pkg-plist (r1.1)
    mports/finance/opentaxsolver/files:
        patch-src-GUI-otk_lib-otk_lib.c (r1.1)
        patch-src-GUI-ots_gui.c (r1.1)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/finance/Makefile,v
retrieving revision 1.1
retrieving revision 1.2
diff -L finance/Makefile -L finance/Makefile -u -r1.1 -r1.2
--- finance/Makefile
+++ finance/Makefile
@@ -3,6 +3,7 @@
 
     COMMENT = Monetary, financial and related applications
 
+    SUBDIR += opentaxsolver
     SUBDIR += wmstock
 
 .include <bsd.port.subdir.mk>
--- /dev/null
+++ finance/opentaxsolver/pkg-descr
@@ -0,0 +1,19 @@
+OpenTaxSolver (OTS) is a free program for calculating Tax Form
+entries and tax-owed or refund-due, such as US Federal or State
+personal income taxes. An optional graphical front-end, OTS_GUI,
+has been added. Preliminary versions for Canada and the United
+Kingdom were posted in previous years and may be updated with help
+from volunteers.
+
+Motivations include:
+
+    * To make tax preparation software available for all platforms.
+    * To provide insight into how our taxes are calculated in clear
+      unambiguous equations/code.
+    * To avoid invasive, bloated commercial software packages.
+    * To avoid rewriting our own individual programs each year by
+      combining efforts.
+    * To provide a simple reliable tax-package requiring only
+      rudimentary knowledge to maintain.
+
+WWW: http://opentaxsolver.sourceforge.net/
--- /dev/null
+++ finance/opentaxsolver/pkg-plist
@@ -0,0 +1,54 @@
+bin/ots_gui
+bin/taxsolve_CA_540_2007
+bin/taxsolve_MA_1_2007
+bin/taxsolve_NC_D400_2007
+bin/taxsolve_NJ_1040_2007
+bin/taxsolve_NY_IT201_2007
+bin/taxsolve_OH_IT1040_2007
+bin/taxsolve_PA_40_2007
+bin/taxsolve_US_1040_2007
+bin/taxsolve_US_1040_Sched_C_2007
+bin/taxsolve_VA_760_2007
+share/ots/otslogo.ppm
+share/ots/examples_and_templates/CA_540/CA_540_2007_example.dat
+share/ots/examples_and_templates/CA_540/CA_540_2007_template.dat
+share/ots/examples_and_templates/CA_540/README_CA_540.txt
+share/ots/examples_and_templates/MA_1/README_MA_1.txt
+share/ots/examples_and_templates/MA_1/ma_1_2007_example.dat
+share/ots/examples_and_templates/MA_1/ma_1_2007_template.dat
+share/ots/examples_and_templates/NC_400/NC_400_2007_example.dat
+share/ots/examples_and_templates/NC_400/NC_400_2007_template.dat
+share/ots/examples_and_templates/NC_400/README_NC_400.txt
+share/ots/examples_and_templates/NJ_1040/NJ_1040_2007_example.dat
+share/ots/examples_and_templates/NJ_1040/NJ_1040_2007_template.dat
+share/ots/examples_and_templates/NJ_1040/README_NJ_1040.txt
+share/ots/examples_and_templates/NY_IT201/NY_IT201_2007_example.dat
+share/ots/examples_and_templates/NY_IT201/NY_IT201_2007_template.dat
+share/ots/examples_and_templates/NY_IT201/README_NY_IT201.txt
+share/ots/examples_and_templates/OH_1040/OH_IT1040_2007_example.dat
+share/ots/examples_and_templates/OH_1040/OH_IT1040_2007_template.dat
+share/ots/examples_and_templates/OH_1040/README_OH_IT1040.txt
+share/ots/examples_and_templates/PA_40/PA_40_2007_example.dat
+share/ots/examples_and_templates/PA_40/PA_40_2007_template.dat
+share/ots/examples_and_templates/PA_40/README_PA_40.txt
+share/ots/examples_and_templates/US_1040/README_US_1040.txt
+share/ots/examples_and_templates/US_1040/US_1040_example.dat
+share/ots/examples_and_templates/US_1040/US_1040_template.dat
+share/ots/examples_and_templates/US_1040_Sched_C/README_US_1040_Sched_C.txt
+share/ots/examples_and_templates/US_1040_Sched_C/US_1040Sched_C_2007_example.dat
+share/ots/examples_and_templates/US_1040_Sched_C/US_1040Sched_C_2007_template.dat
+share/ots/examples_and_templates/VA_760/README_VA_760.txt
+share/ots/examples_and_templates/VA_760/VA_760_2007_example.dat
+share/ots/examples_and_templates/VA_760/VA_760_2007_template.dat
+ at dirrm share/ots/examples_and_templates/VA_760
+ at dirrm share/ots/examples_and_templates/US_1040_Sched_C
+ at dirrm share/ots/examples_and_templates/US_1040
+ at dirrm share/ots/examples_and_templates/PA_40
+ at dirrm share/ots/examples_and_templates/OH_1040
+ at dirrm share/ots/examples_and_templates/NY_IT201
+ at dirrm share/ots/examples_and_templates/NJ_1040
+ at dirrm share/ots/examples_and_templates/NC_400
+ at dirrm share/ots/examples_and_templates/MA_1
+ at dirrm share/ots/examples_and_templates/CA_540
+ at dirrm share/ots/examples_and_templates
+ at dirrm share/ots
--- /dev/null
+++ finance/opentaxsolver/Makefile
@@ -0,0 +1,68 @@
+# Ports collection makefile for:  opentaxsolver
+# Date created:			  Sat Apr 08, 2006
+# Whom:				  John Hein (jhein at timing.com)
+#
+# $MidnightBSD: mports/finance/opentaxsolver/Makefile,v 1.1 2008/04/29 02:17:26 laffer1 Exp $
+# $FreeBSD: ports/finance/opentaxsolver/Makefile,v 1.7 2008/02/26 11:26:18 miwi Exp $
+#
+
+PORTNAME=	${UPPORTNAME:L}
+PORTVERSION=	5.05
+CATEGORIES=	finance
+MASTER_SITES=	${MASTER_SITE_SOURCEFORGE}
+MASTER_SITE_SUBDIR=	opentaxsolver
+DISTNAME=	${UPPORTNAME}2007_${PORTVERSION}
+EXTRACT_SUFX=	.tgz
+
+MAINTAINER=	ports at MidnightBSD.org
+COMMENT=	US tax prep software
+LICENSE=	gpl2
+
+USE_XLIB=	yes
+USE_GL=		yes
+UPPORTNAME=	OpenTaxSolver
+
+post-patch:
+	@${REINPLACE_CMD} -e 's/%%PREFIX%%/${PREFIX:C,/,\/,g}/' \
+	${WRKSRC}/src/GUI/ots_gui.c
+	@${REINPLACE_CMD} -e 's|/usr/X11R6|${X11BASE}|' \
+	${WRKSRC}/src/GUI/Makefile.linux
+
+# 4.07 distfile has pre-built (linux) binaries we must whack.
+pre-build:
+	@(cd ${BUILD_WRKSRC}/src && make -f Makefile.unix clean && \
+	cd GUI && make -f Makefile.linux clean)
+
+do-build:
+	@(cd ${BUILD_WRKSRC}; ${SETENV} ${MAKE_ENV} \
+	./Build_taxsolve_packages_LINUX.sh)
+
+BUILDPROGLISTCMD=	${FIND} bin -type f
+BUILDEXAMPLELISTCMD=	${FIND} examples_and_templates -type f
+BUILDEXAMPLEDIRLISTCMD=	${FIND} examples_and_templates -type d
+NEWPLIST=		${WRKDIR}/plist.new
+
+do-install:
+	@(cd ${WRKSRC} && \
+	for prog in $$(${BUILDPROGLISTCMD}); do \
+	    ${INSTALL_PROGRAM} $${prog} ${PREFIX}/bin/. ; \
+	done && \
+	${MKDIR} ${PREFIX}/share/ots && \
+	${INSTALL_DATA} src/GUI/otslogo.ppm ${PREFIX}/share/ots/. && \
+	for example in $$(${BUILDEXAMPLELISTCMD}); do \
+	    ${MKDIR} ${PREFIX}/share/ots/$$(dirname $${example}) && \
+	    ${INSTALL_DATA} $${example} \
+	    ${PREFIX}/share/ots/$$(dirname $${example})/. ; \
+	done)
+
+new-plist:
+	@(cd ${WRKSRC} && \
+	${BUILDPROGLISTCMD} | ${SORT} > ${NEWPLIST} && \
+	${ECHO_CMD} share/ots/otslogo.ppm >> ${NEWPLIST} && \
+	${BUILDEXAMPLELISTCMD} | ${SED} 's,^,share/ots/,' | ${SORT} \
+	    >> ${NEWPLIST} && \
+	for f in $$(${BUILDEXAMPLEDIRLISTCMD} | ${SED} 's,^,share/ots/,' && \
+	    ${ECHO_CMD} share/ots); do ${ECHO_CMD} @dirrm $$f; done | \
+	    ${SORT} -r >> ${NEWPLIST})
+
+.include <bsd.port.mk>
--- /dev/null
+++ finance/opentaxsolver/distinfo
@@ -0,0 +1,3 @@
+MD5 (OpenTaxSolver2007_5.05.tgz) = 87aa263a676c8c9066e43a534aeed288
+SHA256 (OpenTaxSolver2007_5.05.tgz) = bd4dcaad202c2aa45eb5258502139074f4e490e5be4b8d00b9b396fa3e13b424
+SIZE (OpenTaxSolver2007_5.05.tgz) = 379480
--- /dev/null
+++ finance/opentaxsolver/files/patch-src-GUI-ots_gui.c
@@ -0,0 +1,31 @@
+--- src/GUI/ots_gui.c.orig	2008-02-10 12:57:32.000000000 -0700
++++ src/GUI/ots_gui.c	2008-02-19 18:17:30.000000000 -0700
+@@ -1026,7 +1026,7 @@
+   }
+  else
+   {
+-   sprintf(tmpstr,"%s%s", invocation_path, strg);
++   snprintf(tmpstr, sizeof(tmpstr), "%s%s", invocation_path, strg);
+    printf("Setting Tax Program to be: '%s'\n", tmpstr);
+    taxsolvecmd = strdup(tmpstr);
+    strcpy(taxsolvestrng,tmpstr);
+@@ -1037,8 +1037,8 @@
+    if (k>0) k--;
+    while ((k>0) && (tmpstr[k]!=slashchr)) k--;
+    if (tmpstr[k]==slashchr)  tmpstr[k+1] = '\0';
+-   else  {sprintf(tmpstr,".%c", slashchr);}
+-   sprintf(directory_dat,"%sexamples_and_templates%c", tmpstr, slashchr);
++   else  {snprintf(tmpstr, sizeof(tmpstr), ".%c", slashchr);}
++   snprintf(directory_dat, sizeof(directory_dat), "%sexamples_and_templates%c", "%%PREFIX%%/share/ots/", slashchr);
+    /* CA_540  MA_1  NC_400  NJ_1040  NY_IT201  OH_1040  PA_40  US_1040  US_1040_Sched_C  VA_760 */
+    if (strstr(strg,"CA_540")) strcat(directory_dat,"CA_540"); else
+    if (strstr(strg,"MA_1")) strcat(directory_dat,"MA_1"); else
+@@ -1118,7 +1118,7 @@
+  main_panel = 
+  OtkMakePanel( OtkOuterWindow, Otk_Raised, Otk_LightGray, 1, 7.5, 98, 87 );	/* Main Panel. */
+  Otk_SetBorderThickness( main_panel, 0.25 );
+- sprintf(tmpstr,"%s..%csrc%cGUI%cotslogo.ppm", invocation_path, slashchr, slashchr, slashchr );
++ snprintf(tmpstr, sizeof(tmpstr), "%%PREFIX%%/share/ots/otslogo.ppm");
+  subpanel = OtkMakePanel( main_panel, Otk_Raised, Otk_LightGray, 18.5, 2, 63, 17 );
+  Otk_SetBorderThickness( subpanel, 0.75 );
+  testfile = fopen(tmpstr,"r");
--- /dev/null
+++ finance/opentaxsolver/files/patch-src-GUI-otk_lib-otk_lib.c
@@ -0,0 +1,13 @@
+--- src/GUI/otk_lib/otk_lib.c.orig	Fri Mar 31 21:42:34 2006
++++ src/GUI/otk_lib/otk_lib.c	Sat Apr  8 11:50:21 2006
+@@ -38,6 +38,10 @@
+ /* Set debug switch. 1=verbose.  0=quiet. */
+ #define DEBUG if (0)
+ 
++#ifdef __FreeBSD__
++#include <sys/time.h>
++#endif
++
+ #include "otk_lib.h"
+ 
+ int Otk_verbose=0;


More information about the Midnightbsd-cvs mailing list