From: Philip Balister <philip@balister.org>
To: Khem Raj <raj.khem@gmail.com>
Cc: Patches and discussions about the oe-core layer
<openembedded-core@lists.openembedded.org>
Subject: Re: [PATCH] cmake.bbclass : Add support for cmake projects that use .S files.
Date: Fri, 19 Sep 2014 09:55:57 -0400 [thread overview]
Message-ID: <541C35ED.9040503@balister.org> (raw)
In-Reply-To: <CAMKF1spggZ4tP2A6oOq_-mw9bPhrdYj9dWR9n5dr-5YNFyP_EQ@mail.gmail.com>
On 09/17/2014 07:07 PM, Khem Raj wrote:
> On Wed, Sep 17, 2014 at 7:33 AM, Philip Balister <philip@balister.org> wrote:
>> UHD and GNU radio use the cmake build system. The toolchain file made
>> from cmake.bbclass does not set the variable needs by cmake projects
>> that use .S files. UHD added some .S files and these changes are required
>> to build recent UHD.
>>
>
> I dont know if this is right thing to do in a generic bbclass. Since
> some packages might use bare assembler to compiler assembly files
If a cmake project enables assembler and doesn't set the CMAKE_ASM_*
flags to some sane defaults, the build fails. Settings these vars in the
toolchain files fixes the problem.
I am not a cmake guru, but it seems like we should be able to build code
that builds OK natively.
Philip
>
>> Signed-off-by: Philip Balister <philip@balister.org>
>> ---
>> meta/classes/cmake.bbclass | 3 +++
>> 1 file changed, 3 insertions(+)
>>
>> diff --git a/meta/classes/cmake.bbclass b/meta/classes/cmake.bbclass
>> index ab2adec..bfa5995 100644
>> --- a/meta/classes/cmake.bbclass
>> +++ b/meta/classes/cmake.bbclass
>> @@ -34,10 +34,13 @@ set( CMAKE_SYSTEM_NAME `echo ${TARGET_OS} | sed -e 's/^./\u&/' -e 's/^\(Linux\).
>> set( CMAKE_SYSTEM_PROCESSOR ${TARGET_ARCH} )
>> set( CMAKE_C_COMPILER ${OECMAKE_C_COMPILER} )
>> set( CMAKE_CXX_COMPILER ${OECMAKE_CXX_COMPILER} )
>> +set( CMAKE_ASM_COMPILER ${OECMAKE_C_COMPILER} )
>> set( CMAKE_C_FLAGS "${OECMAKE_C_FLAGS}" CACHE STRING "CFLAGS" )
>> set( CMAKE_CXX_FLAGS "${OECMAKE_CXX_FLAGS}" CACHE STRING "CXXFLAGS" )
>> +set( CMAKE_ASM_FLAGS "${OECMAKE_C_FLAGS}" CACHE STRING "ASM FLAGS" )
>> set( CMAKE_C_FLAGS_RELEASE "${OECMAKE_C_FLAGS_RELEASE}" CACHE STRING "CFLAGS for release" )
>> set( CMAKE_CXX_FLAGS_RELEASE "${OECMAKE_CXX_FLAGS_RELEASE}" CACHE STRING "CXXFLAGS for release" )
>> +set( CMAKE_ASM_FLAGS_RELEASE "${OECMAKE_C_FLAGS_RELEASE}" CACHE STRING "ASM FLAGS for release" )
>> set( CMAKE_C_LINK_FLAGS "${OECMAKE_C_LINK_FLAGS}" CACHE STRING "LDFLAGS" )
>> set( CMAKE_CXX_LINK_FLAGS "${OECMAKE_CXX_LINK_FLAGS}" CACHE STRING "LDFLAGS" )
>>
>> --
>> 1.8.3.1
>>
>> --
>> _______________________________________________
>> Openembedded-core mailing list
>> Openembedded-core@lists.openembedded.org
>> http://lists.openembedded.org/mailman/listinfo/openembedded-core
>
next prev parent reply other threads:[~2014-09-19 13:55 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-09-17 14:33 [PATCH] cmake.bbclass : Add support for cmake projects that use .S files Philip Balister
2014-09-17 23:07 ` Khem Raj
2014-09-19 13:55 ` Philip Balister [this message]
2014-09-19 14:01 ` Otavio Salvador
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=541C35ED.9040503@balister.org \
--to=philip@balister.org \
--cc=openembedded-core@lists.openembedded.org \
--cc=raj.khem@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.