1 |
2018-02-25 10:06 GMT+01:00 Michał Górny <mgorny@g.o>: |
2 |
|
3 |
> Some CMake projects use ASM-ATT rather than ASM, so extend our rule |
4 |
> overrides to that. |
5 |
> |
6 |
|
7 |
for the curious: |
8 |
https://cmake.org/Wiki/CMake/Assembler#ASM-ATT |
9 |
|
10 |
ASM-ATT |
11 |
|
12 |
This can be used for assembler files in AT&T assembler syntax. This |
13 |
includes the GNU assembler gas. |
14 |
|
15 |
- Supported assembler names: as, gas, may have toolchain specific prefix |
16 |
- Supported source files extensions: .s, .asm |
17 |
- .S files, i.e. assembler files which require preprocessing, are not |
18 |
supported |
19 |
- Involved files: CMakeASM-ATTInformation.cmake, |
20 |
CMakeDetermineASM-ATTCompiler.cmake, CMakeTestASM-ATTCompiler.cmake |
21 |
|
22 |
|
23 |
|
24 |
|
25 |
> |
26 |
> Bug: https://bugs.gentoo.org/625844 |
27 |
> --- |
28 |
> eclass/cmake-utils.eclass | 3 +++ |
29 |
> 1 file changed, 3 insertions(+) |
30 |
> |
31 |
> diff --git a/eclass/cmake-utils.eclass b/eclass/cmake-utils.eclass |
32 |
> index b9f69a824b14..ef3f3c2607f8 100644 |
33 |
> --- a/eclass/cmake-utils.eclass |
34 |
> +++ b/eclass/cmake-utils.eclass |
35 |
> @@ -516,6 +516,7 @@ cmake-utils_src_configure() { |
36 |
> fi |
37 |
> cat > "${build_rules}" <<- _EOF_ || die |
38 |
> SET (CMAKE_ASM_COMPILE_OBJECT "<CMAKE_ASM_COMPILER> |
39 |
> <DEFINES> ${includes} ${CPPFLAGS} <FLAGS> -o <OBJECT> -c <SOURCE>" CACHE |
40 |
> STRING "ASM compile command" FORCE) |
41 |
> + SET (CMAKE_ASM-ATT_COMPILE_OBJECT "<CMAKE_ASM_COMPILER> |
42 |
> <DEFINES> ${includes} ${CPPFLAGS} <FLAGS> -o <OBJECT> -c <SOURCE>" CACHE |
43 |
> STRING "ASM compile command" FORCE) |
44 |
> SET (CMAKE_C_COMPILE_OBJECT "<CMAKE_C_COMPILER> <DEFINES> |
45 |
> ${includes} ${CPPFLAGS} <FLAGS> -o <OBJECT> -c <SOURCE>" CACHE STRING "C |
46 |
> compile command" FORCE) |
47 |
> SET (CMAKE_CXX_COMPILE_OBJECT "<CMAKE_CXX_COMPILER> |
48 |
> <DEFINES> ${includes} ${CPPFLAGS} <FLAGS> -o <OBJECT> -c <SOURCE>" CACHE |
49 |
> STRING "C++ compile command" FORCE) |
50 |
> SET (CMAKE_Fortran_COMPILE_OBJECT |
51 |
> "<CMAKE_Fortran_COMPILER> <DEFINES> ${includes} ${FCFLAGS} <FLAGS> -o |
52 |
> <OBJECT> -c <SOURCE>" CACHE STRING "Fortran compile command" FORCE) |
53 |
> @@ -531,6 +532,7 @@ cmake-utils_src_configure() { |
54 |
> local toolchain_file=${BUILD_DIR}/gentoo_toolchain.cmake |
55 |
> cat > ${toolchain_file} <<- _EOF_ || die |
56 |
> SET (CMAKE_ASM_COMPILER "${myCC/ /;}") |
57 |
> + SET (CMAKE_ASM-ATT_COMPILER "${myCC/ /;}") |
58 |
> SET (CMAKE_C_COMPILER "${myCC/ /;}") |
59 |
> SET (CMAKE_CXX_COMPILER "${myCXX/ /;}") |
60 |
> SET (CMAKE_Fortran_COMPILER "${myFC/ /;}") |
61 |
> @@ -609,6 +611,7 @@ cmake-utils_src_configure() { |
62 |
> if [[ ${CMAKE_BUILD_TYPE} != Gentoo && ${EAPI} != 5 ]]; then |
63 |
> cat >> ${common_config} <<- _EOF_ || die |
64 |
> SET (CMAKE_ASM_FLAGS_${CMAKE_BUILD_TYPE^^} "" |
65 |
> CACHE STRING "") |
66 |
> + SET (CMAKE_ASM-ATT_FLAGS_${CMAKE_BUILD_TYPE^^} "" |
67 |
> CACHE STRING "") |
68 |
> SET (CMAKE_C_FLAGS_${CMAKE_BUILD_TYPE^^} "" CACHE |
69 |
> STRING "") |
70 |
> SET (CMAKE_CXX_FLAGS_${CMAKE_BUILD_TYPE^^} "" |
71 |
> CACHE STRING "") |
72 |
> SET (CMAKE_Fortran_FLAGS_${CMAKE_BUILD_TYPE^^} "" |
73 |
> CACHE STRING "") |
74 |
> -- |
75 |
> 2.16.2 |
76 |
> |
77 |
> |
78 |
> |