Commit graph

15 commits

Author SHA1 Message Date
Colin Cross
245ced74fe Allow arch-specific stl selection
Test: m -j checkbuild
Change-Id: Ic55433e39b2a0108efcfe980503265ac139b22e2
2017-07-20 16:59:26 -07:00
Colin Cross
3edeee113a Add ctx.Windows()
Replace ctx.Os() == android.Windows with ctx.Windows()

Test: builds
Change-Id: I7c24c39bcf54a51ad152b21c0021e40a0c07f189
2017-04-04 15:39:04 -07:00
David Benjamin
87f9f03d3f Add libc++ and libc++_static aliases for SDK builds.
c++_shared and c++_static are named libc++ and libc++_static in every
other mode. Allow the same names so targets which are built for both
host and device with SDK may specify a single name for the STL.

Test: external/boringssl is able to use "libc++_static" as the STL.
Change-Id: Ibc579c7e24ddb8de12fbfc6e1b5d80648efa589e
2017-01-25 16:47:31 -05:00
Dan Willemsen
2e47b34435 Add Toolchain.Bionic()
Move some cc ctx.Host() / ctx.Device() checks over to using
ctx.toolchain().Bionic(). There will be more changes, these are just the
obvious ones dealing with host_ldlibs / crt / system libraries.

Bug: 31559095
Test: out/soong/build.ninja is identical
Change-Id: Ibba60483b4ab0e01f6996eb7d883120e4acc1830
2016-11-17 01:50:43 -08:00
Dan Albert
3895d5b246 Always link libdl with libc++ for the NDK.
Soong change to match
https://android-review.googlesource.com/#/c/274447/.

Test: make checkbuild tests
Bug: None
Change-Id: I25bfed6d99b97c406f40892ae4abc38f4e656e81
2016-09-14 16:50:48 -07:00
Colin Cross
3d92b27717 Add libc and libm to modules that use libc++_static
Matches makefile change Ib21364e6f43689cf59da31d6f561919731ef8272

Change-Id: I6b4f3fcc65e5cac190bf9da315bd9d81e4c7cd3d
2016-07-15 14:46:21 -07:00
Colin Cross
7924885eb3 Make Stl *bool
When collapsing properties for applying defaults, string is
appended, *string is replaced, which is the behavior we want here.

Change-Id: I22a8c23e1cb8ec1960cd5d92d80f6c1ddfab1913
2016-07-12 13:12:33 -07:00
Dan Willemsen
141d566f2b Remove support for libstdc++ on Android/Linux/Darwin
It's now only supported on Windows, where we don't have libc++ support
yet.

Change-Id: I64891b7558d3d2942588687017a0c2f695c18d5c
2016-06-15 13:47:51 -07:00
Colin Cross
a1ad8d1889 Simplify arch target handling
Soong's multi-architecture building has grown complex, with the
combination of HostOrDevice+HostType+Arch necessary to determine how to
build a variant of a module, and three separate mutators to split each
into its variations.

Combine HostOrDevice+HostType into Os, which will be Linux, Darwin,
Windows, or Android.  Store Os+Arch as a single Target.

Change-Id: I92f2e2dac53617d595a35cc285d2bd348baa0fbd
2016-06-02 19:09:32 -07:00
Colin Cross
b9db480385 Revert "Simplify arch target handling"
This reverts commit 6713fb26cbcadf525cd75e47d7d0cbc23d282b3e.

Change-Id: Ic473cea2563b0b37dc08b0bc5d3a0ac8c4b6afe6
2016-06-03 01:50:47 +00:00
Colin Cross
54c7112c43 Simplify arch target handling
Soong's multi-architecture building has grown complex, with the
combination of HostOrDevice+HostType+Arch necessary to determine how to
build a variant of a module, and three separate mutators to split each
into its variations.

Combine HostOrDevice+HostType into Os, which will be Linux, Darwin,
Windows, or Android.  Store Os+Arch as a single Target.

Change-Id: Iae677eff61a851b65a7192a47f2dc17c1abb4160
2016-06-02 17:37:02 -07:00
Colin Cross
635c3b0157 Rename common to android
Rename the "common" package to "android", because common is too
generic.  Also removes all android.Android naming stutter.

Ran:
gomvpkg -from 'android/soong/common' -to 'android/soong/android'
gorename -from '"android/soong/android".AndroidModuleContext' -to 'ModuleContext'
gorename -from '"android/soong/android".AndroidBaseContext' -to 'BaseContext'
gorename -from '"android/soong/android".AndroidModuleBase' -to 'ModuleBase'
gorename -from '"android/soong/android".AndroidBottomUpMutatorContext' -to 'BottomUpMutatorContext'
gorename -from '"android/soong/android".AndroidTopDownMutatorContext' -to 'TopDownMutatorContext'
gorename -from '"android/soong/android".AndroidModule' -to 'Module'

Change-Id: I3b23590b8ce7c8a1ea1139411d84a53163288da7
2016-05-18 15:37:25 -07:00
Colin Cross
4a97cb4328 Support "none" for stl when using ndk
Change-Id: I13ecf0a6be591814546a9a1c8b8356988348feb0
2016-04-21 16:39:28 -07:00
Colin Cross
a8e07cc653 Promote stl to a fixed feature
cc needs to know what stl was selected, promote stl from a generic
feature implementation to a fixed type pointer.

Change-Id: I950ef947f7cd254fe3074f4ff240bb2b90b9116c
2016-04-21 16:39:28 -07:00
Colin Cross
ca860ac720 Refactor cc
Refactor all of cc in order to use composition instead of inheritance.
All cc module types exported by cc are now *cc.Module objects, with
compilation, linking, and installing steps delegated to different
objects in order to form the full module type.  Additional features that
modify dependencies and flags can be inserted in a features object list,
and custom module types can be created by adding a Customizer object
that can modify properties.

Change-Id: Ie1283d14920f7856f6947b0530606b2f4d58fab0
2016-03-21 17:31:04 -07:00