From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 55F18138334 for ; Tue, 13 Nov 2018 20:41:01 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id E0474E0ABE; Tue, 13 Nov 2018 20:40:51 +0000 (UTC) Received: from km35626.keymachine.de (text-idiomas.com [87.118.86.27]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 4CD8DE0A49 for ; Tue, 13 Nov 2018 20:40:50 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by km35626.keymachine.de (Postfix) with ESMTP id 092301129922 for ; Tue, 13 Nov 2018 21:40:49 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at km35626.keymachine.de. Received: from km35626.keymachine.de ([127.0.0.1]) by localhost (km35626.keymachine.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id U68e0ZYHedK8 for ; Tue, 13 Nov 2018 21:40:47 +0100 (CET) Received: from grusum.endjinn.de (p2E5B524B.dip0.t-ipconnect.de [46.91.82.75]) by km35626.keymachine.de (Postfix) with ESMTPSA id F316911299A9 for ; Tue, 13 Nov 2018 21:40:46 +0100 (CET) Received: by grusum.endjinn.de (Postfix, from userid 500) id 9D09417039A; Tue, 13 Nov 2018 21:34:34 +0100 (CET) Date: Tue, 13 Nov 2018 21:35:00 +0100 From: David Haller To: gentoo-user@lists.gentoo.org Subject: Re: [gentoo-user] Weird compilation error (nasm) Message-ID: <20181113203500.5ccero46uouavcqd@grusum.endjinn.de> Mail-Followup-To: gentoo-user@lists.gentoo.org References: <20181113171138.rwe43lsliihyhh7s@solfire> Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-user@lists.gentoo.org Reply-to: gentoo-user@lists.gentoo.org MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-15 Content-Disposition: inline In-Reply-To: <20181113171138.rwe43lsliihyhh7s@solfire> Organization: What? X-Clacks-Overhead: GNU Terry Pratchett User-Agent: NeoMutt/20170609 (1.8.3) X-Archives-Salt: 751c1b9d-a6ab-4f8d-8e6e-e55e6eca89f5 X-Archives-Hash: da052338f71cad73828228f06777e9cb Hello, On Tue, 13 Nov 2018, tuxic@posteo.de wrote: >I got a weird looking error while upgrading/recompiling nasm: >cmake -C /var/tmp/portage/media-libs/libjpeg-turbo-2.0.1/work/libjpeg-turbo-2.0.1-abi_x86_64.amd64/gentoo_common_config.cmake -G Unix Makefiles -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_INSTALL_DEFAULT_DOCDIR=/usr/share/doc/libjpeg-turbo-2.0.1 -DENABLE_STATIC=no -DWITH_JAVA=no -DWITH_MEM_SRCDST=ON -DCMAKE_BUILD_TYPE=Gentoo -DCMAKE_TOOLCHAIN_FILE=/var/tmp/portage/media-libs/libjpeg-turbo-2.0.1/work/libjpeg-turbo-2.0.1-abi_x86_64.amd64/gentoo_toolchain.cmake /var/tmp/portage/media-libs/libjpeg-turbo-2.0.1/work/libjpeg-turbo-2.0.1 >loading initial cache file /var/tmp/portage/media-libs/libjpeg-turbo-2.0.1/work/libjpeg-turbo-2.0.1-abi_x86_64.amd64/gentoo_common_config.cmake > * ACCESS DENIED: fopen_wr: /? >Build type Gentoo >Install path /usr >Compiler flags: >C -march=native -O -pipe >C++ >Linker flags: >Executable -Wl,-O1 -Wl,--as-needed >Module -Wl,-O1 -Wl,--as-needed >Shared -Wl,-O1 -Wl,--as-needed > >>>> Source configured. > * --------------------------- ACCESS VIOLATION SUMMARY --------------------------- > * LOG FILE: "/var/log/sandbox/sandbox-16492.log" > * >VERSION 1.0 >FORMAT: F - Function called >FORMAT: S - Access Status >FORMAT: P - Path as passed to function >FORMAT: A - Absolute Path (not canonical) >FORMAT: R - Canonical Path >FORMAT: C - Command Line > >F: fopen_wr >S: deny >P: /? >A: /? >R: /? >C: /usr/bin/nasm /? > * -------------------------------------------------------------------------------- The problem is cmake's way to figure out what nasm it has got: ==== /usr/share/cmake/Modules/CMakeDetermineASMCompiler.cmake:79 ==== list(APPEND CMAKE_ASM${ASM_DIALECT}_COMPILER_ID_VENDORS MSVC ) set(CMAKE_ASM${ASM_DIALECT}_COMPILER_ID_VENDOR_FLAGS_MSVC "/?") set(CMAKE_ASM${ASM_DIALECT}_COMPILER_ID_VENDOR_REGEX_MSVC "Microsoft ==== Workaround1: ==== --- libjpeg-turbo-2.0.1.ebuild~ 2018-11-13 20:45:58.000000000 +0100 +++ libjpeg-turbo-2.0.1.ebuild 2018-11-13 20:44:02.000000000 +0100 @@ -52,6 +52,7 @@ -DENABLE_STATIC="$(usex static-libs)" -DWITH_JAVA="$(multilib_native_usex java)" -DWITH_MEM_SRCDST=ON + -DCMAKE_ASM_NASM_COMPILER_ID=GNU ) [[ ${ABI} == "x32" ]] && mycmakeargs+=( -DREQUIRE_SIMD=OFF ) #420239 cmake-utils_src_configure ==== Workaround2: if you have dev-lang/yasm installed, use: ASM_NASM=/usr/bin/yasm [ebuild|emerge] ... Workaround3: delete those MSVC lines from /usr/share/cmake/Modules/CMakeDetermineASMCompiler.cmake Workaround4: patch cmake-utils.eclass to add -DCMAKE_ASM_NASM_COMPILER_ID=GNU to cmakeargs in cmake-utils_src_configure. HTH, -dnh, I'd prefer solution 3 ;) -- my other signature is more intellectual