Fix build with gcc-3.4

PR:		ports/70784
Submitted by:	Ports Fury
This commit is contained in:
Kirill Ponomarev 2004-08-22 01:06:12 +00:00
parent 44b43272e2
commit f62713e133
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=116996
9 changed files with 96 additions and 17 deletions

View file

@ -8,7 +8,7 @@
PORTNAME= vipec
PORTVERSION= 3.2.0
PORTREVISION= 1
PORTREVISION= 2
CATEGORIES= cad
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE}
MASTER_SITE_SUBDIR= ${PORTNAME}
@ -23,19 +23,14 @@ BUILD_DEPENDS= qmake:${PORTSDIR}/devel/qmake
USE_QT_VER= 3
USE_GMAKE= yes
MAKE_ENV= QTDIR="${QT_PREFIX}"
post-patch:
@${SED} -e 's:@PREFIX@:${PREFIX}:g' \
${FILESDIR}/vipec.sh.in > ${WRKSRC}/../vipec.sh
MAKE_ENV= QTDIR="${QT_PREFIX}" VIPECHOME="${DATADIR}"
do-configure:
@cd ${WRKSRC} && ${SETENV} ${MAKE_ENV} qmake \
-spec ${LOCALBASE}/share/qt/mkspecs/freebsd-g++ vipec.pro
do-install:
${INSTALL_SCRIPT} ${WRKSRC}/../vipec.sh ${PREFIX}/bin/vipec
${INSTALL_PROGRAM} ${WRKSRC}/../vipec ${PREFIX}/bin/vipec.exec
${INSTALL_PROGRAM} ${WRKSRC}/../vipec ${PREFIX}/bin/vipec
@${MKDIR} ${DATADIR}
${INSTALL_DATA} ${WRKSRC}/../vipec.cfg ${DATADIR}
@${MKDIR} ${DATADIR}/ckt

View file

@ -0,0 +1,18 @@
--- HelpWindow.cpp.orig Thu Oct 2 04:40:40 2003
+++ HelpWindow.cpp Fri Aug 20 23:49:10 2004
@@ -36,7 +36,15 @@
QString vipecHome = QString(getenv("VIPECHOME"));
if ( vipecHome.isEmpty() )
{
+#ifdef VIPECHOME
+ vipecHome = QString(VIPECHOME);
+ if (vipecHome.isEmpty())
+ {
+ vipecHome = dir.absPath();
+ }
+#else
vipecHome = dir.absPath();
+#endif
}
home_ = vipecHome + "/help/index.html";
const QStringList currentDir(".");

View file

@ -0,0 +1,22 @@
--- Setup.cpp.orig Fri Oct 3 09:31:11 2003
+++ Setup.cpp Fri Aug 20 23:49:30 2004
@@ -163,8 +163,17 @@
vipecHome_ = QString(getenv("VIPECHOME"));
if ( vipecHome_.isEmpty() )
{
- vipecHome_ = dir.absPath();
- Logger::warning("VIPECHOME not set, assuming " + vipecHome_);
+#ifdef VIPECHOME
+ vipecHome_ = QString(VIPECHOME);
+ if (vipecHome_.isEmpty())
+ {
+ vipecHome_ = dir.absPath();
+ Logger::warning("VIPECHOME not set, assuming " + vipecHome_);
+ }
+#else
+ vipecHome_ = dir.absPath();
+ Logger::warning("VIPECHOME not set, assuming " + vipecHome_);
+#endif
}
helpFilename_ = vipecHome_ + "/help/index.html";
configFilename_ = vipecHome_ + "/vipec.cfg";

View file

@ -0,0 +1,24 @@
--- ../include/Component.h.orig Fri Mar 30 18:50:58 2001
+++ ../include/Component.h Fri Aug 20 21:55:50 2004
@@ -93,6 +93,10 @@
static int getNodeSize();
+ //Not implemented
+ Component( const Component& c );
+ Component& operator=( const Component& c );
+
protected:
virtual void drawSymbol(QPainter*) = 0;
CircuitNode* addNode(int, int, bool isPortNode = FALSE,
@@ -106,10 +110,6 @@
void copyMemberData( Component& source );
private:
- //Not implemented
- Component( const Component& c );
- Component& operator=( const Component& c );
-
void drawAttributes(QPainter* painter);
protected:

View file

@ -0,0 +1,10 @@
--- ../include/DataVector.h.orig Tue Feb 13 06:23:19 2001
+++ ../include/DataVector.h Fri Aug 20 21:56:44 2004
@@ -43,7 +43,6 @@
uint getSize();
void addPoint(TComplex value);
-private:
DataVector(const DataVector& vector);

View file

@ -0,0 +1,13 @@
--- ../include/Schematic.h.orig Fri Mar 30 18:50:58 2001
+++ ../include/Schematic.h Fri Aug 20 21:48:46 2004
@@ -91,9 +91,9 @@
QList<DataPoint>& getZData();
TComplex getPortImpedance( uint port );
-private:
Schematic( const Schematic& );
+private:
int distanceFromLine( const QPoint& point,
const CircuitLine& line,
bool orthoganalOnly );

View file

@ -1,11 +1,13 @@
--- vipec.pro.orig Thu Oct 2 04:58:40 2003
+++ vipec.pro Mon Jan 26 00:17:52 2004
@@ -8,7 +8,7 @@
+++ vipec.pro Sat Aug 21 00:04:24 2004
@@ -8,8 +8,8 @@
CLEAN_FILES = core Makefile *~ *moc* components/*~ dialogs/*~ images/*~ outputs/*~ widgets/*~
MOC_DIR = moc
OBJECTS_DIR = obj
-CONFIG = qt warn_on exceptions stl rtti
+CONFIG = qt warn_on exceptions stl rtti thread release
DEFINES = QT_FATAL_ASSERT
-DEFINES = QT_FATAL_ASSERT
+CONFIG += qt warn_on exceptions stl rtti
+DEFINES += QT_FATAL_ASSERT VIPECHOME=\"$(VIPECHOME)\"
RC_FILE = vipec.rc
HEADERS = \
../include/Logger.h \

View file

@ -1,4 +0,0 @@
#!/bin/sh
VIPECHOME=@PREFIX@/share/vipec/
export VIPECHOME
exec "@PREFIX@/bin/vipec.exec" "$@"

View file

@ -1,5 +1,4 @@
bin/vipec
bin/vipec.exec
%%DATADIR%%/ckt/amplifier.ckt
%%DATADIR%%/ckt/bandpass.ckt
%%DATADIR%%/ckt/bandpass.s2p