forked from hasufell/hasufell-repository
Compare commits
1 Commits
python-sip
...
GHC-8.2.2
| Author | SHA1 | Date | |
|---|---|---|---|
| cc71b79a28 |
@@ -18,7 +18,6 @@ dev-ocaml
|
|||||||
dev-perl
|
dev-perl
|
||||||
dev-python
|
dev-python
|
||||||
dev-ruby
|
dev-ruby
|
||||||
dev-scm
|
|
||||||
dev-tcl
|
dev-tcl
|
||||||
dev-util
|
dev-util
|
||||||
games-action
|
games-action
|
||||||
@@ -50,7 +49,6 @@ sci-mathematics
|
|||||||
sys-apps
|
sys-apps
|
||||||
sys-boot
|
sys-boot
|
||||||
sys-process
|
sys-process
|
||||||
virtual
|
|
||||||
voip
|
voip
|
||||||
www-apps
|
www-apps
|
||||||
www-servers
|
www-servers
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
|
|
||||||
SUMMARY="cabal-install is the command line interface to Cabal and hackage"
|
SUMMARY="cabal-install is the command line interface to Cabal and hackage"
|
||||||
HOMEPAGE="https://www.haskell.org/cabal/"
|
HOMEPAGE="https://www.haskell.org/cabal/"
|
||||||
DOWNLOADS="https://downloads.haskell.org/~debian/pool/main/c/cabal-install-2.4/cabal-install-2.4_2.4%2Bgit20180920.1.60e200d-6~deb9_amd64.deb"
|
DOWNLOADS="https://www.haskell.org/cabal/release/cabal-install-${PV}/cabal-install-${PV}-x86_64-unknown-linux.tar.gz"
|
||||||
|
|
||||||
LICENCES="BSD-3"
|
LICENCES="BSD-3"
|
||||||
SLOT="0"
|
SLOT="0"
|
||||||
@@ -12,7 +12,7 @@ MYOPTIONS=""
|
|||||||
|
|
||||||
DEPENDENCIES="
|
DEPENDENCIES="
|
||||||
run:
|
run:
|
||||||
virtual/GHC
|
dev-lang/ghc-bin
|
||||||
dev-libs/gmp[>=6.1] [[ note = [ depends on libgmp.so.10 ] ]]
|
dev-libs/gmp[>=6.1] [[ note = [ depends on libgmp.so.10 ] ]]
|
||||||
!dev-haskell/cabal-install [[
|
!dev-haskell/cabal-install [[
|
||||||
description = [ Both install the same binary ]
|
description = [ Both install the same binary ]
|
||||||
@@ -24,13 +24,7 @@ BUGS_TO="hasufell@posteo.de"
|
|||||||
|
|
||||||
WORK=${WORKBASE}
|
WORK=${WORKBASE}
|
||||||
|
|
||||||
src_unpack() {
|
|
||||||
default
|
|
||||||
unpack ./data.tar.xz
|
|
||||||
}
|
|
||||||
|
|
||||||
src_install() {
|
src_install() {
|
||||||
dobin opt/cabal/2.4/bin/cabal
|
dobin cabal
|
||||||
doman opt/cabal/2.4/share/man/man1/*
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -16,8 +16,8 @@ MYOPTIONS=""
|
|||||||
|
|
||||||
DEPENDENCIES="
|
DEPENDENCIES="
|
||||||
run:
|
run:
|
||||||
|
dev-lang/ghc-bin
|
||||||
dev-libs/gmp[>=6.1] [[ note = [ depends on libgmp.so.10 ] ]]
|
dev-libs/gmp[>=6.1] [[ note = [ depends on libgmp.so.10 ] ]]
|
||||||
virtual/GHC
|
|
||||||
"
|
"
|
||||||
|
|
||||||
BUGS_TO="hasufell@posteo.de"
|
BUGS_TO="hasufell@posteo.de"
|
||||||
@@ -22,7 +22,7 @@ HOMEPAGE="https://www.haskell.org/ghc/"
|
|||||||
DOWNLOADS="
|
DOWNLOADS="
|
||||||
https://downloads.haskell.org/~ghc/${PV}/${MY_PNV}-src.tar.xz
|
https://downloads.haskell.org/~ghc/${PV}/${MY_PNV}-src.tar.xz
|
||||||
https://downloads.haskell.org/~ghc/${PV}/${MY_PNV}-testsuite.tar.xz
|
https://downloads.haskell.org/~ghc/${PV}/${MY_PNV}-testsuite.tar.xz
|
||||||
https://hawkings.mailstation.de/~hasufell/ghc-${PV}-x86_64-unknown-linux.tar.xz
|
https://downloads.haskell.org/~ghc/${PV}/ghc-${PV}-x86_64-deb7-linux.tar.xz
|
||||||
"
|
"
|
||||||
|
|
||||||
PLATFORMS="-* ~amd64"
|
PLATFORMS="-* ~amd64"
|
||||||
@@ -46,10 +46,12 @@ RESTRICT="test"
|
|||||||
|
|
||||||
DEPENDENCIES="
|
DEPENDENCIES="
|
||||||
build:
|
build:
|
||||||
|
dev-libs/libxslt[>=1.1.2]
|
||||||
dev-python/Sphinx
|
dev-python/Sphinx
|
||||||
build+run:
|
build+run:
|
||||||
dev-lang/perl:*[>=5.6.1]
|
dev-lang/perl:*[>=5.6.1]
|
||||||
dev-libs/gmp:=[>=5]
|
dev-libs/gmp:=[>=5]
|
||||||
|
dev-libs/libedit
|
||||||
dev-libs/libffi
|
dev-libs/libffi
|
||||||
llvm? ( dev-lang/llvm[>=2.7] )
|
llvm? ( dev-lang/llvm[>=2.7] )
|
||||||
!dev-lang/ghc [[ resolution = uninstall-blocked-before ]]
|
!dev-lang/ghc [[ resolution = uninstall-blocked-before ]]
|
||||||
@@ -59,7 +61,7 @@ DEPENDENCIES="
|
|||||||
WORK=${WORKBASE}/${MY_PNV}
|
WORK=${WORKBASE}/${MY_PNV}
|
||||||
|
|
||||||
src_unpack() {
|
src_unpack() {
|
||||||
unpack ghc-${PV}-x86_64-unknown-linux.tar.xz
|
unpack ghc-${PV}-x86_64-deb7-linux.tar.xz
|
||||||
edo mv "${WORK}" "${WORK}-pre"
|
edo mv "${WORK}" "${WORK}-pre"
|
||||||
unpack ${MY_PNV}-src.tar.xz
|
unpack ${MY_PNV}-src.tar.xz
|
||||||
unpack ${MY_PNV}-testsuite.tar.xz
|
unpack ${MY_PNV}-testsuite.tar.xz
|
||||||
@@ -67,6 +69,7 @@ src_unpack() {
|
|||||||
|
|
||||||
src_prepare() {
|
src_prepare() {
|
||||||
# prepare pre-built ghc
|
# prepare pre-built ghc
|
||||||
|
# we are not building, shut up already
|
||||||
edo mkdir "${TEMP}"/bin
|
edo mkdir "${TEMP}"/bin
|
||||||
edo ln -s /usr/$(exhost --target)/bin/$(exhost --tool-prefix)ar "${TEMP}/bin/ar"
|
edo ln -s /usr/$(exhost --target)/bin/$(exhost --tool-prefix)ar "${TEMP}/bin/ar"
|
||||||
edo ln -s /usr/$(exhost --target)/bin/true "${TEMP}"/bin/strip
|
edo ln -s /usr/$(exhost --target)/bin/true "${TEMP}"/bin/strip
|
||||||
@@ -161,19 +164,14 @@ src_install() {
|
|||||||
/usr/$(exhost --target)/bin/runghc{,-${SLOT}} \
|
/usr/$(exhost --target)/bin/runghc{,-${SLOT}} \
|
||||||
/usr/$(exhost --target)/bin/runhaskell /usr/$(exhost --target)/bin/runghc-${SLOT}
|
/usr/$(exhost --target)/bin/runhaskell /usr/$(exhost --target)/bin/runghc-${SLOT}
|
||||||
|
|
||||||
if [[ -d ${IMAGE}/usr/share/man ]]; then
|
# alternatives for manpages
|
||||||
local file alternatives=()
|
local file alternatives=()
|
||||||
for file in "${IMAGE}"/usr/share/man/*/*; do
|
for file in "${IMAGE}"/usr/share/man/*/*; do
|
||||||
alternatives+=(
|
alternatives+=(
|
||||||
${file#${IMAGE}}
|
${file#${IMAGE}}
|
||||||
${file#${IMAGE}}-${SLOT}
|
${file#${IMAGE}}-${SLOT}
|
||||||
)
|
)
|
||||||
done
|
done
|
||||||
|
|
||||||
alternatives_for \
|
|
||||||
ghc ${SLOT} ${SLOT} \
|
|
||||||
"${alternatives[@]}"
|
|
||||||
fi
|
|
||||||
}
|
}
|
||||||
|
|
||||||
src_test_expensive() {
|
src_test_expensive() {
|
||||||
@@ -1,179 +0,0 @@
|
|||||||
# Copyright 2008 Santiago M. Mola
|
|
||||||
# Copyright 2008, 2009, 2010, 2011 Ingmar Vanhassel
|
|
||||||
# Copyright 2011 Markus Rothe
|
|
||||||
# Distributed under the terms of the GNU General Public License v2
|
|
||||||
# Based in part upon 'ghc-6.8.2.ebuild' from Gentoo, which is:
|
|
||||||
# Copyright 1999-2008 Gentoo Foundation
|
|
||||||
# Copyright 2018 Julian Ospald <hasufell@posteo.de>
|
|
||||||
|
|
||||||
MY_PN="ghc"
|
|
||||||
MY_PNV="${MY_PN}-${PV}"
|
|
||||||
MY_PNVR="${MY_PN}-${PVR}"
|
|
||||||
|
|
||||||
require bash-completion flag-o-matic alternatives
|
|
||||||
require autotools [ supported_autoconf=[ 2.5 ] supported_automake=[ 1.15 ] ]
|
|
||||||
|
|
||||||
SUMMARY="The Glorious Glasgow Haskell Compilation System (non-haskell packages version)"
|
|
||||||
DESCRIPTION="
|
|
||||||
GHC is a state-of-the-art, open source, compiler and interactive environment for the functional
|
|
||||||
language Haskell.
|
|
||||||
"
|
|
||||||
HOMEPAGE="https://www.haskell.org/ghc/"
|
|
||||||
DOWNLOADS="
|
|
||||||
https://downloads.haskell.org/~ghc/${PV}/${MY_PNV}-src.tar.xz
|
|
||||||
https://downloads.haskell.org/~ghc/${PV}/${MY_PNV}-testsuite.tar.xz
|
|
||||||
https://downloads.haskell.org/~ghc/${PV}/ghc-${PV}-x86_64-fedora27-linux.tar.xz
|
|
||||||
"
|
|
||||||
|
|
||||||
PLATFORMS="-* ~amd64"
|
|
||||||
|
|
||||||
BUGS_TO=""
|
|
||||||
REMOTE_IDS="freecode:${MY_PN}"
|
|
||||||
UPSTREAM_RELEASE_NOTES="http://www.haskell.org/${MY_PN}/docs/${PV}/html/users_guide/release-${PV//./-}.html"
|
|
||||||
|
|
||||||
LICENCES="BSD-3"
|
|
||||||
SLOT="${PV}"
|
|
||||||
MYOPTIONS="
|
|
||||||
doc
|
|
||||||
llvm [[ description = [ Code generation using LLVM ] ]]
|
|
||||||
"
|
|
||||||
|
|
||||||
# `make test` takes really long, so disable it. It also succeeds (i.e. returned value is zero) in
|
|
||||||
# case of unexpected failures. There are always unexpected failures.
|
|
||||||
# If you really want to run the tests, then enable expensive tests in order to run `make fulltest`,
|
|
||||||
# which runs the same tests as `make test`, but includes more test cases per test.
|
|
||||||
RESTRICT="test"
|
|
||||||
|
|
||||||
DEPENDENCIES="
|
|
||||||
build:
|
|
||||||
dev-python/Sphinx
|
|
||||||
build+run:
|
|
||||||
dev-lang/perl:*[>=5.6.1]
|
|
||||||
dev-libs/gmp:=[>=5]
|
|
||||||
dev-libs/libffi
|
|
||||||
llvm? ( dev-lang/llvm[>=2.7] )
|
|
||||||
!dev-lang/ghc [[ resolution = uninstall-blocked-before ]]
|
|
||||||
!dev-lang/ghc-bin [[ resolution = uninstall-blocked-before ]]
|
|
||||||
"
|
|
||||||
|
|
||||||
WORK=${WORKBASE}/${MY_PNV}
|
|
||||||
|
|
||||||
src_unpack() {
|
|
||||||
unpack ghc-${PV}-x86_64-fedora27-linux.tar.xz
|
|
||||||
edo mv "${WORK}" "${WORK}-pre"
|
|
||||||
unpack ${MY_PNV}-src.tar.xz
|
|
||||||
unpack ${MY_PNV}-testsuite.tar.xz
|
|
||||||
}
|
|
||||||
|
|
||||||
src_prepare() {
|
|
||||||
# prepare pre-built ghc
|
|
||||||
edo pushd "${WORK}-pre"
|
|
||||||
edo ./configure \
|
|
||||||
--prefix="${TEMP}/ghc-pre" \
|
|
||||||
--target=$(exhost --target)
|
|
||||||
emake install
|
|
||||||
edo popd
|
|
||||||
|
|
||||||
autotools_src_prepare
|
|
||||||
}
|
|
||||||
|
|
||||||
src_configure() {
|
|
||||||
# Initialize build.mk
|
|
||||||
echo '# Exherbo changes' > mk/build.mk
|
|
||||||
|
|
||||||
cat <<EOF >> mk/build.mk
|
|
||||||
# Put docs into the right place
|
|
||||||
docdir = /usr/share/doc/${MY_PNVR}
|
|
||||||
htmldir = /usr/share/doc/${MY_PNVR}/html
|
|
||||||
EOF
|
|
||||||
|
|
||||||
if option doc; then
|
|
||||||
echo "BUILD_SPHINX_HTML=YES" >> mk/build.mk
|
|
||||||
echo "BUILD_SPHINX_PDF=NO" >> mk/build.mk
|
|
||||||
echo "HADDOCK_DOCS=YES" >> mk/build.mk
|
|
||||||
else
|
|
||||||
echo "BUILD_SPHINX_HTML=NO" >> mk/build.mk
|
|
||||||
echo "BUILD_SPHINX_PDF=NO" >> mk/build.mk
|
|
||||||
echo "HADDOCK_DOCS=NO" >> mk/build.mk
|
|
||||||
fi
|
|
||||||
|
|
||||||
GHC_SRC_CONFIGURE_OPTIONS+=( --with-ghc=${TEMP}/ghc-pre/bin/ghc )
|
|
||||||
export PATH="${WORKBASE}/usr/bin:${PATH}"
|
|
||||||
|
|
||||||
if option llvm; then
|
|
||||||
echo "GhcWithLlvmCodeGen=YES" >> mk/build.mk
|
|
||||||
else
|
|
||||||
echo "GhcWithLlvmCodeGen=NO" >> mk/build.mk
|
|
||||||
fi
|
|
||||||
|
|
||||||
GHC_SRC_CONFIGURE_OPTIONS+=(
|
|
||||||
--with-system-libffi
|
|
||||||
--with-ffi-includes=$(${PKG_CONFIG} --variable includedir libffi)
|
|
||||||
)
|
|
||||||
|
|
||||||
# host and build cause compilation (at least for 7.6.1) to fail, as they're intended for
|
|
||||||
# cross-compilation.
|
|
||||||
econf \
|
|
||||||
AR=${AR} \
|
|
||||||
CC=${CC} \
|
|
||||||
--target=$(exhost --target) \
|
|
||||||
"${GHC_SRC_CONFIGURE_OPTIONS[@]}"
|
|
||||||
|
|
||||||
# don't strip anything. Very useful when stage2 SIGSEGVs on you
|
|
||||||
echo "STRIP_CMD = :" >> mk/build.mk
|
|
||||||
}
|
|
||||||
|
|
||||||
src_install() {
|
|
||||||
default
|
|
||||||
|
|
||||||
# libraries/ is a partial dupe of the html/ dir hierarchy, but
|
|
||||||
# containing only LICENSE files
|
|
||||||
edo rm -rf "${IMAGE}"/usr/share/doc/${MY_PNVR}/{LICENSE,libraries}
|
|
||||||
|
|
||||||
dobashcompletion "${FILES}/ghc-bash-completion"
|
|
||||||
alternatives_for ghc ${SLOT} ${SLOT} \
|
|
||||||
/usr/share/bash-completion/completions/ghc-bin{,-${SLOT}}
|
|
||||||
|
|
||||||
# some scripts are not versioned, move
|
|
||||||
edo mv "${IMAGE}"/usr/$(exhost --target)/bin/{hp2ps,hp2ps-${SLOT}}
|
|
||||||
edo mv "${IMAGE}"/usr/$(exhost --target)/bin/{hpc,hpc-${SLOT}}
|
|
||||||
edo mv "${IMAGE}"/usr/$(exhost --target)/bin/{hsc2hs,hsc2hs-${SLOT}}
|
|
||||||
|
|
||||||
# remove unversioned symlinks, we create alternatives later
|
|
||||||
local ghc_bin
|
|
||||||
for ghc_bin in ghc ghci ghc-pkg $(optionq doc && echo "haddock") runghc runhaskell ; do
|
|
||||||
edo rm "${IMAGE}"/usr/$(exhost --target)/bin/${ghc_bin}
|
|
||||||
done
|
|
||||||
unset ghc_bin
|
|
||||||
|
|
||||||
# create alternatives for scripts/binaries
|
|
||||||
alternatives_for ghc ${SLOT} ${SLOT} \
|
|
||||||
/usr/$(exhost --target)/bin/ghc{,-${SLOT}} \
|
|
||||||
/usr/$(exhost --target)/bin/ghci{,-${SLOT}} \
|
|
||||||
/usr/$(exhost --target)/bin/ghc-pkg{,-${SLOT}} \
|
|
||||||
$(optionq doc && echo "/usr/$(exhost --target)/bin/haddock{,-ghc-${SLOT}}") \
|
|
||||||
/usr/$(exhost --target)/bin/hp2ps{,-${SLOT}} \
|
|
||||||
/usr/$(exhost --target)/bin/hpc{,-${SLOT}} \
|
|
||||||
/usr/$(exhost --target)/bin/hsc2hs{,-${SLOT}} \
|
|
||||||
/usr/$(exhost --target)/bin/runghc{,-${SLOT}} \
|
|
||||||
/usr/$(exhost --target)/bin/runhaskell /usr/$(exhost --target)/bin/runghc-${SLOT}
|
|
||||||
|
|
||||||
if [[ -d ${IMAGE}/usr/share/man ]]; then
|
|
||||||
local file alternatives=()
|
|
||||||
for file in "${IMAGE}"/usr/share/man/*/*; do
|
|
||||||
alternatives+=(
|
|
||||||
${file#${IMAGE}}
|
|
||||||
${file#${IMAGE}}-${SLOT}
|
|
||||||
)
|
|
||||||
done
|
|
||||||
|
|
||||||
alternatives_for \
|
|
||||||
ghc ${SLOT} ${SLOT} \
|
|
||||||
"${alternatives[@]}"
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
src_test_expensive() {
|
|
||||||
emake fulltest
|
|
||||||
}
|
|
||||||
|
|
||||||
@@ -46,10 +46,12 @@ RESTRICT="test"
|
|||||||
|
|
||||||
DEPENDENCIES="
|
DEPENDENCIES="
|
||||||
build:
|
build:
|
||||||
|
dev-libs/libxslt[>=1.1.2]
|
||||||
dev-python/Sphinx
|
dev-python/Sphinx
|
||||||
build+run:
|
build+run:
|
||||||
dev-lang/perl:*[>=5.6.1]
|
dev-lang/perl:*[>=5.6.1]
|
||||||
dev-libs/gmp:=[>=5]
|
dev-libs/gmp:=[>=5]
|
||||||
|
dev-libs/libedit
|
||||||
dev-libs/libffi
|
dev-libs/libffi
|
||||||
llvm? ( dev-lang/llvm[>=2.7] )
|
llvm? ( dev-lang/llvm[>=2.7] )
|
||||||
!dev-lang/ghc [[ resolution = uninstall-blocked-before ]]
|
!dev-lang/ghc [[ resolution = uninstall-blocked-before ]]
|
||||||
@@ -159,19 +161,13 @@ src_install() {
|
|||||||
/usr/$(exhost --target)/bin/runhaskell /usr/$(exhost --target)/bin/runghc-${SLOT}
|
/usr/$(exhost --target)/bin/runhaskell /usr/$(exhost --target)/bin/runghc-${SLOT}
|
||||||
|
|
||||||
# alternatives for manpages
|
# alternatives for manpages
|
||||||
if [[ -d ${IMAGE}/usr/share/man ]]; then
|
local file alternatives=()
|
||||||
local file alternatives=()
|
for file in "${IMAGE}"/usr/share/man/*/*; do
|
||||||
for file in "${IMAGE}"/usr/share/man/*/*; do
|
alternatives+=(
|
||||||
alternatives+=(
|
|
||||||
${file#${IMAGE}}
|
${file#${IMAGE}}
|
||||||
${file#${IMAGE}}-${SLOT}
|
${file#${IMAGE}}-${SLOT}
|
||||||
)
|
)
|
||||||
done
|
done
|
||||||
|
|
||||||
alternatives_for \
|
|
||||||
ghc ${SLOT} ${SLOT} \
|
|
||||||
"${alternatives[@]}"
|
|
||||||
fi
|
|
||||||
}
|
}
|
||||||
|
|
||||||
src_test_expensive() {
|
src_test_expensive() {
|
||||||
@@ -1,179 +0,0 @@
|
|||||||
# Copyright 2008 Santiago M. Mola
|
|
||||||
# Copyright 2008, 2009, 2010, 2011 Ingmar Vanhassel
|
|
||||||
# Copyright 2011 Markus Rothe
|
|
||||||
# Distributed under the terms of the GNU General Public License v2
|
|
||||||
# Based in part upon 'ghc-6.8.2.ebuild' from Gentoo, which is:
|
|
||||||
# Copyright 1999-2008 Gentoo Foundation
|
|
||||||
# Copyright 2018 Julian Ospald <hasufell@posteo.de>
|
|
||||||
|
|
||||||
MY_PN="ghc"
|
|
||||||
MY_PNV="${MY_PN}-${PV}"
|
|
||||||
MY_PNVR="${MY_PN}-${PVR}"
|
|
||||||
|
|
||||||
require bash-completion flag-o-matic alternatives
|
|
||||||
require autotools [ supported_autoconf=[ 2.5 ] supported_automake=[ 1.15 ] ]
|
|
||||||
|
|
||||||
SUMMARY="The Glorious Glasgow Haskell Compilation System (non-haskell packages version)"
|
|
||||||
DESCRIPTION="
|
|
||||||
GHC is a state-of-the-art, open source, compiler and interactive environment for the functional
|
|
||||||
language Haskell.
|
|
||||||
"
|
|
||||||
HOMEPAGE="https://www.haskell.org/ghc/"
|
|
||||||
DOWNLOADS="
|
|
||||||
https://downloads.haskell.org/~ghc/${PV}/${MY_PNV}-src.tar.xz
|
|
||||||
https://downloads.haskell.org/~ghc/${PV}/${MY_PNV}-testsuite.tar.xz
|
|
||||||
https://downloads.haskell.org/~ghc/${PV}/ghc-${PV}-x86_64-fedora27-linux.tar.xz
|
|
||||||
"
|
|
||||||
|
|
||||||
PLATFORMS="-* ~amd64"
|
|
||||||
|
|
||||||
BUGS_TO=""
|
|
||||||
REMOTE_IDS="freecode:${MY_PN}"
|
|
||||||
UPSTREAM_RELEASE_NOTES="http://www.haskell.org/${MY_PN}/docs/${PV}/html/users_guide/release-${PV//./-}.html"
|
|
||||||
|
|
||||||
LICENCES="BSD-3"
|
|
||||||
SLOT="${PV}"
|
|
||||||
MYOPTIONS="
|
|
||||||
doc
|
|
||||||
llvm [[ description = [ Code generation using LLVM ] ]]
|
|
||||||
"
|
|
||||||
|
|
||||||
# `make test` takes really long, so disable it. It also succeeds (i.e. returned value is zero) in
|
|
||||||
# case of unexpected failures. There are always unexpected failures.
|
|
||||||
# If you really want to run the tests, then enable expensive tests in order to run `make fulltest`,
|
|
||||||
# which runs the same tests as `make test`, but includes more test cases per test.
|
|
||||||
RESTRICT="test"
|
|
||||||
|
|
||||||
DEPENDENCIES="
|
|
||||||
build:
|
|
||||||
dev-python/Sphinx
|
|
||||||
build+run:
|
|
||||||
dev-lang/perl:*[>=5.6.1]
|
|
||||||
dev-libs/gmp:=[>=5]
|
|
||||||
dev-libs/libffi
|
|
||||||
llvm? ( dev-lang/llvm[>=2.7] )
|
|
||||||
!dev-lang/ghc [[ resolution = uninstall-blocked-before ]]
|
|
||||||
!dev-lang/ghc-bin [[ resolution = uninstall-blocked-before ]]
|
|
||||||
"
|
|
||||||
|
|
||||||
WORK=${WORKBASE}/${MY_PNV}
|
|
||||||
|
|
||||||
src_unpack() {
|
|
||||||
unpack ghc-${PV}-x86_64-fedora27-linux.tar.xz
|
|
||||||
edo mv "${WORK}" "${WORK}-pre"
|
|
||||||
unpack ${MY_PNV}-src.tar.xz
|
|
||||||
unpack ${MY_PNV}-testsuite.tar.xz
|
|
||||||
}
|
|
||||||
|
|
||||||
src_prepare() {
|
|
||||||
# prepare pre-built ghc
|
|
||||||
edo pushd "${WORK}-pre"
|
|
||||||
edo ./configure \
|
|
||||||
--prefix="${TEMP}/ghc-pre" \
|
|
||||||
--target=$(exhost --target)
|
|
||||||
emake install
|
|
||||||
edo popd
|
|
||||||
|
|
||||||
autotools_src_prepare
|
|
||||||
}
|
|
||||||
|
|
||||||
src_configure() {
|
|
||||||
# Initialize build.mk
|
|
||||||
echo '# Exherbo changes' > mk/build.mk
|
|
||||||
|
|
||||||
cat <<EOF >> mk/build.mk
|
|
||||||
# Put docs into the right place
|
|
||||||
docdir = /usr/share/doc/${MY_PNVR}
|
|
||||||
htmldir = /usr/share/doc/${MY_PNVR}/html
|
|
||||||
EOF
|
|
||||||
|
|
||||||
if option doc; then
|
|
||||||
echo "BUILD_SPHINX_HTML=YES" >> mk/build.mk
|
|
||||||
echo "BUILD_SPHINX_PDF=NO" >> mk/build.mk
|
|
||||||
echo "HADDOCK_DOCS=YES" >> mk/build.mk
|
|
||||||
else
|
|
||||||
echo "BUILD_SPHINX_HTML=NO" >> mk/build.mk
|
|
||||||
echo "BUILD_SPHINX_PDF=NO" >> mk/build.mk
|
|
||||||
echo "HADDOCK_DOCS=NO" >> mk/build.mk
|
|
||||||
fi
|
|
||||||
|
|
||||||
GHC_SRC_CONFIGURE_OPTIONS+=( --with-ghc=${TEMP}/ghc-pre/bin/ghc )
|
|
||||||
export PATH="${WORKBASE}/usr/bin:${PATH}"
|
|
||||||
|
|
||||||
if option llvm; then
|
|
||||||
echo "GhcWithLlvmCodeGen=YES" >> mk/build.mk
|
|
||||||
else
|
|
||||||
echo "GhcWithLlvmCodeGen=NO" >> mk/build.mk
|
|
||||||
fi
|
|
||||||
|
|
||||||
GHC_SRC_CONFIGURE_OPTIONS+=(
|
|
||||||
--with-system-libffi
|
|
||||||
--with-ffi-includes=$(${PKG_CONFIG} --variable includedir libffi)
|
|
||||||
)
|
|
||||||
|
|
||||||
# host and build cause compilation (at least for 7.6.1) to fail, as they're intended for
|
|
||||||
# cross-compilation.
|
|
||||||
econf \
|
|
||||||
AR=${AR} \
|
|
||||||
CC=${CC} \
|
|
||||||
--target=$(exhost --target) \
|
|
||||||
"${GHC_SRC_CONFIGURE_OPTIONS[@]}"
|
|
||||||
|
|
||||||
# don't strip anything. Very useful when stage2 SIGSEGVs on you
|
|
||||||
echo "STRIP_CMD = :" >> mk/build.mk
|
|
||||||
}
|
|
||||||
|
|
||||||
src_install() {
|
|
||||||
default
|
|
||||||
|
|
||||||
# libraries/ is a partial dupe of the html/ dir hierarchy, but
|
|
||||||
# containing only LICENSE files
|
|
||||||
edo rm -rf "${IMAGE}"/usr/share/doc/${MY_PNVR}/{LICENSE,libraries}
|
|
||||||
|
|
||||||
dobashcompletion "${FILES}/ghc-bash-completion"
|
|
||||||
alternatives_for ghc ${SLOT} ${SLOT} \
|
|
||||||
/usr/share/bash-completion/completions/ghc-bin{,-${SLOT}}
|
|
||||||
|
|
||||||
# some scripts are not versioned, move
|
|
||||||
edo mv "${IMAGE}"/usr/$(exhost --target)/bin/{hp2ps,hp2ps-${SLOT}}
|
|
||||||
edo mv "${IMAGE}"/usr/$(exhost --target)/bin/{hpc,hpc-${SLOT}}
|
|
||||||
edo mv "${IMAGE}"/usr/$(exhost --target)/bin/{hsc2hs,hsc2hs-${SLOT}}
|
|
||||||
|
|
||||||
# remove unversioned symlinks, we create alternatives later
|
|
||||||
local ghc_bin
|
|
||||||
for ghc_bin in ghc ghci ghc-pkg $(optionq doc && echo "haddock") runghc runhaskell ; do
|
|
||||||
edo rm "${IMAGE}"/usr/$(exhost --target)/bin/${ghc_bin}
|
|
||||||
done
|
|
||||||
unset ghc_bin
|
|
||||||
|
|
||||||
# create alternatives for scripts/binaries
|
|
||||||
alternatives_for ghc ${SLOT} ${SLOT} \
|
|
||||||
/usr/$(exhost --target)/bin/ghc{,-${SLOT}} \
|
|
||||||
/usr/$(exhost --target)/bin/ghci{,-${SLOT}} \
|
|
||||||
/usr/$(exhost --target)/bin/ghc-pkg{,-${SLOT}} \
|
|
||||||
$(optionq doc && echo "/usr/$(exhost --target)/bin/haddock{,-ghc-${SLOT}}") \
|
|
||||||
/usr/$(exhost --target)/bin/hp2ps{,-${SLOT}} \
|
|
||||||
/usr/$(exhost --target)/bin/hpc{,-${SLOT}} \
|
|
||||||
/usr/$(exhost --target)/bin/hsc2hs{,-${SLOT}} \
|
|
||||||
/usr/$(exhost --target)/bin/runghc{,-${SLOT}} \
|
|
||||||
/usr/$(exhost --target)/bin/runhaskell /usr/$(exhost --target)/bin/runghc-${SLOT}
|
|
||||||
|
|
||||||
if [[ -d ${IMAGE}/usr/share/man ]]; then
|
|
||||||
local file alternatives=()
|
|
||||||
for file in "${IMAGE}"/usr/share/man/*/*; do
|
|
||||||
alternatives+=(
|
|
||||||
${file#${IMAGE}}
|
|
||||||
${file#${IMAGE}}-${SLOT}
|
|
||||||
)
|
|
||||||
done
|
|
||||||
|
|
||||||
alternatives_for \
|
|
||||||
ghc ${SLOT} ${SLOT} \
|
|
||||||
"${alternatives[@]}"
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
src_test_expensive() {
|
|
||||||
emake fulltest
|
|
||||||
}
|
|
||||||
|
|
||||||
@@ -20,10 +20,6 @@ DEPENDENCIES="
|
|||||||
dev-lang/perl:*[>=5.6.1]
|
dev-lang/perl:*[>=5.6.1]
|
||||||
dev-libs/gmp[>=6.1] [[ note = [ depends on libgmp.so.10 ] ]]
|
dev-libs/gmp[>=6.1] [[ note = [ depends on libgmp.so.10 ] ]]
|
||||||
sys-libs/ncurses[>=6.1-r2] [[ note = [ Only these include libtinfo.so symlinks ] ]]
|
sys-libs/ncurses[>=6.1-r2] [[ note = [ Only these include libtinfo.so symlinks ] ]]
|
||||||
!dev-lang/GHC [[
|
|
||||||
description = [ different provider ]
|
|
||||||
resolution = uninstall-blocked-after
|
|
||||||
]]
|
|
||||||
!dev-lang/ghc [[
|
!dev-lang/ghc [[
|
||||||
description = [ Both install the same binaries/libs and alternatives ]
|
description = [ Both install the same binaries/libs and alternatives ]
|
||||||
resolution = uninstall-blocked-before
|
resolution = uninstall-blocked-before
|
||||||
@@ -20,10 +20,6 @@ DEPENDENCIES="
|
|||||||
dev-lang/perl:*[>=5.6.1]
|
dev-lang/perl:*[>=5.6.1]
|
||||||
dev-libs/gmp[>=6.1] [[ note = [ depends on libgmp.so.10 ] ]]
|
dev-libs/gmp[>=6.1] [[ note = [ depends on libgmp.so.10 ] ]]
|
||||||
sys-libs/ncurses[>=6.1-r2] [[ note = [ Only these include libtinfo.so symlinks ] ]]
|
sys-libs/ncurses[>=6.1-r2] [[ note = [ Only these include libtinfo.so symlinks ] ]]
|
||||||
!dev-lang/GHC [[
|
|
||||||
description = [ different provider ]
|
|
||||||
resolution = uninstall-blocked-after
|
|
||||||
]]
|
|
||||||
!dev-lang/ghc [[
|
!dev-lang/ghc [[
|
||||||
description = [ Both install the same binaries/libs and alternatives ]
|
description = [ Both install the same binaries/libs and alternatives ]
|
||||||
resolution = uninstall-blocked-before
|
resolution = uninstall-blocked-before
|
||||||
@@ -1,96 +0,0 @@
|
|||||||
# Copyright 2018 Julian Ospald <hasufell@posteo.de>
|
|
||||||
# Distributed under the terms of the GNU General Public License v2
|
|
||||||
|
|
||||||
require bash-completion alternatives
|
|
||||||
|
|
||||||
SUMMARY="The Glorious Glasgow Haskell Compilation System"
|
|
||||||
DESCRIPTION="
|
|
||||||
GHC is a state-of-the-art, open source, compiler and interactive environment for the functional
|
|
||||||
language Haskell."
|
|
||||||
HOMEPAGE="https://www.haskell.org/ghc/"
|
|
||||||
DOWNLOADS="https://downloads.haskell.org/~ghc/${PV}/ghc-${PV}-x86_64-fedora27-linux.tar.xz"
|
|
||||||
|
|
||||||
LICENCES="BSD-3"
|
|
||||||
SLOT="${PV}"
|
|
||||||
PLATFORMS="-* ~amd64"
|
|
||||||
MYOPTIONS=""
|
|
||||||
|
|
||||||
DEPENDENCIES="
|
|
||||||
build+run:
|
|
||||||
dev-lang/perl:*[>=5.6.1]
|
|
||||||
dev-libs/gmp[>=6.1] [[ note = [ depends on libgmp.so.10 ] ]]
|
|
||||||
sys-libs/ncurses[>=6.1-r2] [[ note = [ Only these include libtinfo.so symlinks ] ]]
|
|
||||||
!dev-lang/GHC [[
|
|
||||||
description = [ different provider ]
|
|
||||||
resolution = uninstall-blocked-after
|
|
||||||
]]
|
|
||||||
!dev-lang/ghc [[
|
|
||||||
description = [ Both install the same binaries/libs and alternatives ]
|
|
||||||
resolution = uninstall-blocked-before
|
|
||||||
]]
|
|
||||||
suggestion:
|
|
||||||
dev-haskell/cabal-install-bin [[ description = [ the cabal binary for installing packages ] ]]
|
|
||||||
dev-lang/llvm[>=2.7] [[ description = [ LLVM can be used for code generation and linking ] ]]
|
|
||||||
"
|
|
||||||
|
|
||||||
BUGS_TO="hasufell@posteo.de"
|
|
||||||
REMOTE_IDS="freecode:${PN}"
|
|
||||||
UPSTREAM_RELEASE_NOTES="http://www.haskell.org/${PN}/docs/${PV}/html/users_guide/release-${PV//./-}.html"
|
|
||||||
|
|
||||||
RESTRICT="test"
|
|
||||||
|
|
||||||
WORK=${WORKBASE}/ghc-${PV}
|
|
||||||
|
|
||||||
src_configure() {
|
|
||||||
econf \
|
|
||||||
--target=$(exhost --target)
|
|
||||||
}
|
|
||||||
|
|
||||||
src_compile() {
|
|
||||||
:
|
|
||||||
}
|
|
||||||
|
|
||||||
src_install() {
|
|
||||||
default
|
|
||||||
|
|
||||||
# bashcomp
|
|
||||||
dobashcompletion "${FILES}/ghc-bash-completion"
|
|
||||||
alternatives_for ghc ${SLOT} ${SLOT} \
|
|
||||||
/usr/share/bash-completion/completions/ghc-bin{,-${SLOT}}
|
|
||||||
|
|
||||||
# some scripts are not versioned, move
|
|
||||||
edo mv "${IMAGE}"/usr/$(exhost --target)/bin/{hp2ps,hp2ps-${SLOT}}
|
|
||||||
edo mv "${IMAGE}"/usr/$(exhost --target)/bin/{hpc,hpc-${SLOT}}
|
|
||||||
edo mv "${IMAGE}"/usr/$(exhost --target)/bin/{hsc2hs,hsc2hs-${SLOT}}
|
|
||||||
|
|
||||||
# remove unversioned symlinks, we create alternatives later
|
|
||||||
local ghc_bin
|
|
||||||
for ghc_bin in ghc ghci ghc-pkg haddock runghc runhaskell ; do
|
|
||||||
edo rm "${IMAGE}"/usr/$(exhost --target)/bin/${ghc_bin}
|
|
||||||
done
|
|
||||||
unset ghc_bin
|
|
||||||
|
|
||||||
# create alternatives for scripts/binaries
|
|
||||||
alternatives_for ghc ${SLOT} ${SLOT} \
|
|
||||||
/usr/$(exhost --target)/bin/ghc{,-${SLOT}} \
|
|
||||||
/usr/$(exhost --target)/bin/ghci{,-${SLOT}} \
|
|
||||||
/usr/$(exhost --target)/bin/ghc-pkg{,-${SLOT}} \
|
|
||||||
/usr/$(exhost --target)/bin/haddock{,-ghc-${SLOT}} \
|
|
||||||
/usr/$(exhost --target)/bin/hp2ps{,-${SLOT}} \
|
|
||||||
/usr/$(exhost --target)/bin/hpc{,-${SLOT}} \
|
|
||||||
/usr/$(exhost --target)/bin/hsc2hs{,-${SLOT}} \
|
|
||||||
/usr/$(exhost --target)/bin/runghc{,-${SLOT}} \
|
|
||||||
/usr/$(exhost --target)/bin/runhaskell /usr/$(exhost --target)/bin/runghc-${SLOT}
|
|
||||||
|
|
||||||
# alternatives for manpages
|
|
||||||
local file alternatives=()
|
|
||||||
for file in "${IMAGE}"/usr/share/man/*/*; do
|
|
||||||
alternatives+=(
|
|
||||||
${file#${IMAGE}}
|
|
||||||
${file#${IMAGE}}-${SLOT}
|
|
||||||
)
|
|
||||||
done
|
|
||||||
alternatives_for \
|
|
||||||
ghc ${SLOT} ${SLOT} \
|
|
||||||
"${alternatives[@]}"
|
|
||||||
}
|
|
||||||
@@ -24,7 +24,6 @@ MYOPTIONS=""
|
|||||||
DEPENDENCIES="
|
DEPENDENCIES="
|
||||||
build+run:
|
build+run:
|
||||||
dev-python/typed-ast[>=1.1.0&<1.2.0][python_abis:*(-)?]
|
dev-python/typed-ast[>=1.1.0&<1.2.0][python_abis:*(-)?]
|
||||||
dev-python/mypy_extensions[>=0.4.0&<0.5.0][python_abis:*(-)?]
|
|
||||||
python_abis:3.4? (
|
python_abis:3.4? (
|
||||||
dev-python/typing[>=3.5.3][python_abis:3.4]
|
dev-python/typing[>=3.5.3][python_abis:3.4]
|
||||||
)
|
)
|
||||||
@@ -1,17 +0,0 @@
|
|||||||
# Copyright 2018 Alexander Kapshuna <kapsh@kap.sh>
|
|
||||||
# Distributed under the terms of the GNU General Public License v2
|
|
||||||
|
|
||||||
require pypi setup-py [ import=setuptools ]
|
|
||||||
|
|
||||||
SUMMARY="Experimental type system extensions for programs checked with the mypy typechecker"
|
|
||||||
|
|
||||||
LICENCES="MIT"
|
|
||||||
SLOT="0"
|
|
||||||
PLATFORMS="~amd64"
|
|
||||||
MYOPTIONS=""
|
|
||||||
|
|
||||||
DEPENDENCIES="
|
|
||||||
build+run:
|
|
||||||
python_abis:3.4? ( dev-python/typing[>=3.5.3][python_abis:3.4] )
|
|
||||||
"
|
|
||||||
|
|
||||||
@@ -16,6 +16,7 @@ DEPENDENCIES="
|
|||||||
build+run:
|
build+run:
|
||||||
dev-python/six[>=1.9.0][python_abis:*(-)?]
|
dev-python/six[>=1.9.0][python_abis:*(-)?]
|
||||||
dev-python/wcwidth[python_abis:*(-)?]
|
dev-python/wcwidth[python_abis:*(-)?]
|
||||||
|
|
||||||
"
|
"
|
||||||
|
|
||||||
BUGS_TO="hasufell@posteo.de"
|
BUGS_TO="hasufell@posteo.de"
|
||||||
@@ -1,234 +0,0 @@
|
|||||||
Upstream: Yes (pjsip)
|
|
||||||
Source: Backported from https://trac.pjsip.org/repos/browser/pjproject/trunk
|
|
||||||
|
|
||||||
---
|
|
||||||
deps/pjsip/aconfigure | 22 ++++++------
|
|
||||||
deps/pjsip/aconfigure.ac | 4 +--
|
|
||||||
deps/pjsip/pjlib/src/pj/ssl_sock_ossl.c | 47 +++++++++++++++++++++----
|
|
||||||
3 files changed, 53 insertions(+), 20 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/deps/pjsip/aconfigure b/deps/pjsip/aconfigure
|
|
||||||
index 530dbc3d..c413760b 100644
|
|
||||||
--- a/deps/pjsip/aconfigure
|
|
||||||
+++ b/deps/pjsip/aconfigure
|
|
||||||
@@ -6352,7 +6352,7 @@ if test "x$ac_cv_header_openssl_ssl_h" = xyes; then :
|
|
||||||
fi
|
|
||||||
|
|
||||||
|
|
||||||
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ERR_load_BIO_strings in -lcrypto" >&5
|
|
||||||
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ERR_load_BIO_strings in -lcrypto" >&5
|
|
||||||
$as_echo_n "checking for ERR_load_BIO_strings in -lcrypto... " >&6; }
|
|
||||||
if ${ac_cv_lib_crypto_ERR_load_BIO_strings+:} false; then :
|
|
||||||
$as_echo_n "(cached) " >&6
|
|
||||||
@@ -6392,9 +6392,9 @@ if test "x$ac_cv_lib_crypto_ERR_load_BIO_strings" = xyes; then :
|
|
||||||
libcrypto_present=1 && LIBS="-lcrypto $LIBS"
|
|
||||||
fi
|
|
||||||
|
|
||||||
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SSL_library_init in -lssl" >&5
|
|
||||||
-$as_echo_n "checking for SSL_library_init in -lssl... " >&6; }
|
|
||||||
-if ${ac_cv_lib_ssl_SSL_library_init+:} false; then :
|
|
||||||
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SSL_CTX_new in -lssl" >&5
|
|
||||||
+$as_echo_n "checking for SSL_CTX_new in -lssl... " >&6; }
|
|
||||||
+if ${ac_cv_lib_ssl_SSL_CTX_new+:} false; then :
|
|
||||||
$as_echo_n "(cached) " >&6
|
|
||||||
else
|
|
||||||
ac_check_lib_save_LIBS=$LIBS
|
|
||||||
@@ -6408,27 +6408,27 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
|
|
||||||
#ifdef __cplusplus
|
|
||||||
extern "C"
|
|
||||||
#endif
|
|
||||||
-char SSL_library_init ();
|
|
||||||
+char SSL_CTX_new ();
|
|
||||||
int
|
|
||||||
main ()
|
|
||||||
{
|
|
||||||
-return SSL_library_init ();
|
|
||||||
+return SSL_CTX_new ();
|
|
||||||
;
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
_ACEOF
|
|
||||||
if ac_fn_c_try_link "$LINENO"; then :
|
|
||||||
- ac_cv_lib_ssl_SSL_library_init=yes
|
|
||||||
+ ac_cv_lib_ssl_SSL_CTX_new=yes
|
|
||||||
else
|
|
||||||
- ac_cv_lib_ssl_SSL_library_init=no
|
|
||||||
+ ac_cv_lib_ssl_SSL_CTX_new=no
|
|
||||||
fi
|
|
||||||
rm -f core conftest.err conftest.$ac_objext \
|
|
||||||
conftest$ac_exeext conftest.$ac_ext
|
|
||||||
LIBS=$ac_check_lib_save_LIBS
|
|
||||||
fi
|
|
||||||
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ssl_SSL_library_init" >&5
|
|
||||||
-$as_echo "$ac_cv_lib_ssl_SSL_library_init" >&6; }
|
|
||||||
-if test "x$ac_cv_lib_ssl_SSL_library_init" = xyes; then :
|
|
||||||
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ssl_SSL_CTX_new" >&5
|
|
||||||
+$as_echo "$ac_cv_lib_ssl_SSL_CTX_new" >&6; }
|
|
||||||
+if test "x$ac_cv_lib_ssl_SSL_CTX_new" = xyes; then :
|
|
||||||
libssl_present=1 && LIBS="-lssl $LIBS"
|
|
||||||
fi
|
|
||||||
|
|
||||||
diff --git a/deps/pjsip/aconfigure.ac b/deps/pjsip/aconfigure.ac
|
|
||||||
index 89ff674e..54c65ad3 100644
|
|
||||||
--- a/deps/pjsip/aconfigure.ac
|
|
||||||
+++ b/deps/pjsip/aconfigure.ac
|
|
||||||
@@ -935,8 +935,8 @@ AC_ARG_ENABLE(ssl,
|
|
||||||
AC_SUBST(libssl_present)
|
|
||||||
AC_SUBST(libcrypto_present)
|
|
||||||
AC_CHECK_HEADER(openssl/ssl.h,[openssl_h_present=1])
|
|
||||||
- AC_CHECK_LIB(crypto,ERR_load_BIO_strings,[libcrypto_present=1 && LIBS="-lcrypto $LIBS"])
|
|
||||||
- AC_CHECK_LIB(ssl,SSL_library_init,[libssl_present=1 && LIBS="-lssl $LIBS"])
|
|
||||||
+ AC_CHECK_LIB(crypto,ERR_load_BIO_strings,[libcrypto_present=1 && LIBS="-lcrypto $LIBS"])
|
|
||||||
+ AC_CHECK_LIB(ssl,SSL_CTX_new,[libssl_present=1 && LIBS="-lssl $LIBS"])
|
|
||||||
if test "x$openssl_h_present" = "x1" -a "x$libssl_present" = "x1" -a "x$libcrypto_present" = "x1"; then
|
|
||||||
AC_MSG_RESULT([OpenSSL library found, SSL support enabled])
|
|
||||||
# PJSIP_HAS_TLS_TRANSPORT setting follows PJ_HAS_SSL_SOCK
|
|
||||||
diff --git a/deps/pjsip/pjlib/src/pj/ssl_sock_ossl.c b/deps/pjsip/pjlib/src/pj/ssl_sock_ossl.c
|
|
||||||
index 926512ba..705ed63d 100644
|
|
||||||
--- a/deps/pjsip/pjlib/src/pj/ssl_sock_ossl.c
|
|
||||||
+++ b/deps/pjsip/pjlib/src/pj/ssl_sock_ossl.c
|
|
||||||
@@ -43,15 +43,31 @@
|
|
||||||
/*
|
|
||||||
* Include OpenSSL headers
|
|
||||||
*/
|
|
||||||
+#include <openssl/asn1.h>
|
|
||||||
#include <openssl/bio.h>
|
|
||||||
#include <openssl/ssl.h>
|
|
||||||
#include <openssl/err.h>
|
|
||||||
#include <openssl/x509v3.h>
|
|
||||||
|
|
||||||
|
|
||||||
+#if !USING_LIBRESSL && OPENSSL_VERSION_NUMBER >= 0x10100000L
|
|
||||||
+# define OPENSSL_NO_SSL2 /* seems to be removed in 1.1.0 */
|
|
||||||
+# define M_ASN1_STRING_data(x) ASN1_STRING_get0_data(x)
|
|
||||||
+# define M_ASN1_STRING_length(x) ASN1_STRING_length(x)
|
|
||||||
+# if defined(OPENSSL_API_COMPAT) && OPENSSL_API_COMPAT >= 0x10100000L
|
|
||||||
+# define X509_get_notBefore(x) X509_get0_notBefore(x)
|
|
||||||
+# define X509_get_notAfter(x) X509_get0_notAfter(x)
|
|
||||||
+# endif
|
|
||||||
+#else
|
|
||||||
+# define SSL_CIPHER_get_id(c) (c)->id
|
|
||||||
+# define SSL_set_session(ssl, s) (ssl)->session = (s)
|
|
||||||
+#endif
|
|
||||||
+
|
|
||||||
+
|
|
||||||
#ifdef _MSC_VER
|
|
||||||
# pragma comment( lib, "libeay32")
|
|
||||||
# pragma comment( lib, "ssleay32")
|
|
||||||
+# pragma comment( lib, "crypt32")
|
|
||||||
#endif
|
|
||||||
|
|
||||||
|
|
||||||
@@ -319,8 +335,12 @@ static pj_status_t init_openssl(void)
|
|
||||||
pj_assert(status == PJ_SUCCESS);
|
|
||||||
|
|
||||||
/* Init OpenSSL lib */
|
|
||||||
+#if OPENSSL_VERSION_NUMBER < 0x10100000L
|
|
||||||
SSL_library_init();
|
|
||||||
SSL_load_error_strings();
|
|
||||||
+#else
|
|
||||||
+ OPENSSL_init_ssl(0, NULL);
|
|
||||||
+#endif
|
|
||||||
#if OPENSSL_VERSION_NUMBER < 0x009080ffL
|
|
||||||
/* This is now synonym of SSL_library_init() */
|
|
||||||
OpenSSL_add_all_algorithms();
|
|
||||||
@@ -334,6 +354,7 @@ static pj_status_t init_openssl(void)
|
|
||||||
STACK_OF(SSL_CIPHER) *sk_cipher;
|
|
||||||
unsigned i, n;
|
|
||||||
|
|
||||||
+#if OPENSSL_VERSION_NUMBER < 0x10100000L
|
|
||||||
meth = (SSL_METHOD*)SSLv23_server_method();
|
|
||||||
if (!meth)
|
|
||||||
meth = (SSL_METHOD*)TLSv1_server_method();
|
|
||||||
@@ -345,6 +366,12 @@ static pj_status_t init_openssl(void)
|
|
||||||
if (!meth)
|
|
||||||
meth = (SSL_METHOD*)SSLv2_server_method();
|
|
||||||
#endif
|
|
||||||
+
|
|
||||||
+#else
|
|
||||||
+ /* Specific version methods are deprecated in 1.1.0 */
|
|
||||||
+ meth = (SSL_METHOD*)TLS_method();
|
|
||||||
+#endif
|
|
||||||
+
|
|
||||||
pj_assert(meth);
|
|
||||||
|
|
||||||
ctx=SSL_CTX_new(meth);
|
|
||||||
@@ -361,7 +388,7 @@ static pj_status_t init_openssl(void)
|
|
||||||
const SSL_CIPHER *c;
|
|
||||||
c = sk_SSL_CIPHER_value(sk_cipher,i);
|
|
||||||
openssl_ciphers[i].id = (pj_ssl_cipher)
|
|
||||||
- (pj_uint32_t)c->id & 0x00FFFFFF;
|
|
||||||
+ (pj_uint32_t)SSL_CIPHER_get_id(c) & 0x00FFFFFF;
|
|
||||||
openssl_ciphers[i].name = SSL_CIPHER_get_name(c);
|
|
||||||
}
|
|
||||||
|
|
||||||
@@ -526,6 +553,7 @@ static pj_status_t create_ssl(pj_ssl_sock_t *ssock)
|
|
||||||
ssock->param.proto = PJ_SSL_SOCK_PROTO_SSL23;
|
|
||||||
|
|
||||||
/* Determine SSL method to use */
|
|
||||||
+#if OPENSSL_VERSION_NUMBER < 0x10100000L
|
|
||||||
switch (ssock->param.proto) {
|
|
||||||
case PJ_SSL_SOCK_PROTO_TLS1:
|
|
||||||
ssl_method = (SSL_METHOD*)TLSv1_method();
|
|
||||||
@@ -541,6 +569,10 @@ static pj_status_t create_ssl(pj_ssl_sock_t *ssock)
|
|
||||||
#endif
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
+#else
|
|
||||||
+ /* Specific version methods are deprecated in 1.1.0 */
|
|
||||||
+ ssl_method = (SSL_METHOD*)TLS_method();
|
|
||||||
+#endif
|
|
||||||
|
|
||||||
if (!ssl_method) {
|
|
||||||
ssl_method = (SSL_METHOD*)SSLv23_method();
|
|
||||||
@@ -869,7 +901,8 @@ static pj_status_t set_cipher_list(pj_ssl_sock_t *ssock)
|
|
||||||
const SSL_CIPHER *c;
|
|
||||||
c = sk_SSL_CIPHER_value(sk_cipher, j);
|
|
||||||
if (ssock->param.ciphers[i] == (pj_ssl_cipher)
|
|
||||||
- ((pj_uint32_t)c->id & 0x00FFFFFF))
|
|
||||||
+ ((pj_uint32_t)SSL_CIPHER_get_id(c) &
|
|
||||||
+ 0x00FFFFFF))
|
|
||||||
{
|
|
||||||
const char *c_name;
|
|
||||||
|
|
||||||
@@ -994,7 +1027,7 @@ static void get_cert_info(pj_pool_t *pool, pj_ssl_cert_info *ci, X509 *x,
|
|
||||||
pj_bool_t update_needed;
|
|
||||||
char buf[512];
|
|
||||||
pj_uint8_t serial_no[64] = {0}; /* should be >= sizeof(ci->serial_no) */
|
|
||||||
- pj_uint8_t *q;
|
|
||||||
+ const pj_uint8_t *q;
|
|
||||||
unsigned len;
|
|
||||||
GENERAL_NAMES *names = NULL;
|
|
||||||
|
|
||||||
@@ -1004,7 +1037,7 @@ static void get_cert_info(pj_pool_t *pool, pj_ssl_cert_info *ci, X509 *x,
|
|
||||||
X509_NAME_oneline(X509_get_issuer_name(x), buf, sizeof(buf));
|
|
||||||
|
|
||||||
/* Get serial no */
|
|
||||||
- q = (pj_uint8_t*) M_ASN1_STRING_data(X509_get_serialNumber(x));
|
|
||||||
+ q = (const pj_uint8_t*) M_ASN1_STRING_data(X509_get_serialNumber(x));
|
|
||||||
len = M_ASN1_STRING_length(X509_get_serialNumber(x));
|
|
||||||
if (len > sizeof(ci->serial_no))
|
|
||||||
len = sizeof(ci->serial_no);
|
|
||||||
@@ -1075,8 +1108,8 @@ static void get_cert_info(pj_pool_t *pool, pj_ssl_cert_info *ci, X509 *x,
|
|
||||||
type = PJ_SSL_CERT_NAME_URI;
|
|
||||||
break;
|
|
||||||
case GEN_IPADD:
|
|
||||||
- p = ASN1_STRING_data(name->d.ip);
|
|
||||||
- len = ASN1_STRING_length(name->d.ip);
|
|
||||||
+ p = (unsigned char*)M_ASN1_STRING_data(name->d.ip);
|
|
||||||
+ len = M_ASN1_STRING_length(name->d.ip);
|
|
||||||
type = PJ_SSL_CERT_NAME_IP;
|
|
||||||
break;
|
|
||||||
default:
|
|
||||||
@@ -2300,7 +2333,7 @@ PJ_DEF(pj_status_t) pj_ssl_sock_get_info (pj_ssl_sock_t *ssock,
|
|
||||||
|
|
||||||
/* Current cipher */
|
|
||||||
cipher = SSL_get_current_cipher(ssock->ossl_ssl);
|
|
||||||
- info->cipher = (cipher->id & 0x00FFFFFF);
|
|
||||||
+ info->cipher = (SSL_CIPHER_get_id(cipher) & 0x00FFFFFF);
|
|
||||||
|
|
||||||
/* Remote address */
|
|
||||||
pj_sockaddr_cp(&info->remote_addr, &ssock->rem_addr);
|
|
||||||
--
|
|
||||||
2.19.2
|
|
||||||
|
|
||||||
@@ -1,273 +0,0 @@
|
|||||||
Upstream: Patch Submitted
|
|
||||||
|
|
||||||
|
|
||||||
commit 7ec01af311d21e339208c68d03c1430c8b210073
|
|
||||||
Author: Tom Briden <tom@decompile.me.uk>
|
|
||||||
Date: Wed Nov 28 17:51:41 2018 +0000
|
|
||||||
|
|
||||||
zsrtp: Add support for openssl-1.1
|
|
||||||
|
|
||||||
diff --git a/deps/pjsip/third_party/zsrtp/include/openssl_compat.h b/deps/pjsip/third_party/zsrtp/include/openssl_compat.h
|
|
||||||
new file mode 100644
|
|
||||||
index 00000000..cf2e8179
|
|
||||||
--- /dev/null
|
|
||||||
+++ b/deps/pjsip/third_party/zsrtp/include/openssl_compat.h
|
|
||||||
@@ -0,0 +1,22 @@
|
|
||||||
+#ifndef _OPENSSL_COMPAT
|
|
||||||
+#define _OPENSSL_COMPAT
|
|
||||||
+
|
|
||||||
+#if (OPENSSL_VERSION_NUMBER < 0x10100000L) || defined (LIBRESSL_VERSION_NUMBER)
|
|
||||||
+static HMAC_CTX *HMAC_CTX_new(void)
|
|
||||||
+{
|
|
||||||
+ HMAC_CTX *ctx = (HMAC_CTX*)OPENSSL_malloc(sizeof(*ctx));
|
|
||||||
+ if (ctx != NULL)
|
|
||||||
+ HMAC_CTX_init(ctx);
|
|
||||||
+ return ctx;
|
|
||||||
+}
|
|
||||||
+
|
|
||||||
+static void HMAC_CTX_free(HMAC_CTX *ctx)
|
|
||||||
+{
|
|
||||||
+ if (ctx != NULL) {
|
|
||||||
+ HMAC_CTX_cleanup(ctx);
|
|
||||||
+ OPENSSL_free(ctx);
|
|
||||||
+ }
|
|
||||||
+}
|
|
||||||
+#endif
|
|
||||||
+
|
|
||||||
+#endif
|
|
||||||
diff --git a/deps/pjsip/third_party/zsrtp/zrtp/srtp/crypto/openssl/hmac.cpp b/deps/pjsip/third_party/zsrtp/zrtp/srtp/crypto/openssl/hmac.cpp
|
|
||||||
index 6cdb6b14..605285dd 100644
|
|
||||||
--- a/deps/pjsip/third_party/zsrtp/zrtp/srtp/crypto/openssl/hmac.cpp
|
|
||||||
+++ b/deps/pjsip/third_party/zsrtp/zrtp/srtp/crypto/openssl/hmac.cpp
|
|
||||||
@@ -37,6 +37,8 @@
|
|
||||||
#include <openssl/hmac.h>
|
|
||||||
#include <crypto/hmac.h>
|
|
||||||
|
|
||||||
+#include <openssl_compat.h>
|
|
||||||
+
|
|
||||||
#if defined(__APPLE__)
|
|
||||||
# pragma GCC diagnostic push
|
|
||||||
# pragma GCC diagnostic ignored "-Wdeprecated-declarations"
|
|
||||||
@@ -55,23 +57,21 @@ void hmac_sha1( uint8_t* key, int32_t key_length,
|
|
||||||
const uint8_t* data_chunks[],
|
|
||||||
uint32_t data_chunck_length[],
|
|
||||||
uint8_t* mac, int32_t* mac_length ) {
|
|
||||||
- HMAC_CTX ctx;
|
|
||||||
- HMAC_CTX_init(&ctx);
|
|
||||||
- HMAC_Init_ex(&ctx, key, key_length, EVP_sha1(), NULL);
|
|
||||||
+ HMAC_CTX* ctx = HMAC_CTX_new();
|
|
||||||
+ HMAC_Init_ex(ctx, key, key_length, EVP_sha1(), NULL);
|
|
||||||
while (*data_chunks) {
|
|
||||||
- HMAC_Update(&ctx, *data_chunks, *data_chunck_length);
|
|
||||||
+ HMAC_Update(ctx, *data_chunks, *data_chunck_length);
|
|
||||||
data_chunks ++;
|
|
||||||
data_chunck_length ++;
|
|
||||||
}
|
|
||||||
- HMAC_Final(&ctx, mac, reinterpret_cast<uint32_t*>(mac_length));
|
|
||||||
- HMAC_CTX_cleanup(&ctx);
|
|
||||||
+ HMAC_Final(ctx, mac, reinterpret_cast<uint32_t*>(mac_length));
|
|
||||||
+ HMAC_CTX_free(ctx);
|
|
||||||
}
|
|
||||||
|
|
||||||
void* createSha1HmacContext(uint8_t* key, int32_t key_length)
|
|
||||||
{
|
|
||||||
- HMAC_CTX* ctx = (HMAC_CTX*)malloc(sizeof(HMAC_CTX));
|
|
||||||
+ HMAC_CTX* ctx = HMAC_CTX_new();
|
|
||||||
|
|
||||||
- HMAC_CTX_init(ctx);
|
|
||||||
HMAC_Init_ex(ctx, key, key_length, EVP_sha1(), NULL);
|
|
||||||
return ctx;
|
|
||||||
}
|
|
||||||
@@ -80,7 +80,11 @@ void* initializeSha1HmacContext(void* ctx, uint8_t* key, int32_t keyLength)
|
|
||||||
{
|
|
||||||
HMAC_CTX *pctx = (HMAC_CTX*)ctx;
|
|
||||||
|
|
||||||
+#if (OPENSSL_VERSION_NUMBER < 0x10100000L) || defined (LIBRESSL_VERSION_NUMBER)
|
|
||||||
HMAC_CTX_init(pctx);
|
|
||||||
+#else
|
|
||||||
+ HMAC_CTX_reset(pctx);
|
|
||||||
+#endif
|
|
||||||
HMAC_Init_ex(pctx, key, keyLength, EVP_sha1(), NULL);
|
|
||||||
return pctx;
|
|
||||||
}
|
|
||||||
@@ -112,8 +116,7 @@ void hmacSha1Ctx(void* ctx, const uint8_t* data[], uint32_t data_length[],
|
|
||||||
void freeSha1HmacContext(void* ctx)
|
|
||||||
{
|
|
||||||
if (ctx) {
|
|
||||||
- HMAC_CTX_cleanup((HMAC_CTX*)ctx);
|
|
||||||
- free(ctx);
|
|
||||||
+ HMAC_CTX_free((HMAC_CTX*)ctx);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
diff --git a/deps/pjsip/third_party/zsrtp/zrtp/zrtp/crypto/openssl/hmac256.cpp b/deps/pjsip/third_party/zsrtp/zrtp/zrtp/crypto/openssl/hmac256.cpp
|
|
||||||
index 0953ad5c..2dd6f807 100644
|
|
||||||
--- a/deps/pjsip/third_party/zsrtp/zrtp/zrtp/crypto/openssl/hmac256.cpp
|
|
||||||
+++ b/deps/pjsip/third_party/zsrtp/zrtp/zrtp/crypto/openssl/hmac256.cpp
|
|
||||||
@@ -38,6 +38,8 @@
|
|
||||||
#include <openssl/hmac.h>
|
|
||||||
#include <crypto/hmac256.h>
|
|
||||||
|
|
||||||
+#include "openssl_compat.h"
|
|
||||||
+
|
|
||||||
#if defined(__APPLE__)
|
|
||||||
# pragma GCC diagnostic push
|
|
||||||
# pragma GCC diagnostic ignored "-Wdeprecated-declarations"
|
|
||||||
@@ -58,17 +60,16 @@ void hmac_sha256(uint8_t* key, uint32_t key_length,
|
|
||||||
uint8_t* mac, uint32_t* mac_length )
|
|
||||||
{
|
|
||||||
unsigned int tmp;
|
|
||||||
- HMAC_CTX ctx;
|
|
||||||
- HMAC_CTX_init( &ctx );
|
|
||||||
- HMAC_Init_ex( &ctx, key, key_length, EVP_sha256(), NULL );
|
|
||||||
+ HMAC_CTX* ctx = HMAC_CTX_new();
|
|
||||||
+ HMAC_Init_ex( ctx, key, key_length, EVP_sha256(), NULL );
|
|
||||||
while( *data_chunks ){
|
|
||||||
- HMAC_Update( &ctx, *data_chunks, *data_chunck_length );
|
|
||||||
+ HMAC_Update( ctx, *data_chunks, *data_chunck_length );
|
|
||||||
data_chunks ++;
|
|
||||||
data_chunck_length ++;
|
|
||||||
}
|
|
||||||
- HMAC_Final( &ctx, mac, &tmp);
|
|
||||||
+ HMAC_Final( ctx, mac, &tmp);
|
|
||||||
*mac_length = tmp;
|
|
||||||
- HMAC_CTX_cleanup( &ctx );
|
|
||||||
+ HMAC_CTX_free( ctx );
|
|
||||||
}
|
|
||||||
|
|
||||||
#if defined(__APPLE__)
|
|
||||||
diff --git a/deps/pjsip/third_party/zsrtp/zrtp/zrtp/crypto/openssl/hmac384.cpp b/deps/pjsip/third_party/zsrtp/zrtp/zrtp/crypto/openssl/hmac384.cpp
|
|
||||||
index f1dd5abc..28191f4c 100644
|
|
||||||
--- a/deps/pjsip/third_party/zsrtp/zrtp/zrtp/crypto/openssl/hmac384.cpp
|
|
||||||
+++ b/deps/pjsip/third_party/zsrtp/zrtp/zrtp/crypto/openssl/hmac384.cpp
|
|
||||||
@@ -38,6 +38,8 @@
|
|
||||||
#include <openssl/hmac.h>
|
|
||||||
#include <zrtp/crypto/hmac256.h>
|
|
||||||
|
|
||||||
+#include "openssl_compat.h"
|
|
||||||
+
|
|
||||||
#if defined(__APPLE__)
|
|
||||||
# pragma GCC diagnostic push
|
|
||||||
# pragma GCC diagnostic ignored "-Wdeprecated-declarations"
|
|
||||||
@@ -56,17 +58,16 @@ void hmac_sha384(uint8_t* key, uint32_t key_length,
|
|
||||||
uint8_t* mac, uint32_t* mac_length )
|
|
||||||
{
|
|
||||||
unsigned int tmp;
|
|
||||||
- HMAC_CTX ctx;
|
|
||||||
- HMAC_CTX_init( &ctx );
|
|
||||||
- HMAC_Init_ex( &ctx, key, key_length, EVP_sha384(), NULL );
|
|
||||||
+ HMAC_CTX* ctx = HMAC_CTX_new();
|
|
||||||
+ HMAC_Init_ex( ctx, key, key_length, EVP_sha384(), NULL );
|
|
||||||
while( *data_chunks ){
|
|
||||||
- HMAC_Update( &ctx, *data_chunks, *data_chunck_length );
|
|
||||||
+ HMAC_Update( ctx, *data_chunks, *data_chunck_length );
|
|
||||||
data_chunks ++;
|
|
||||||
data_chunck_length ++;
|
|
||||||
}
|
|
||||||
- HMAC_Final( &ctx, mac, &tmp);
|
|
||||||
+ HMAC_Final( ctx, mac, &tmp);
|
|
||||||
*mac_length = tmp;
|
|
||||||
- HMAC_CTX_cleanup( &ctx );
|
|
||||||
+ HMAC_CTX_free( ctx );
|
|
||||||
}
|
|
||||||
|
|
||||||
#if defined(__APPLE__)
|
|
||||||
diff --git a/deps/pjsip/third_party/zsrtp/zrtp/zrtp/crypto/openssl/zrtpDH.cpp b/deps/pjsip/third_party/zsrtp/zrtp/zrtp/crypto/openssl/zrtpDH.cpp
|
|
||||||
index 2623d2a3..76089951 100644
|
|
||||||
--- a/deps/pjsip/third_party/zsrtp/zrtp/zrtp/crypto/openssl/zrtpDH.cpp
|
|
||||||
+++ b/deps/pjsip/third_party/zsrtp/zrtp/zrtp/crypto/openssl/zrtpDH.cpp
|
|
||||||
@@ -223,24 +223,35 @@ ZrtpDH::ZrtpDH(const char* type) {
|
|
||||||
}
|
|
||||||
|
|
||||||
DH* tmpCtx = NULL;
|
|
||||||
+ BIGNUM *p = NULL;
|
|
||||||
+ BIGNUM* priv_key = NULL;
|
|
||||||
+ BIGNUM *g = BN_new();
|
|
||||||
switch (pkType) {
|
|
||||||
case DH2K:
|
|
||||||
case DH3K:
|
|
||||||
ctx = static_cast<void*>(DH_new());
|
|
||||||
tmpCtx = static_cast<DH*>(ctx);
|
|
||||||
- tmpCtx->g = BN_new();
|
|
||||||
- BN_set_word(tmpCtx->g, DH_GENERATOR_2);
|
|
||||||
+ BN_set_word(g, DH_GENERATOR_2);
|
|
||||||
|
|
||||||
if (pkType == DH2K) {
|
|
||||||
- tmpCtx->p = BN_dup(bnP2048);
|
|
||||||
+ p = BN_dup(bnP2048);
|
|
||||||
RAND_bytes(random, 32);
|
|
||||||
- tmpCtx->priv_key = BN_bin2bn(random, 32, NULL);
|
|
||||||
+ priv_key = BN_bin2bn(random, 32, NULL);
|
|
||||||
}
|
|
||||||
else if (pkType == DH3K) {
|
|
||||||
- tmpCtx->p = BN_dup(bnP3072);
|
|
||||||
+ p = BN_dup(bnP3072);
|
|
||||||
RAND_bytes(random, 64);
|
|
||||||
- tmpCtx->priv_key = BN_bin2bn(random, 32, NULL);
|
|
||||||
+ priv_key = BN_bin2bn(random, 32, NULL);
|
|
||||||
}
|
|
||||||
+
|
|
||||||
+#if (OPENSSL_VERSION_NUMBER < 0x10100000L) || defined (LIBRESSL_VERSION_NUMBER)
|
|
||||||
+ tmpCtx->g = g;
|
|
||||||
+ tmpCtx->p = p;
|
|
||||||
+ tmpCtx->priv_key = priv_key;
|
|
||||||
+#else
|
|
||||||
+ DH_set0_pqg(tmpCtx, p, NULL, g);
|
|
||||||
+ DH_set0_key(tmpCtx, NULL, priv_key);
|
|
||||||
+#endif
|
|
||||||
break;
|
|
||||||
|
|
||||||
case EC25:
|
|
||||||
@@ -274,11 +285,16 @@ int32_t ZrtpDH::computeSecretKey(uint8_t *pubKeyBytes, uint8_t *secret) {
|
|
||||||
if (pkType == DH2K || pkType == DH3K) {
|
|
||||||
DH* tmpCtx = static_cast<DH*>(ctx);
|
|
||||||
|
|
||||||
+ BIGNUM* pub_key = BN_bin2bn(pubKeyBytes, getDhSize(), NULL);
|
|
||||||
+#if (OPENSSL_VERSION_NUMBER < 0x10100000L) || defined (LIBRESSL_VERSION_NUMBER)
|
|
||||||
if (tmpCtx->pub_key != NULL) {
|
|
||||||
- BN_free(tmpCtx->pub_key);
|
|
||||||
+ BN_free(tmpCtx->pub_key);
|
|
||||||
}
|
|
||||||
- tmpCtx->pub_key = BN_bin2bn(pubKeyBytes, getDhSize(), NULL);
|
|
||||||
- return DH_compute_key(secret, tmpCtx->pub_key, tmpCtx);
|
|
||||||
+ tmpCtx->pub_key = pub_key;
|
|
||||||
+#else
|
|
||||||
+ DH_set0_key(tmpCtx, pub_key, NULL);
|
|
||||||
+#endif
|
|
||||||
+ return DH_compute_key(secret, pub_key, tmpCtx);
|
|
||||||
}
|
|
||||||
if (pkType == EC25 || pkType == EC38) {
|
|
||||||
uint8_t buffer[100];
|
|
||||||
@@ -323,8 +339,15 @@ int32_t ZrtpDH::getDhSize() const
|
|
||||||
|
|
||||||
int32_t ZrtpDH::getPubKeySize() const
|
|
||||||
{
|
|
||||||
- if (pkType == DH2K || pkType == DH3K)
|
|
||||||
- return BN_num_bytes(static_cast<DH*>(ctx)->pub_key);
|
|
||||||
+ if (pkType == DH2K || pkType == DH3K){
|
|
||||||
+ const BIGNUM* pub_key;
|
|
||||||
+#if (OPENSSL_VERSION_NUMBER < 0x10100000L) || defined (LIBRESSL_VERSION_NUMBER)
|
|
||||||
+ pub_key = static_cast<DH*>(ctx)->pub_key;
|
|
||||||
+#else
|
|
||||||
+ DH_get0_key(static_cast<DH*>(ctx), &pub_key, NULL);
|
|
||||||
+#endif
|
|
||||||
+ return BN_num_bytes(pub_key);
|
|
||||||
+ }
|
|
||||||
|
|
||||||
if (pkType == EC25 || pkType == EC38)
|
|
||||||
return EC_POINT_point2oct(EC_KEY_get0_group(static_cast<EC_KEY*>(ctx)),
|
|
||||||
@@ -343,7 +366,13 @@ int32_t ZrtpDH::getPubKeyBytes(uint8_t *buf) const
|
|
||||||
if (prepend > 0) {
|
|
||||||
memset(buf, 0, prepend);
|
|
||||||
}
|
|
||||||
- return BN_bn2bin(static_cast<DH*>(ctx)->pub_key, buf + prepend);
|
|
||||||
+ const BIGNUM* pub_key;
|
|
||||||
+#if (OPENSSL_VERSION_NUMBER < 0x10100000L) || defined (LIBRESSL_VERSION_NUMBER)
|
|
||||||
+ pub_key = static_cast<DH*>(ctx)->pub_key;
|
|
||||||
+#else
|
|
||||||
+ DH_get0_key(static_cast<DH*>(ctx), &pub_key, NULL);
|
|
||||||
+#endif
|
|
||||||
+ return BN_bn2bin(pub_key, buf + prepend);
|
|
||||||
}
|
|
||||||
if (pkType == EC25 || pkType == EC38) {
|
|
||||||
uint8_t buffer[100];
|
|
||||||
@@ -49,8 +49,6 @@ DEPENDENCIES="
|
|||||||
DEFAULT_SRC_PREPARE_PATCHES=(
|
DEFAULT_SRC_PREPARE_PATCHES=(
|
||||||
"${FILES}"/${PNV}-fix-build.patch
|
"${FILES}"/${PNV}-fix-build.patch
|
||||||
"${FILES}"/${PNV}-pjmedia-ffmpeg-fix.patch
|
"${FILES}"/${PNV}-pjmedia-ffmpeg-fix.patch
|
||||||
"${FILES}"/${PN}-support-openssl-1.1_01.patch
|
|
||||||
"${FILES}"/${PN}-support-openssl-1.1_02.patch
|
|
||||||
-p0 "${FILES}"/${PNV}-pjmedia-openh264-1.6.patch
|
-p0 "${FILES}"/${PNV}-pjmedia-openh264-1.6.patch
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|||||||
@@ -1,35 +0,0 @@
|
|||||||
# Copyright 2018 Julian Ospald <hasufell@posteo.de>
|
|
||||||
# Distributed under the terms of the GNU General Public License v2
|
|
||||||
|
|
||||||
require github [ user=mhagger tag="v${PV}" ]
|
|
||||||
require python [ has_bin=true multibuild=false blacklist=2 ]
|
|
||||||
require bash-completion
|
|
||||||
|
|
||||||
SUMMARY="Incremental merge for git"
|
|
||||||
|
|
||||||
LICENCES="GPL-2.0"
|
|
||||||
SLOT="0"
|
|
||||||
PLATFORMS="~amd64 ~x86"
|
|
||||||
MYOPTIONS=""
|
|
||||||
|
|
||||||
DEPENDENCIES="
|
|
||||||
run:
|
|
||||||
dev-scm/git
|
|
||||||
"
|
|
||||||
|
|
||||||
BUGS_TO="hasufell@posteo.de"
|
|
||||||
|
|
||||||
src_prepare() {
|
|
||||||
default
|
|
||||||
|
|
||||||
# fix shebang
|
|
||||||
edo sed -i \
|
|
||||||
-e "s:/usr/bin/env python.*$:/usr/$(exhost --target)/bin/env ${PYTHON##*/}:" \
|
|
||||||
${PN}
|
|
||||||
}
|
|
||||||
|
|
||||||
src_install() {
|
|
||||||
dodoc README.rst
|
|
||||||
dobashcompletion ${PN}.bashcomplete
|
|
||||||
dobin ${PN}
|
|
||||||
}
|
|
||||||
@@ -5,9 +5,10 @@
|
|||||||
# Copyright 1999-2015 Gentoo Foundation
|
# Copyright 1999-2015 Gentoo Foundation
|
||||||
# Distributed under the terms of the GNU General Public License v2
|
# Distributed under the terms of the GNU General Public License v2
|
||||||
|
|
||||||
require udev-rules github [ user=gentoo tag=${PV} ]
|
require udev-rules
|
||||||
|
|
||||||
HOMEPAGE="https://www.gentoo.org/proj/en/base/openrc/"
|
HOMEPAGE="https://www.gentoo.org/proj/en/base/openrc/"
|
||||||
|
DOWNLOADS="https://dev.gentoo.org/~robbat2/distfiles/${PNV}.tar.bz2"
|
||||||
|
|
||||||
SUMMARY="Gentoo Network Interface Management Scripts"
|
SUMMARY="Gentoo Network Interface Management Scripts"
|
||||||
LICENCES="BSD-2"
|
LICENCES="BSD-2"
|
||||||
@@ -33,7 +34,7 @@ src_compile() {
|
|||||||
|
|
||||||
src_install() {
|
src_install() {
|
||||||
emake ${MAKE_ARGS} DESTDIR="${IMAGE}" install
|
emake ${MAKE_ARGS} DESTDIR="${IMAGE}" install
|
||||||
dodoc README CREDITS FEATURE-REMOVAL-SCHEDULE STYLE TODO
|
dodoc README CREDITS FEATURE-REMOVAL-SCHEDULE STYLE TODO ChangeLog
|
||||||
}
|
}
|
||||||
|
|
||||||
pkg_postinst() {
|
pkg_postinst() {
|
||||||
@@ -12,10 +12,7 @@ Remmina is a remote desktop client written in GTK+, aiming to be useful for syst
|
|||||||
HOMEPAGE+=" http://remmina.org/"
|
HOMEPAGE+=" http://remmina.org/"
|
||||||
|
|
||||||
LICENCES="GPL-2"
|
LICENCES="GPL-2"
|
||||||
MYOPTIONS="
|
MYOPTIONS="ssh"
|
||||||
ssh
|
|
||||||
( providers: libressl openssl ) [[ number-selected = exactly-one ]]
|
|
||||||
"
|
|
||||||
|
|
||||||
DEPENDENCIES="
|
DEPENDENCIES="
|
||||||
build:
|
build:
|
||||||
@@ -39,8 +36,6 @@ DEPENDENCIES="
|
|||||||
net-libs/libssh
|
net-libs/libssh
|
||||||
dev-libs/vte:2.91
|
dev-libs/vte:2.91
|
||||||
)
|
)
|
||||||
providers:libressl? ( dev-libs/libressl:= )
|
|
||||||
providers:openssl? ( dev-libs/openssl )
|
|
||||||
"
|
"
|
||||||
|
|
||||||
BUGS_TO="hasufell@posteo.de"
|
BUGS_TO="hasufell@posteo.de"
|
||||||
@@ -65,4 +60,3 @@ CMAKE_SRC_CONFIGURE_OPTION_WITHS=(
|
|||||||
"ssh LIBSSH"
|
"ssh LIBSSH"
|
||||||
"ssh VTE"
|
"ssh VTE"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@ require freedesktop-desktop
|
|||||||
|
|
||||||
SUMMARY="Next generation Brave browser"
|
SUMMARY="Next generation Brave browser"
|
||||||
HOMEPAGE="https://brave-browser.readthedocs.io"
|
HOMEPAGE="https://brave-browser.readthedocs.io"
|
||||||
DOWNLOADS="https://github.com/brave/brave-browser/releases/download/v${PV}/brave-browser_${PV}_amd64.deb"
|
DOWNLOADS="https://brave-browser-apt-dev.s3.brave.com/pool/main/b/${PN}/${PN}_0.50.14_amd64.deb"
|
||||||
|
|
||||||
LICENCES="MPL-2.0"
|
LICENCES="MPL-2.0"
|
||||||
SLOT="0"
|
SLOT="0"
|
||||||
@@ -60,17 +60,17 @@ src_unpack() {
|
|||||||
src_install() {
|
src_install() {
|
||||||
local f
|
local f
|
||||||
|
|
||||||
edo mv usr/share/doc/brave-browser usr/share/doc/${PNV}
|
edo mv usr/share/doc/${PN} usr/share/doc/${PNV}
|
||||||
insinto /usr/share
|
insinto /usr/share
|
||||||
doins -r usr/share/*
|
doins -r usr/share/*
|
||||||
|
|
||||||
insinto /opt
|
insinto /opt
|
||||||
doins -r opt/*
|
doins -r opt/*
|
||||||
for f in "${IMAGE}"/opt/brave.com/brave/{brave-browser,brave,brave-sandbox} ; do
|
for f in "${IMAGE}"/opt/brave.com/brave-dev/{${PN},brave,brave-sandbox} ; do
|
||||||
edo chmod +x "${f}"
|
edo chmod +x "${f}"
|
||||||
done
|
done
|
||||||
|
|
||||||
dodir /usr/$(exhost --target)/bin
|
dodir /usr/$(exhost --target)/bin
|
||||||
dosym ../../../opt/brave.com/brave/brave-browser /usr/$(exhost --target)/bin/${PN}
|
dosym ../../../opt/brave.com/brave-dev/${PN} /usr/$(exhost --target)/bin/${PN}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1,22 +0,0 @@
|
|||||||
# Copyright 2018 Julian Ospald <hasufell@posteo.de>
|
|
||||||
# Distributed under the terms of the GNU General Public License v2
|
|
||||||
|
|
||||||
SUMMARY="Virtual: The Glasgow Haskell Compiler"
|
|
||||||
HOMEPAGE=""
|
|
||||||
|
|
||||||
SLOT="0"
|
|
||||||
PLATFORMS="~amd64"
|
|
||||||
MYOPTIONS="
|
|
||||||
( providers:
|
|
||||||
ghc-bin
|
|
||||||
GHC
|
|
||||||
) [[
|
|
||||||
*description = [ ghc provider ]
|
|
||||||
number-selected = at-most-one
|
|
||||||
]]
|
|
||||||
"
|
|
||||||
|
|
||||||
DEPENDENCIES="
|
|
||||||
providers:ghc-bin? ( dev-lang/ghc-bin )
|
|
||||||
providers:GHC? ( dev-lang/GHC )
|
|
||||||
"
|
|
||||||
@@ -1,3 +1,3 @@
|
|||||||
* dev-haskell/cabal-install-bin
|
* dev-haskell/cabal-install-bin
|
||||||
* virtual/GHC
|
* dev-lang/ghc-bin
|
||||||
? dev-haskell/stack-bin
|
? dev-haskell/stack-bin
|
||||||
|
|||||||
Reference in New Issue
Block a user