summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergei Trofimovich <slyfox@gentoo.org>2020-01-30 08:30:36 +0000
committerSergei Trofimovich <slyfox@gentoo.org>2020-01-30 08:30:53 +0000
commiteb100a85c7481ac78d7c95f035924f267aca798a (patch)
treec61ab1b83b8fe74a285e3b28d50a11b5852684e8 /app-emulation/simh/simh-3.11.0.ebuild
parentsys-kernel/vanilla-sources: Automated version bump to {4.14.169,4.19.100,5.4.... (diff)
downloadgentoo-eb100a85c7481ac78d7c95f035924f267aca798a.tar.gz
gentoo-eb100a85c7481ac78d7c95f035924f267aca798a.tar.bz2
gentoo-eb100a85c7481ac78d7c95f035924f267aca798a.zip
app-emulation/simh: bump up to 3.11.0, take package
Reported-by: https://bugs.gentoo.org/706866 Closes: https://bugs.gentoo.org/706866 Package-Manager: Portage-2.3.86, Repoman-2.3.20 Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
Diffstat (limited to 'app-emulation/simh/simh-3.11.0.ebuild')
-rw-r--r--app-emulation/simh/simh-3.11.0.ebuild62
1 files changed, 62 insertions, 0 deletions
diff --git a/app-emulation/simh/simh-3.11.0.ebuild b/app-emulation/simh/simh-3.11.0.ebuild
new file mode 100644
index 000000000000..5c9e5593eacc
--- /dev/null
+++ b/app-emulation/simh/simh-3.11.0.ebuild
@@ -0,0 +1,62 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit toolchain-funcs
+
+MY_P="${PN}v$(ver_rs 1 '' 2 '-')" # 'a.b.c' -> 'ab-c'
+DESCRIPTION="a simulator for historical computers such as Vax, PDP-11 etc.)"
+HOMEPAGE="http://simh.trailing-edge.com/"
+SRC_URI="http://simh.trailing-edge.com/sources/${MY_P}.zip"
+
+LICENSE="MIT"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos"
+IUSE=""
+
+RDEPEND="net-libs/libpcap"
+DEPEND="${RDEPEND}
+ app-arch/unzip"
+
+S=${WORKDIR}/sim
+
+PATCHES=(
+ "${FILESDIR}"/${PN}-3.11.0-respect-FLAGS.patch
+ "${FILESDIR}"/${PN}-3.11.0-fix-mkdir-race.patch
+ "${FILESDIR}"/${PN}-3.11.0-fcommon.patch
+)
+
+src_prepare() {
+ default
+
+ # fix linking on Darwin
+ if [[ ${CHOST} == *-darwin* ]] ; then
+ sed -e 's/-lrt//g' \
+ -i makefile || die
+ fi
+}
+
+src_compile() {
+ export GCC="$(tc-getCC)"
+ export LDFLAGS_O="${LDFLAGS}"
+ export CFLAGS_O="${CFLAGS}"
+
+ local my_makeopts="USE_NETWORK=1"
+ if tc-is-gcc && ver_test $(gcc-version) -lt 4.6 ; then
+ my_makeopts+=" NO_LTO=1"
+ fi
+
+ emake ${my_makeopts}
+}
+
+src_install() {
+ for BINFILE in BIN/* ; do
+ newbin ${BINFILE} "simh-$(basename ${BINFILE})"
+ done
+
+ insinto /usr/share/simh
+ doins VAX/*.bin
+
+ dodoc *.txt */*.txt
+}