• Ying Wang's avatar
    Load compiler environment for a second arch. · 1d274d26
    Ying Wang authored
    This is the first step to build 32-bit libraries in a 64-bit product.
    It will work like this:
    1) In the product's BoardConfig.mk, define:
    TARGET_2ND_ARCH, TARGET_2ND_ARCH_VARIANT, TARGET_2ND_CPU_VARIANT.
    The build system uses those variables to set up an additional compiler
    environment for the second arch.
    
    2) When parsing Android.mks, the build system sets up rules to build a
    module for both the 1st arch and the 2nd arch, unless it's explicitly
    asked to skip so.
    Android.mk will be adapted if there is additional rule of generating
    source files.
    The build system will accept arch-specific LOCAL_ variables, such as
    LOCAL_CFLAGS_arm, LOCAL_CFLAGS_armv7-a-neon, LOCAL_CFLAGS_cortex-a15,
    LOCAL_CFLAGS_aarch64 etc. Modules use such variables to set up build for
    various archs at the same time.
    
    3) Install binary of the 2nd arch by adding "<module_name>:32" to
    PRODUCT_PACKAGES. All 2nd-arch libraries linked in by "<module_name>:32"
    will be installed automatically.
    
    Bug: 11654773
    Change-Id: I2df63cd5463a07bf5358bee2a109f8fb9590fe30
    
    Conflicts:
    	core/combo/TARGET_linux-arm.mk
    1d274d26
dynamic_binary.mk 4.9 KB