diff options
author | 2019-06-21 12:26:01 +0200 | |
---|---|---|
committer | 2019-06-21 12:26:01 +0200 | |
commit | 8ae207615124b0e39e4164b85491a334b3b3bece (patch) | |
tree | e7d6f91f1367e42dd17793ef6c7df022944be25b | |
parent | Added aseprite-1.2.12(.1) (diff) | |
download | Drauthius-8ae207615124b0e39e4164b85491a334b3b3bece.tar.gz Drauthius-8ae207615124b0e39e4164b85491a334b3b3bece.tar.bz2 Drauthius-8ae207615124b0e39e4164b85491a334b3b3bece.zip |
Fixed problem with building Godot with LLVM/clang.
Signed-off-by: Albert Diserholt <albert@diserholt.com>
-rw-r--r-- | dev-games/godot/Manifest | 4 | ||||
-rw-r--r-- | dev-games/godot/godot-3.1.1.ebuild | 35 | ||||
-rw-r--r-- | dev-games/godot/godot-3.1.ebuild | 126 |
3 files changed, 33 insertions, 132 deletions
diff --git a/dev-games/godot/Manifest b/dev-games/godot/Manifest index 8afd39c..ebbd1c4 100644 --- a/dev-games/godot/Manifest +++ b/dev-games/godot/Manifest @@ -1,4 +1,2 @@ -DIST 3.1-stable.zip 25495857 BLAKE2B 321323b21b9d845939b94e60d9cfc7894cbbb6b09ba8d8d8fbaa1440441dd14fa5d2ba8fb67738f965fc4f64d2dd6c11802cb1e49cb6dced6b514983cb070302 SHA512 df9c2a3d41095403321a3afba0c4943253723bbc602d4d5c238e31a25ce7f3660f066d1051e8c725f567d08f5a0a4f28c738d82aacbfc025e60f1a188c5692fe DIST 3.1.1-stable.zip 25427059 BLAKE2B 85c4df448f5af7f96a3f5a3ba8e23e7764f83e1a43b21807ccf3ba66356aa3ec1dc56242dcf7d0c7d1d9efcba56b7eab8cfc32e314d1f35978bd34d2c300f65e SHA512 509b144be7416174a487548b5708367f7ce743b0268a710d0dc9a9fb095eb368a218bf5cd591f38f90bb9a96fa24acab442c503f4ea91b485274503e381569cd -EBUILD godot-3.1.1.ebuild 3282 BLAKE2B ec32b7f3a6e5792d05070f815e170869703eab085cb316b4de58e476b3bca9ad0943fdbddbd8c3aaedb3d7cffb76038f794512f71c58315f46700c391936817d SHA512 dce4f255e5c1677bfec02c2226a9045d0a8c437bec47c6c518edc0f87d1f0a06695fc5f7abafd2be00ee925bcd61949903c6b84d973321cb782a190ca522e52b -EBUILD godot-3.1.ebuild 3282 BLAKE2B ec32b7f3a6e5792d05070f815e170869703eab085cb316b4de58e476b3bca9ad0943fdbddbd8c3aaedb3d7cffb76038f794512f71c58315f46700c391936817d SHA512 dce4f255e5c1677bfec02c2226a9045d0a8c437bec47c6c518edc0f87d1f0a06695fc5f7abafd2be00ee925bcd61949903c6b84d973321cb782a190ca522e52b +EBUILD godot-3.1.1.ebuild 3654 BLAKE2B 3da11533e18b9db7055dd04e9e3c5cf7617223a8306a533a90519fa724922c2b4ea50788ac1a4271f304ca3503ba28cb765759043900de7d3d96ceb040e0cc4c SHA512 c0f3412f80ad1166183d3c6f557cd6f02a7d1218fcbbdd0f1b5bdbe64c47617357cadfad96b6e89c8e09868d20ea9aa33bd01a97bfac73d4790307522366547f diff --git a/dev-games/godot/godot-3.1.1.ebuild b/dev-games/godot/godot-3.1.1.ebuild index 0eab0ba..1d1bff5 100644 --- a/dev-games/godot/godot-3.1.1.ebuild +++ b/dev-games/godot/godot-3.1.1.ebuild @@ -4,7 +4,7 @@ EAPI=7 PYTHON_COMPAT=( python2_7 ) -inherit eutils python-any-r1 scons-utils +inherit eutils python-any-r1 scons-utils flag-o-matic llvm DESCRIPTION="Multi-platform 2D and 3D game engine" HOMEPAGE="http://godotengine.org" @@ -15,7 +15,19 @@ SRC_URI="https://github.com/godotengine/${PN}/archive/${PV}-stable.zip" S="${WORKDIR}/${P}-stable" KEYWORDS="~amd64 ~x86" -IUSE="+enet +freetype +llvm pulseaudio theora +udev +vorbis +webp +websockets +mbedtls +opus" +IUSE="debug + +enet + +freetype + llvm + lto + +mbedtls + +opus + pulseaudio + theora + +udev + +vorbis + +webp + +websockets" DEPEND=" >=app-arch/bzip2-1.0.6-r6 @@ -39,7 +51,7 @@ DEPEND=" >=sys-apps/attr-2.4.47-r1 >=sys-apps/tcp-wrappers-7.6.22-r1 >=sys-apps/util-linux-2.25.2-r2 - >=sys-devel/gcc-4.6.4:*[cxx] + !llvm? ( >=sys-devel/gcc-4.6.4:*[cxx] ) >=sys-libs/gdbm-1.11 >=sys-libs/glibc-2.20-r2 >=sys-libs/libcap-2.22-r2 @@ -58,7 +70,20 @@ DEPEND=" RDEPEND="${DEPEND}" +pkg_setup() { + python-any-r1_pkg_setup + llvm_pkg_setup +} + src_configure() { + if use llvm && ! tc-is-clang; then + einfo "Enforcing the use of clang due to USE=llvm ..." + CC=${CHOST}-clang + CXX=${CHOST}-clang++ + fi + + strip-unsupported-flags + MYSCONS=( CC="$(tc-getCC)" builtin_enet=$(usex enet) @@ -88,8 +113,12 @@ src_configure() { platform=x11 pulseaudio=$(usex pulseaudio) tools=yes + progress=false + verbose=true udev=$(usex udev) use_llvm=$(usex llvm) + use_lto=$(usex lto) + target=$(usex debug debug release_debug) ) } diff --git a/dev-games/godot/godot-3.1.ebuild b/dev-games/godot/godot-3.1.ebuild deleted file mode 100644 index 0eab0ba..0000000 --- a/dev-games/godot/godot-3.1.ebuild +++ /dev/null @@ -1,126 +0,0 @@ -# Copyright 1999-2019 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 -PYTHON_COMPAT=( python2_7 ) - -inherit eutils python-any-r1 scons-utils - -DESCRIPTION="Multi-platform 2D and 3D game engine" -HOMEPAGE="http://godotengine.org" -LICENSE="MIT" -SLOT="0" - -SRC_URI="https://github.com/godotengine/${PN}/archive/${PV}-stable.zip" -S="${WORKDIR}/${P}-stable" -KEYWORDS="~amd64 ~x86" - -IUSE="+enet +freetype +llvm pulseaudio theora +udev +vorbis +webp +websockets +mbedtls +opus" - -DEPEND=" - >=app-arch/bzip2-1.0.6-r6 - >=app-arch/lz4-0_p120 - >=app-arch/xz-utils-5.0.8 - >=dev-libs/json-c-0.11-r1 - dev-libs/libpcre2[pcre32] - >=media-libs/alsa-lib-1.0.28 - >=media-libs/flac-1.3.1-r1 - >=media-libs/libogg-1.3.1 - >=media-libs/libsndfile-1.0.25-r1 - media-libs/libvpx - >=media-libs/mesa-10.2.8[gles2] - webp? ( media-libs/libwebp ) - opus? ( media-libs/opus ) - enet? ( net-libs/enet ) - >=net-libs/libasyncns-0.8-r3 - websockets? ( net-libs/libwebsockets ) - mbedtls? ( net-libs/mbedtls ) - net-libs/miniupnpc - >=sys-apps/attr-2.4.47-r1 - >=sys-apps/tcp-wrappers-7.6.22-r1 - >=sys-apps/util-linux-2.25.2-r2 - >=sys-devel/gcc-4.6.4:*[cxx] - >=sys-libs/gdbm-1.11 - >=sys-libs/glibc-2.20-r2 - >=sys-libs/libcap-2.22-r2 - >=sys-libs/zlib-1.2.8-r1 - >=x11-libs/libX11-1.6.2 - >=x11-libs/libXcursor-1.1.14 - >=x11-libs/libXinerama-1.1.3 - freetype? ( >=media-libs/freetype-2.5.3-r1:2 ) - llvm? ( >=sys-devel/llvm-3.6.0 ) - >=media-libs/libpng-1.6.16:0= - pulseaudio? ( >=media-sound/pulseaudio-5.0-r7 ) - theora? ( media-libs/libtheora ) - udev? ( virtual/udev ) - virtual/glu - vorbis? ( >=media-libs/libvorbis-1.3.4 )" - -RDEPEND="${DEPEND}" - -src_configure() { - MYSCONS=( - CC="$(tc-getCC)" - builtin_enet=$(usex enet) - builtin_freetype=no - builtin_libogg=no - builtin_libpng=no - builtin_libpng=no - builtin_libtheora=$(usex theora) - builtin_libvorbis=$(usex vorbis) - builtin_libvpx=no - builtin_libwebp=$(usex webp) - builtin_libwebsockets=$(usex websockets) - builtin_mbedtls=$(usex mbedtls) - builtin_miniupnpc=no - builtin_opus=$(usex opus) - builtin_pcre2=no - builtin_zlib=no - #builtin_zstd=no # Compilation error due to undeclared identifiers - module_enet_enabled=$(usex enet) - module_freetype_enabled=$(usex freetype) - module_mbedtls_enabled=$(usex mbedtls) - module_opus_enabled=$(usex opus) - module_theora_enabled=$(usex theora) - module_vorbis_enabled=$(usex vorbis) - module_webp_enabled=$(usex webp) - module_websocket_enabled=$(usex websockets) - platform=x11 - pulseaudio=$(usex pulseaudio) - tools=yes - udev=$(usex udev) - use_llvm=$(usex llvm) - ) -} - -src_compile() { - escons "${MYSCONS[@]}" -} - -src_install() { - newicon icon.svg ${PN}.svg - dobin bin/godot.* - if [[ "${ARCH}" == "amd64" ]]; then - if use llvm; then - make_desktop_entry godot.x11.tools.64.llvm Godot - with_desktop_entry=1 - else - make_desktop_entry godot.x11.tools.64 Godot - with_desktop_entry=1 - fi - fi - - if [[ "${ARCH}" == "x86" ]]; then - if use llvm; then - make_desktop_entry godot.x11.tools.32.llvm Godot - with_desktop_entry=1 - else - make_desktop_entry godot.x11.tools.32 Godot - with_desktop_entry=1 - fi - fi - - if ! [[ "${with_desktop_entry}" == "1" ]]; then - elog "Couldn't detect running architecture to create a desktop file." - fi -} |