Ticket #40640: qucs_0.0.17.diff
File qucs_0.0.17.diff, 15.5 KB (added by rowue@…, 11 years ago) |
---|
-
Portfile
4 4 PortSystem 1.0 5 5 6 6 name qucs 7 version 0.0.1 67 version 0.0.17 8 8 categories science electronics 9 9 license GPL-2+ 10 10 maintainers rowue openmaintainer 11 11 platforms darwin 12 supported_archs i386 ppc 12 13 13 description an integrated circuit simulator 14 14 long_description Qucs is an integrated circuit simulator. \ 15 You can setup an circut with graphical user interface. \16 It's based on QT 15 You can set up a circuit with a graphical user interface. 16 17 17 homepage http://qucs.sourceforge.net/ 18 master_sites sourceforge 19 checksums md5 c916502171d422ab168fe5fc681b29d8 \ 20 sha1 453143d511d2d75e115f4e03d32457446586d4ab \ 21 rmd160 77624106f891d700c123d7a3f38b47ea2a0d60e1 18 master_sites sourceforge:project/qucs/qucs/${version} 22 19 20 checksums rmd160 4ac2056bd097155ec73bb119f6ffcaeb6848ba69 \ 21 sha256 1fa0e6f2e8068c0800aa4dd3a25b41d18a6060619914c9787a20d21934089a70 23 22 24 depends_lib port:qt3-mac \ 23 depends_build port:pkgconfig 24 25 depends_lib port:qt4-mac \ 25 26 port:freehdl \ 26 27 port:libtool \ 27 port:iverilog \ 28 port:asco 28 port:iverilog 29 30 # iverilog is not universal 31 universal_variant no 32 29 33 use_parallel_build yes 30 patchfiles patch-configure.diff \ 34 35 patchfiles patch-Makefile.in.diff \ 31 36 patch-qucs_qucsdigi.diff \ 32 37 patch-qucs_qucsveri.diff \ 33 38 patch-qucs-main.cpp.diff \ 39 patch-qucs-filter-qf_filter.cpp.diff \ 40 patch-asco-configure.diff \ 34 41 patch-qucs-main.h.diff \ 35 patch-qucs-qucs_actions.cpp.diff 36 # patch-Makefile.in.diff 42 patch-qucs-qucs_actions.cpp.diff 37 43 38 44 post-patch { 39 45 reinplace "s|@APPDIR@|${applications_dir}|g" ${worksrcpath}/qucs/main.cpp 40 reinplace "s|@PREFIX@|${prefix}|g" ${worksrcpath}/qucs/qucsdigi 41 reinplace "s|@PREFIX@|${prefix}|g" ${worksrcpath}/qucs/qucsveri 46 reinplace "s|@PREFIX@|${prefix}|g" ${worksrcpath}/qucs/qucsdigi ${worksrcpath}/qucs/qucsveri 42 47 } 43 48 44 49 post-destroot { 45 50 foreach Program {qucs qucsedit qucsfilter qucshelp qucslib qucstrans qucsattenuator} { 46 xinstall -m 755 -d ${destroot}${applications_dir}/${Program}.app/Contents/MacOS51 xinstall -m 755 -d ${destroot}${applications_dir}/${Program}.app/Contents/MacOS 47 52 move ${destroot}${prefix}/bin/${Program} ${destroot}${applications_dir}/${Program}.app/Contents/MacOS/ 48 xinstall -m 755 -d ${destroot}${applications_dir}/${Program}.app/Contents/Resources53 xinstall -m 755 -d ${destroot}${applications_dir}/${Program}.app/Contents/Resources 49 54 xinstall -m 0644 ${filespath}/${Program}.icns ${destroot}${applications_dir}/${Program}.app/Contents/Resources 50 55 xinstall -m 0644 ${filespath}/Info.plist ${destroot}${applications_dir}/${Program}.app/Contents/ 51 56 reinplace "s|@VERSION@|${version}|" ${destroot}${applications_dir}/${Program}.app/Contents/Info.plist 52 57 reinplace "s|@EXECUTABLE@|${Program}|" ${destroot}${applications_dir}/${Program}.app/Contents/Info.plist 53 system " echo'APPL????' > ${destroot}${applications_dir}/${Program}.app/Contents/PkgInfo"58 system "printf 'APPL????' > ${destroot}${applications_dir}/${Program}.app/Contents/PkgInfo" 54 59 } 55 60 } 56 -
files/patch-Makefile.in.diff
1 --- Makefile.in.orig 2009-06-09 20:14:07.000000000 +0200 2 +++ Makefile.in 2009-06-09 21:35:12.000000000 +0200 3 @@ -105,8 +105,6 @@ 4 CC = @CC@ 5 CCDEPMODE = @CCDEPMODE@ 6 CFLAGS = @CFLAGS@ 7 -COND_MACOSX_FALSE = @COND_MACOSX_FALSE@ 8 -COND_MACOSX_TRUE = @COND_MACOSX_TRUE@ 9 COND_WIN32_FALSE = @COND_WIN32_FALSE@ 10 COND_WIN32_TRUE = @COND_WIN32_TRUE@ 11 CPP = @CPP@ 12 @@ -219,15 +217,6 @@ 1 --- Makefile.in.orig 2013-10-07 20:43:47.000000000 +0200 2 +++ Makefile.in 2013-10-07 20:45:52.000000000 +0200 3 @@ -795,54 +795,6 @@ 4 tags-recursive uninstall uninstall-am uninstall-hook 13 5 14 EXTRA_DIST = autogen.sh depcomp PLATFORMS RELEASE Info.plist15 6 16 -# MacOSX specific installation of applications 17 -@COND_MACOSX_TRUE@app_PROGS = $(top_builddir)/qucs/qucs \ 18 -@COND_MACOSX_TRUE@ $(top_builddir)/qucs-attenuator/qucsattenuator \ 19 -@COND_MACOSX_TRUE@ $(top_builddir)/qucs-filter/qucsfilter \ 20 -@COND_MACOSX_TRUE@ $(top_builddir)/qucs-help/qucshelp \ 21 -@COND_MACOSX_TRUE@ $(top_builddir)/qucs-lib/qucslib \ 22 -@COND_MACOSX_TRUE@ $(top_builddir)/qucs-edit/qucsedit \ 23 -@COND_MACOSX_TRUE@ $(top_builddir)/qucs-transcalc/qucstrans 7 -@COND_MACOSX_TRUE@install-exec-hook: mac-install-apps mac-deploy-framework 24 8 - 25 CLEANFILES = *~ *.rej *.orig26 MAINTAINERCLEANFILES = aclocal.m4 config.h.in configure Makefile.in \27 stamp-h.in stamp-h[0-9].in28 @@ -603,7 +592,6 @@29 30 install-exec-am:31 @$(NORMAL_INSTALL)32 - $(MAKE) $(AM_MAKEFLAGS) install-exec-hook33 34 install-info: install-info-recursive35 36 @@ -651,65 +639,6 @@37 uninstall-info-am38 39 40 -@COND_MACOSX_TRUE@install-exec-hook: mac-install-apps mac-install-framework41 -42 9 -@COND_MACOSX_TRUE@mac-install-apps: 43 10 -@COND_MACOSX_TRUE@ @echo "Creating MacOSX applications..."; 44 11 -@COND_MACOSX_TRUE@ @list='$(app_PROGS)'; for file in $$list; do \ … … 69 36 -@COND_MACOSX_TRUE@ chmod +x $(bindir)/$$app; \ 70 37 -@COND_MACOSX_TRUE@ done 71 38 - 72 -@COND_MACOSX_TRUE@mac- install-framework:39 -@COND_MACOSX_TRUE@mac-deploy-framework: 73 40 -@COND_MACOSX_TRUE@ @echo "Copying and setting up MacOSX/Qt framework..."; 74 -@COND_MACOSX_TRUE@ @if test -e "$(QTDIR)/lib/libqt.3.dylib"; then \ 75 -@COND_MACOSX_TRUE@ qtlib="$(QTDIR)/lib/libqt.3.dylib"; fi && \ 76 -@COND_MACOSX_TRUE@ if test -e "$(QTDIR)/lib/libqt-mt.3.dylib"; then \ 77 -@COND_MACOSX_TRUE@ qtlib="$(QTDIR)/lib/libqt-mt.3.dylib"; fi && \ 78 -@COND_MACOSX_TRUE@ if ! test -z "$$qtlib"; then \ 79 -@COND_MACOSX_TRUE@ $(mkinstalldirs) "$(bindir)/qucs.app/Contents/Frameworks"; \ 80 -@COND_MACOSX_TRUE@ cp "$$qtlib" "$(bindir)/qucs.app/Contents/Frameworks/"; \ 81 -@COND_MACOSX_TRUE@ qtlib=`basename $$qtlib`; \ 82 -@COND_MACOSX_TRUE@ install_name_tool -id "@executable_path/../Frameworks/$$qtlib" \ 83 -@COND_MACOSX_TRUE@ "$(bindir)/qucs.app/Contents/Frameworks/$$qtlib"; \ 84 -@COND_MACOSX_TRUE@ list='$(app_PROGS)'; for file in $$list; do \ 85 -@COND_MACOSX_TRUE@ app=`basename $$file` && \ 86 -@COND_MACOSX_TRUE@ install_name_tool -change $$qtlib \ 87 -@COND_MACOSX_TRUE@ "@executable_path/../../../qucs.app/Contents/Frameworks/$$qtlib" \ 88 -@COND_MACOSX_TRUE@ "$(bindir)/$$app.app/Contents/MacOS/$$app"; \ 89 -@COND_MACOSX_TRUE@ done; \ 90 -@COND_MACOSX_TRUE@ fi 41 -@COND_MACOSX_TRUE@ @list='$(app_PROGS)'; for file in $$list; do \ 42 -@COND_MACOSX_TRUE@ app=`basename $$file`; \ 43 -@COND_MACOSX_TRUE@ echo "running: macdeployqt $(bindir)/$${app}.app"; \ 44 -@COND_MACOSX_TRUE@ macdeployqt $(bindir)/$$app.app; \ 45 -@COND_MACOSX_TRUE@ done 91 46 - 92 47 -@COND_MACOSX_TRUE@uninstall-hook: 93 48 -@COND_MACOSX_TRUE@ @list='$(app_PROGS)'; for file in $$list; do \ … … 96 51 -@COND_MACOSX_TRUE@ done 97 52 -@COND_MACOSX_FALSE@install-exec-hook: 98 53 -@COND_MACOSX_FALSE@uninstall-hook: 54 - 99 55 # Tell versions [3.59,3.63) of GNU make to not export all variables. 100 56 # Otherwise a system limit (for SysV at least) may be exceeded. 101 57 .NOEXPORT: -
files/patch-asco-configure.diff
1 --- asco/configure 2013-10-07 19:16:20.000000000 +0200 2 +++ asco/configure 2013-10-07 19:16:30.000000000 +0200 3 @@ -4042,6 +4211,12 @@ 4 fi 5 fi 6 7 +case $host_os in 8 + *darwin*) 9 + CFLAGS="$CFLAGS -DUNIX -I/usr/include/malloc" 10 + ;; 11 +esac 12 + 13 # Extract the first word of "mpicc", so it can be a program name with args. 14 set dummy mpicc; ac_word=$2 15 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -
files/patch-configure.diff
1 --- configure.orig 2009-06-09 23:25:33.000000000 +02002 +++ configure 2009-06-09 23:26:55.000000000 +02003 @@ -6214,7 +6214,7 @@4 $as_echo_n "checking for Qt headers... " >&6; }5 paths="$QTDIR/include /usr/local/qt/include /usr/include/qt /usr/include/qt3 \6 /usr/include /usr/X11R6/include/X11/qt /usr/X11R6/include/X11/qt \7 - /usr/X11R6/include/qt /usr/X11R6/include /sw/include/qt \8 + /usr/X11R6/include/qt /usr/X11R6/include \9 /usr/X11R6/include/qt2 $prefix/include/qt3"10 for path in $paths; do11 if test -f "$path/qapplication.h"; then12 @@ -6278,9 +6278,9 @@13 $as_echo "checking for Qt... $QT_VER ($QT_MTS)" >&6; }14 { $as_echo "$as_me:$LINENO: checking for Qt library" >&515 $as_echo_n "checking for Qt library... " >&6; }16 -paths="$QTDIR/lib $QTDIR/lib64 /usr/local/qt/lib /usr/lib/qt /usr/lib \17 +paths="$QTDIR/lib $QTDIR/lib64 /usr/lib/qt /usr/lib \18 /usr/X11R6/lib/X11/qt /usr/X11R6/lib/X11/qt /usr/X11R6/lib/qt \19 - /usr/X11R6/lib /sw/lib /usr/lib64/qt /usr/X11R6/lib/qt2"20 + /usr/X11R6/lib /usr/lib64/qt /usr/X11R6/lib/qt2"21 ac_ext=cpp22 ac_cpp='$CXXCPP $CPPFLAGS'23 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' -
files/patch-qucs-filter-qf_filter.cpp.diff
1 --- qucs-filter/qf_filter.cpp 2 +++ qucs-filter/qf_filter.cpp 3 @@ -43,19 +43,19 @@ qf_filter::qf_filter () : 4 ncomp (0), Comp (NULL) { 5 } 6 7 -qf_filter::qf_filter (int n = 3, qfk k = UNDEF, qft t = LOWPASS) : 8 +qf_filter::qf_filter (int n, qfk k, qft t) : 9 type (t), kind (k), ord (n), fc (0), bw (0), imp (1), 10 ncomp (0), Comp (NULL) { 11 } 12 13 -qf_filter::qf_filter (qfk k = UNDEF, qft t = LOWPASS, qf_double_t r = 1, 14 +qf_filter::qf_filter (qfk k, qft t, qf_double_t r, 15 qf_double_t f = 1, qf_double_t b = 0) : 16 type (t), kind (k), fc (f), bw (b), imp (r), ncomp (0), Comp (NULL) { 17 fstart = fc - bw / 2; 18 fstop = fc + bw / 2; 19 } 20 21 -qf_filter::qf_filter (qfk k = UNDEF, qft t = LOWPASS) : 22 +qf_filter::qf_filter (qfk k, qft t) : 23 type (t), kind (k), ord (0), fc (0), bw (0), imp (1), 24 ncomp (0), Comp (NULL) { 25 } -
files/patch-qucs-main.cpp.diff
1 --- qucs/main.cpp.orig 20 09-03-24 22:33:05.000000000 +01002 +++ qucs/main.cpp 20 09-03-24 23:53:40.000000000 +01003 @@ -5 63,13 +563,14@@4 QucsSettings.OctaveDir =5 QDir::convertSeparators (QucsDirStr + "/share/qucs/octave/");6 } else {1 --- qucs/main.cpp.orig 2013-06-23 00:59:40.000000000 -0500 2 +++ qucs/main.cpp 2013-10-01 01:54:19.000000000 -0500 3 @@ -571,6 +571,7 @@ 4 if (var != NULL) { 5 QDir QucsDir = QDir (var); 6 QString QucsDirStr = QucsDir.canonicalPath (); 7 7 + QucsSettings.AppDir = QDir::convertSeparators("@APPDIR@/"); 8 QucsSettings.BinDir = BINARYDIR; 9 QucsSettings.BitmapDir = BITMAPDIR; 10 QucsSettings.LangDir = LANGUAGEDIR; 11 QucsSettings.LibDir = LIBRARYDIR; 12 QucsSettings.OctaveDir = OCTAVEDIR; 8 QucsSettings.BinDir = 9 QDir::convertSeparators (QucsDirStr + "/bin/"); 10 QucsSettings.BitmapDir = 11 @@ -594,7 +595,7 @@ 12 QucsSettings.ExamplesDir = QDir(DOCDIR).canonicalPath()+"/examples/"; 13 QucsSettings.DocDir = DOCDIR; 13 14 } 14 15 - QucsSettings.Editor = QucsSettings.BinDir + "qucsedit"; 15 16 + QucsSettings.Editor = QucsSettings.AppDir + "qucsedit.app/Contents/MacOS/qucsedit"; 16 17 17 QucsWorkDir.setPath(QDir::homeDirPath()+QDir::convertSeparators ("/.qucs")); 18 18 QucsHomeDir.setPath(QDir::homeDirPath()+QDir::convertSeparators ("/.qucs")); 19 loadSettings(); -
files/patch-qucs-qucs_actions.cpp.diff
1 --- qucs/qucs_actions.cpp.orig 20 09-03-24 23:02:53.000000000 +01002 +++ qucs/qucs_actions.cpp 20 09-03-25 00:09:46.000000000 +01003 @@ -6 09,7 +609,7 @@1 --- qucs/qucs_actions.cpp.orig 2013-06-23 00:59:40.000000000 -0500 2 +++ qucs/qucs_actions.cpp 2013-10-01 01:57:16.000000000 -0500 3 @@ -622,7 +622,7 @@ 4 4 void QucsApp::slotCallFilter() 5 5 { 6 Q Process *QucsFilter =7 - new Q Process(QString(QucsSettings.BinDir + "qucsfilter"));8 + new Q Process(QString(QucsSettings.AppDir + "qucsfilter.app/Contents/MacOS/qucsfilter"));6 Q3Process *QucsFilter = 7 - new Q3Process(QString(QucsSettings.BinDir + "qucsfilter")); 8 + new Q3Process(QString(QucsSettings.AppDir + "qucsfilter.app/Contents/MacOS/qucsfilter")); 9 9 if(!QucsFilter->start()) { 10 10 QMessageBox::critical(this, tr("Error"), 11 11 tr("Cannot start filter synthesis program!")); 12 @@ -6 26,7 +626,7 @@12 @@ -639,7 +639,7 @@ 13 13 void QucsApp::slotCallLine() 14 14 { 15 Q Process *QucsLine =16 - new Q Process(QString(QucsSettings.BinDir + "qucstrans"));17 + new Q Process(QString(QucsSettings.AppDir + "qucstrans.app/Contents/MacOS/qucstrans"));15 Q3Process *QucsLine = 16 - new Q3Process(QString(QucsSettings.BinDir + "qucstrans")); 17 + new Q3Process(QString(QucsSettings.AppDir + "qucstrans.app/Contents/MacOS/qucstrans")); 18 18 if(!QucsLine->start()) { 19 19 QMessageBox::critical(this, tr("Error"), 20 20 tr("Cannot start line calculation program!")); 21 @@ -6 43,7 +643,7 @@21 @@ -656,7 +656,7 @@ 22 22 void QucsApp::slotCallLibrary() 23 23 { 24 Q Process *QucsLibrary =25 - new Q Process(QString(QucsSettings.BinDir + "qucslib"));26 + new Q Process(QString(QucsSettings.AppDir + "qucslib.app/Contents/MacOS/qucslib"));24 Q3Process *QucsLibrary = 25 - new Q3Process(QString(QucsSettings.BinDir + "qucslib")); 26 + new Q3Process(QString(QucsSettings.AppDir + "qucslib.app/Contents/MacOS/qucslib")); 27 27 if(!QucsLibrary->start()) { 28 28 QMessageBox::critical(this, tr("Error"), 29 29 tr("Cannot start library program!")); 30 @@ -6 68,7 +668,7 @@30 @@ -681,7 +681,7 @@ 31 31 void QucsApp::slotCallAtt() 32 32 { 33 Q Process *QucsAtt =34 - new Q Process(QString(QucsSettings.BinDir + "qucsattenuator"));35 + new Q Process(QString(QucsSettings.AppDir + "qucsattenuator.app/Contents/MacOS/qucsattenuator"));33 Q3Process *QucsAtt = 34 - new Q3Process(QString(QucsSettings.BinDir + "qucsattenuator")); 35 + new Q3Process(QString(QucsSettings.AppDir + "qucsattenuator.app/Contents/MacOS/qucsattenuator")); 36 36 if(!QucsAtt->start()) { 37 37 QMessageBox::critical(this, tr("Error"), 38 38 tr("Cannot start attenuator calculation program!")); 39 @@ - 696,7 +696,7 @@39 @@ -709,7 +709,7 @@ 40 40 void QucsApp::showHTML(const QString& Page) 41 41 { 42 42 QStringList com; 43 43 - com << QucsSettings.BinDir + "qucshelp" << Page; 44 44 + com << QucsSettings.AppDir + "qucshelp.app/Contents/MacOS/qucshelp" << Page; 45 Q Process *QucsHelp = new QProcess(com);45 Q3Process *QucsHelp = new Q3Process(com); 46 46 QucsHelp->setCommunication(0); 47 47 if(!QucsHelp->start()) {