Gentoo Archives: gentoo-commits

From: Johannes Huber <johu@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-cpp/websocketpp/, dev-cpp/websocketpp/files/
Date: Wed, 27 Jun 2018 09:36:42
Message-Id: 1530092187.a55bc34dbeda74f9ad1d6b4bf525e1327ec094bc.johu@gentoo
1 commit: a55bc34dbeda74f9ad1d6b4bf525e1327ec094bc
2 Author: Johannes Huber <johu <AT> gentoo <DOT> org>
3 AuthorDate: Wed Jun 27 09:32:48 2018 +0000
4 Commit: Johannes Huber <johu <AT> gentoo <DOT> org>
5 CommitDate: Wed Jun 27 09:36:27 2018 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a55bc34d
7
8 dev-cpp/websocketpp: Fix cmake install path
9
10 Revision bump adds patch by me to fix install paths.
11
12 Reported-by: Balint SZENTE <balint <AT> szentedwg.ro>
13 Closes: https://bugs.gentoo.org/658096
14 Package-Manager: Portage-2.3.41, Repoman-2.3.9
15
16 .../files/websocketpp-0.7.0-cmake-install.patch | 28 ++++++++++++++++
17 dev-cpp/websocketpp/websocketpp-0.7.0-r2.ebuild | 39 ++++++++++++++++++++++
18 2 files changed, 67 insertions(+)
19
20 diff --git a/dev-cpp/websocketpp/files/websocketpp-0.7.0-cmake-install.patch b/dev-cpp/websocketpp/files/websocketpp-0.7.0-cmake-install.patch
21 new file mode 100644
22 index 00000000000..4548c650759
23 --- /dev/null
24 +++ b/dev-cpp/websocketpp/files/websocketpp-0.7.0-cmake-install.patch
25 @@ -0,0 +1,28 @@
26 +diff --git a/CMakeLists.txt b/CMakeLists.txt
27 +index f60caa1..9ff2211 100644
28 +--- a/CMakeLists.txt
29 ++++ b/CMakeLists.txt
30 +@@ -15,13 +15,20 @@ set (WEBSOCKETPP_VERSION ${WEBSOCKETPP_MAJOR_VERSION}.${WEBSOCKETPP_MINOR_VERSIO
31 +
32 + set_property(GLOBAL PROPERTY USE_FOLDERS ON)
33 +
34 ++get_property(LIB64 GLOBAL PROPERTY FIND_LIBRARY_USE_LIB64_PATHS)
35 ++if ("${LIB64}" STREQUAL "TRUE")
36 ++ set(LIBSUFFIX 64)
37 ++else()
38 ++ set(LIBSUFFIX "")
39 ++endif()
40 ++
41 + set(INSTALL_INCLUDE_DIR include CACHE PATH "Installation directory for header files")
42 ++set(LIB_INSTALL_DIR "lib${LIB_SUFFIX}")
43 + if (WIN32 AND NOT CYGWIN)
44 +- set (DEF_INSTALL_CMAKE_DIR cmake)
45 ++ set (INSTALL_CMAKE_DIR cmake)
46 + else ()
47 +- set (DEF_INSTALL_CMAKE_DIR lib/cmake/websocketpp)
48 ++ set (INSTALL_CMAKE_DIR ${LIB_INSTALL_DIR}/cmake/websocketpp)
49 + endif ()
50 +-set (INSTALL_CMAKE_DIR ${DEF_INSTALL_CMAKE_DIR} CACHE PATH "Installation directory for CMake files")
51 +
52 + # Make relative paths absolute (needed later on)
53 + foreach (p INCLUDE CMAKE)
54
55 diff --git a/dev-cpp/websocketpp/websocketpp-0.7.0-r2.ebuild b/dev-cpp/websocketpp/websocketpp-0.7.0-r2.ebuild
56 new file mode 100644
57 index 00000000000..1f3730df214
58 --- /dev/null
59 +++ b/dev-cpp/websocketpp/websocketpp-0.7.0-r2.ebuild
60 @@ -0,0 +1,39 @@
61 +# Copyright 1999-2018 Gentoo Foundation
62 +# Distributed under the terms of the GNU General Public License v2
63 +
64 +EAPI=6
65 +
66 +inherit cmake-utils
67 +
68 +DESCRIPTION="C++/Boost Asio based websocket client/server library"
69 +HOMEPAGE="http://www.zaphoyd.com/websocketpp"
70 +SRC_URI="https://github.com/zaphoyd/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
71 +
72 +KEYWORDS="~amd64 ~arm ~arm64 ~ia64 ~ppc64 ~x86"
73 +LICENSE="BSD"
74 +SLOT="0"
75 +IUSE="boost examples test"
76 +
77 +DEPEND=""
78 +RDEPEND="${DEPEND}
79 + boost? ( dev-libs/boost )
80 +"
81 +
82 +# bug 630450
83 +RESTRICT="test"
84 +
85 +PATCHES=( "${FILESDIR}/${P}-cmake-install.patch" )
86 +
87 +src_configure() {
88 + local mycmakeargs=(
89 + -DENABLE_CPP11="$(usex !boost)"
90 + -DBUILD_TESTS="$(usex test)"
91 + )
92 +
93 + cmake-utils_src_configure
94 +}
95 +
96 +src_install() {
97 + use examples && DOCS=( examples/ )
98 + cmake-utils_src_install
99 +}