aboutsummaryrefslogtreecommitdiff
path: root/finance
diff options
context:
space:
mode:
authorMartin Wilke <miwi@FreeBSD.org>2014-02-07 12:59:02 +0000
committerMartin Wilke <miwi@FreeBSD.org>2014-02-07 12:59:02 +0000
commit9ab6cd90de1520895db28161a56cdda2c9b7055b (patch)
tree0ac6884ddfc4d72ba7869f7416574a9635bb3579 /finance
parent7198435c0f939fcc37e63b4a98ba1de265237cd2 (diff)
downloadports-9ab6cd90de1520895db28161a56cdda2c9b7055b.tar.gz
ports-9ab6cd90de1520895db28161a56cdda2c9b7055b.zip
Notes
Diffstat (limited to 'finance')
-rw-r--r--finance/qhacc/Makefile21
-rw-r--r--finance/qhacc/distinfo4
-rw-r--r--finance/qhacc/files/patch-engine__DefaultQHaccLoader.cpp11
-rw-r--r--finance/qhacc/files/patch-engine__GpgQHaccLoader.cpp10
-rw-r--r--finance/qhacc/files/patch-engine__IDableEntity.cpp11
-rw-r--r--finance/qhacc/files/patch-engine__calculators__PayeeCalculator.cpp19
-rw-r--r--finance/qhacc/files/patch-engine__calculators__PieCalculator.cpp11
-rw-r--r--finance/qhacc/files/patch-tools__EncryptingLoader.cpp11
8 files changed, 90 insertions, 8 deletions
diff --git a/finance/qhacc/Makefile b/finance/qhacc/Makefile
index 92eb8807900d..8fba044b4201 100644
--- a/finance/qhacc/Makefile
+++ b/finance/qhacc/Makefile
@@ -2,7 +2,7 @@
# $FreeBSD$
PORTNAME= qhacc
-PORTVERSION= 4.2.1
+PORTVERSION= 4.3
CATEGORIES= finance
MASTER_SITES= SF/${PORTNAME}/${PORTNAME}/${PORTNAME}-${PORTVERSION}
EXTRACT_SUFX= .tgz
@@ -12,13 +12,13 @@ COMMENT= Simple Qt-based financial manager
LICENSE= GPLv2 # (or later)
-LIB_DEPENDS= libqwt6.so:${PORTSDIR}/x11-toolkits/qwt6
+LIB_DEPENDS= libgpgme.so:${PORTSDIR}/security/gpgme \
+ libqwt6.so:${PORTSDIR}/x11-toolkits/qwt6
OPTIONS_DEFINE= DOCS
USES= qmake:norecursive
USE_QT4= corelib gui sql moc_build rcc_build uic_build
-USE_GCC= yes
USE_CXXSTD= c++0x
USE_LDCONFIG= yes
@@ -26,23 +26,32 @@ DESKTOP_ENTRIES="QHacc" "" "" "${PORTNAME}" "" ""
.include <bsd.port.options.mk>
+.if ${OSVERSION} < 1000054
+USE_GCC= yes
+.endif
+
post-patch:
@${REINPLACE_CMD} -e \
'/^INSTALLDIR/s|=.*|=${DATADIR}| ; \
/^QWTINCS/s|=.*|=${LOCALBASE}/include/qwt6| ; \
/^QWTLIBS/s|=.*|=${LOCALBASE}/lib -lqwt6| ; \
- /^QMAKE_/s|=.*|=| ; \
- /+= debug/s|^|#|' ${WRKSRC}/user.pri
+ /+= debug/s|^|#| ; \
+ /^QMAKE_CFLAGS/s|=.*|= $$$${GPGMEINCS}| ; \
+ /^QMAKE_CXXFLAGS/s|=.*|= $$$${GPGMEINCS}| ; \
+ /^INCLUDEPATH/s|=.*|=|' ${WRKSRC}/user.pri
@${REINPLACE_CMD} -e \
's|/usr/include|${LOCALBASE}/include| ; \
s|-lqwt||' ${WRKSRC}/gui/gui.pro
@${REINPLACE_CMD} -e \
's|/../qm/|/../share/qhacc/|' ${WRKSRC}/gui/main.cpp
+ @${FIND} ${WRKSRC} -name "*.cpp" -or -name "*.h" -or -name "*.ui" | \
+ ${XARGS} ${REINPLACE_CMD} -e \
+ 's|qwt/||'
do-install:
(cd ${WRKSRC}/gui/build/release && ${INSTALL_PROGRAM} \
qhacc ${STAGEDIR}${PREFIX}/bin)
- (cd ${WRKSRC}/engine/build/release && ${INSTALL_DATA} \
+ (cd ${WRKSRC}/engine/build/release && ${INSTALL_LIB} \
libengine.so.1.0.0 ${STAGEDIR}${PREFIX}/lib)
@${LN} -sf libengine.so.1.0.0 ${STAGEDIR}${PREFIX}/lib/libengine.so
@${LN} -sf libengine.so.1.0.0 ${STAGEDIR}${PREFIX}/lib/libengine.so.1
diff --git a/finance/qhacc/distinfo b/finance/qhacc/distinfo
index c0ea7e6647f6..fa006e89e9f6 100644
--- a/finance/qhacc/distinfo
+++ b/finance/qhacc/distinfo
@@ -1,2 +1,2 @@
-SHA256 (qhacc-4.2.1.tgz) = 2e491f0c6c47d81f2ed32f8bad49bb18c6c19a43a05679d2e445c7e081bbe08d
-SIZE (qhacc-4.2.1.tgz) = 145190
+SHA256 (qhacc-4.3.tgz) = 007d0ccf0e9e239a215dabe4b305ca9c655673c123f570c0908567f97a32083f
+SIZE (qhacc-4.3.tgz) = 150670
diff --git a/finance/qhacc/files/patch-engine__DefaultQHaccLoader.cpp b/finance/qhacc/files/patch-engine__DefaultQHaccLoader.cpp
new file mode 100644
index 000000000000..57734ae8cc65
--- /dev/null
+++ b/finance/qhacc/files/patch-engine__DefaultQHaccLoader.cpp
@@ -0,0 +1,11 @@
+--- engine/DefaultQHaccLoader.cpp.orig
++++ engine/DefaultQHaccLoader.cpp
+@@ -22,6 +22,8 @@
+ #include "QHacc.h"
+
+ #include <sys/stat.h>
++#include <cstdlib>
++
+ #include <QSqlQuery>
+ #include <QSqlError>
+ #include <QStringList>
diff --git a/finance/qhacc/files/patch-engine__GpgQHaccLoader.cpp b/finance/qhacc/files/patch-engine__GpgQHaccLoader.cpp
new file mode 100644
index 000000000000..ce89189f2a87
--- /dev/null
+++ b/finance/qhacc/files/patch-engine__GpgQHaccLoader.cpp
@@ -0,0 +1,10 @@
+--- engine/GpgQHaccLoader.cpp.orig
++++ engine/GpgQHaccLoader.cpp
+@@ -26,6 +26,7 @@
+ #include <unistd.h>
+ #include <iostream>
+ #include <cstdio>
++#include <cerrno>
+
+ #include <QFile>
+ #include <QVariant>
diff --git a/finance/qhacc/files/patch-engine__IDableEntity.cpp b/finance/qhacc/files/patch-engine__IDableEntity.cpp
new file mode 100644
index 000000000000..504c0e41a0de
--- /dev/null
+++ b/finance/qhacc/files/patch-engine__IDableEntity.cpp
@@ -0,0 +1,11 @@
+--- engine/IDableEntity.cpp.orig
++++ engine/IDableEntity.cpp
+@@ -21,7 +21,7 @@
+
+ const int IDableEntity::NOID = -1;
+
+-IDableEntity::IDableEntity( int _id = NOID ) {
++IDableEntity::IDableEntity( int _id ) {
+ setId( _id );
+ }
+
diff --git a/finance/qhacc/files/patch-engine__calculators__PayeeCalculator.cpp b/finance/qhacc/files/patch-engine__calculators__PayeeCalculator.cpp
new file mode 100644
index 000000000000..75da7a465d55
--- /dev/null
+++ b/finance/qhacc/files/patch-engine__calculators__PayeeCalculator.cpp
@@ -0,0 +1,19 @@
+--- engine/calculators/PayeeCalculator.cpp.orig
++++ engine/calculators/PayeeCalculator.cpp
+@@ -59,14 +59,12 @@
+ }
+
+ std::multimap<Money, QString> moneymap;
+- std::map<QString, Money>::iterator it;
+- for( it = payeemap.begin(); it!= payeemap.end(); ++it ){
++ for( auto it = payeemap.begin(); it!= payeemap.end(); ++it ){
+ moneymap.insert( std::make_pair( it->second, it->first ) );
+ }
+
+ int id = 0;
+- std::map<Money, QString>::iterator mit;
+- for( mit = moneymap.begin(); mit!= moneymap.end(); ++mit ){
++ for( auto mit = moneymap.begin(); mit!= moneymap.end(); ++mit ){
+ CalculatorSeries cs( ++id );
+ cs.addValue( mit->first );
+
diff --git a/finance/qhacc/files/patch-engine__calculators__PieCalculator.cpp b/finance/qhacc/files/patch-engine__calculators__PieCalculator.cpp
new file mode 100644
index 000000000000..f22c199f4ea7
--- /dev/null
+++ b/finance/qhacc/files/patch-engine__calculators__PieCalculator.cpp
@@ -0,0 +1,11 @@
+--- engine/calculators/PieCalculator.cpp.orig
++++ engine/calculators/PieCalculator.cpp
+@@ -147,7 +147,7 @@
+
+ // erase the smallest accounts
+ Money other;
+- std::map<Money,int>::iterator it = smap.begin();
++ auto it = smap.begin();
+ while( mergenum >= 0 ){
+ other += it->first;
+
diff --git a/finance/qhacc/files/patch-tools__EncryptingLoader.cpp b/finance/qhacc/files/patch-tools__EncryptingLoader.cpp
new file mode 100644
index 000000000000..b8e24f6e0185
--- /dev/null
+++ b/finance/qhacc/files/patch-tools__EncryptingLoader.cpp
@@ -0,0 +1,11 @@
+--- tools/EncryptingLoader.cpp.orig
++++ tools/EncryptingLoader.cpp
+@@ -17,6 +17,8 @@
+ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ ************************** * * * * * * * * * * * * **************************/
+
++#include <cstdlib>
++
+ #include <QSqlError>
+
+ #include "EncryptingLoader.h"