make/archive: Use the full path name when matching or storing names in the archive
This pr will avoid targets with the same name can not be archive in the same library Signed-off-by: chao an <anchao@xiaomi.com>
This commit is contained in:
parent
6d44c42707
commit
563125fde3
@ -89,9 +89,9 @@ endif()
|
||||
|
||||
# override the ARCHIVE command
|
||||
|
||||
set(CMAKE_C_ARCHIVE_CREATE "<CMAKE_AR> rcs <TARGET> <LINK_FLAGS> <OBJECTS>")
|
||||
set(CMAKE_CXX_ARCHIVE_CREATE "<CMAKE_AR> rcs <TARGET> <LINK_FLAGS> <OBJECTS>")
|
||||
set(CMAKE_ASM_ARCHIVE_CREATE "<CMAKE_AR> rcs <TARGET> <LINK_FLAGS> <OBJECTS>")
|
||||
set(CMAKE_C_ARCHIVE_CREATE "<CMAKE_AR> rcsP <TARGET> <LINK_FLAGS> <OBJECTS>")
|
||||
set(CMAKE_CXX_ARCHIVE_CREATE "<CMAKE_AR> rcsP <TARGET> <LINK_FLAGS> <OBJECTS>")
|
||||
set(CMAKE_ASM_ARCHIVE_CREATE "<CMAKE_AR> rcsP <TARGET> <LINK_FLAGS> <OBJECTS>")
|
||||
|
||||
# Architecture flags
|
||||
|
||||
|
@ -157,7 +157,7 @@ ifeq ($(CONFIG_ARM_TOOLCHAIN_CLANG),y)
|
||||
CPP = clang -E -P -x c
|
||||
LD = ld.lld -m armelf
|
||||
STRIP = llvm-strip --strip-unneeded
|
||||
AR = llvm-ar rcs
|
||||
AR = llvm-ar rcsP
|
||||
NM = llvm-nm
|
||||
OBJCOPY = llvm-objcopy
|
||||
OBJDUMP = llvm-objdump
|
||||
@ -189,7 +189,7 @@ else ifeq ($(CONFIG_ARM_TOOLCHAIN_ARMCLANG),y)
|
||||
CPP = armclang -E -P -x c
|
||||
LD = armlink
|
||||
STRIP = llvm-strip --strip-unneeded
|
||||
AR = armar -rcs
|
||||
AR = armar -rcsP
|
||||
NM = llvm-nm
|
||||
OBJCOPY = llvm-objcopy
|
||||
OBJDUMP = llvm-objdump
|
||||
@ -230,7 +230,7 @@ else
|
||||
CPP = $(CROSSDEV)gcc -E -P -x c
|
||||
LD = $(CROSSDEV)ld
|
||||
STRIP = $(CROSSDEV)strip --strip-unneeded
|
||||
AR = $(CROSSDEV)ar rcs
|
||||
AR = $(CROSSDEV)ar rcsP
|
||||
NM = $(CROSSDEV)nm
|
||||
OBJCOPY = $(CROSSDEV)objcopy
|
||||
OBJDUMP = $(CROSSDEV)objdump
|
||||
@ -238,7 +238,7 @@ else
|
||||
ifeq ($(CONFIG_LTO_FULL),y)
|
||||
ifeq ($(CONFIG_ARM_TOOLCHAIN_GNU_EABI),y)
|
||||
LD := $(CROSSDEV)gcc
|
||||
AR := $(CROSSDEV)gcc-ar rcs
|
||||
AR := $(CROSSDEV)gcc-ar rcsP
|
||||
NM := $(CROSSDEV)gcc-nm
|
||||
ARCHOPTIMIZATION += -fno-builtin
|
||||
endif
|
||||
|
@ -146,7 +146,7 @@ STRIP = $(CROSSDEV)strip --strip-unneeded
|
||||
OBJCOPY = $(CROSSDEV)objcopy
|
||||
OBJDUMP = $(CROSSDEV)objdump
|
||||
LD = $(CROSSDEV)ld
|
||||
AR = $(CROSSDEV)ar rcs
|
||||
AR = $(CROSSDEV)ar rcsP
|
||||
NM = $(CROSSDEV)nm
|
||||
|
||||
# Link Time Optimization
|
||||
@ -155,7 +155,7 @@ ifeq ($(CONFIG_LTO_FULL),y)
|
||||
ARCHOPTIMIZATION += -flto
|
||||
ifeq ($(CONFIG_ARM_TOOLCHAIN_GNU_EABI),y)
|
||||
LD := $(CROSSDEV)gcc
|
||||
AR := $(CROSSDEV)gcc-ar rcs
|
||||
AR := $(CROSSDEV)gcc-ar rcsP
|
||||
NM := $(CROSSDEV)gcc-nm
|
||||
ARCHOPTIMIZATION += -fuse-linker-plugin
|
||||
ARCHOPTIMIZATION += -fno-builtin
|
||||
|
@ -147,7 +147,7 @@ CXX = $(CROSSDEV)g++
|
||||
CPP = $(CROSSDEV)gcc -E -P -x c
|
||||
LD = $(CROSSDEV)ld
|
||||
STRIP = $(CROSSDEV)strip --strip-unneeded
|
||||
AR = $(CROSSDEV)ar rcs
|
||||
AR = $(CROSSDEV)ar rcsP
|
||||
NM = $(CROSSDEV)nm
|
||||
OBJCOPY = $(CROSSDEV)objcopy
|
||||
OBJDUMP = $(CROSSDEV)objdump
|
||||
|
@ -77,7 +77,7 @@ CXX = $(CROSSDEV)g++
|
||||
CPP = $(CROSSDEV)gcc -E -P -x c
|
||||
LD = $(CROSSDEV)ld
|
||||
STRIP = $(CROSSDEV)strip --strip-unneeded
|
||||
AR = $(CROSSDEV)ar rcs
|
||||
AR = $(CROSSDEV)ar rcsP
|
||||
NM = $(CROSSDEV)nm
|
||||
OBJCOPY = $(CROSSDEV)objcopy
|
||||
OBJDUMP = $(CROSSDEV)objdump
|
||||
|
@ -286,7 +286,7 @@ CXX = $(CROSSDEV)g++
|
||||
CPP = $(CROSSDEV)gcc -E -P -x c
|
||||
LD = $(CROSSDEV)ld
|
||||
STRIP = $(CROSSDEV)strip --strip-unneeded
|
||||
AR = $(CROSSDEV)ar rcs
|
||||
AR = $(CROSSDEV)ar rcsP
|
||||
NM = $(CROSSDEV)nm
|
||||
OBJCOPY = $(CROSSDEV)objcopy
|
||||
OBJDUMP = $(CROSSDEV)objdump
|
||||
|
@ -108,7 +108,7 @@ CXX = $(CROSSDEV)g++
|
||||
CPP = $(CROSSDEV)gcc -E -P -x c
|
||||
LD = $(CROSSDEV)ld
|
||||
STRIP = $(CROSSDEV)strip --strip-unneeded
|
||||
AR = $(CROSSDEV)ar rcs
|
||||
AR = $(CROSSDEV)ar rcsP
|
||||
NM = $(CROSSDEV)nm
|
||||
OBJCOPY = $(CROSSDEV)objcopy
|
||||
OBJDUMP = $(CROSSDEV)objdump
|
||||
|
@ -56,7 +56,7 @@ CXX = $(CROSSDEV)g++
|
||||
CPP = $(CROSSDEV)gcc -E -P -x c
|
||||
LD = $(CROSSDEV)ld
|
||||
STRIP = $(CROSSDEV)strip --strip-unneeded
|
||||
AR = $(CROSSDEV)ar rcs
|
||||
AR = $(CROSSDEV)ar rcsP
|
||||
NM = $(CROSSDEV)nm
|
||||
OBJCOPY = $(CROSSDEV)objcopy
|
||||
OBJDUMP = $(CROSSDEV)objdump
|
||||
|
@ -94,7 +94,7 @@ CXX = $(CROSSDEV)g++
|
||||
CPP = $(CROSSDEV)gcc -E -P -x c
|
||||
LD = $(CROSSDEV)ld
|
||||
STRIP = $(CROSSDEV)strip --strip-unneeded
|
||||
AR = $(CROSSDEV)ar rcs
|
||||
AR = $(CROSSDEV)ar rcsP
|
||||
NM = $(CROSSDEV)nm
|
||||
OBJCOPY = $(CROSSDEV)objcopy
|
||||
OBJDUMP = $(CROSSDEV)objdump
|
||||
|
@ -245,7 +245,7 @@ STRIP = $(CROSSDEV)strip --strip-unneeded
|
||||
OBJCOPY = $(CROSSDEV)objcopy
|
||||
OBJDUMP = $(CROSSDEV)objdump
|
||||
LD = $(CROSSDEV)ld
|
||||
AR = $(CROSSDEV)ar rcs
|
||||
AR = $(CROSSDEV)ar rcsP
|
||||
NM = $(CROSSDEV)nm
|
||||
|
||||
# Link Time Optimization
|
||||
@ -254,7 +254,7 @@ ifeq ($(CONFIG_LTO_FULL),y)
|
||||
ARCHOPTIMIZATION += -flto
|
||||
ifeq ($(CONFIG_RISCV_TOOLCHAIN),GNU_RVG)
|
||||
LD := $(CROSSDEV)gcc
|
||||
AR := $(CROSSDEV)gcc-ar rcs
|
||||
AR := $(CROSSDEV)gcc-ar rcsP
|
||||
NM := $(CROSSDEV)gcc-nm
|
||||
ARCHOPTIMIZATION += -fuse-linker-plugin
|
||||
ARCHOPTIMIZATION += -fno-builtin
|
||||
|
@ -115,7 +115,7 @@ CXX = $(CROSSDEV)g++
|
||||
CPP = $(CROSSDEV)gcc -E
|
||||
LD = $(CROSSDEV)ld
|
||||
STRIP = $(CROSSDEV)strip --strip-unneeded
|
||||
AR = $(CROSSDEV)ar rcs
|
||||
AR = $(CROSSDEV)ar rcsP
|
||||
NM = $(CROSSDEV)nm
|
||||
OBJCOPY = $(CROSSDEV)objcopy
|
||||
OBJDUMP = $(CROSSDEV)objdump
|
||||
|
@ -152,7 +152,7 @@ endif
|
||||
|
||||
LD = $(CROSSDEV)ld
|
||||
STRIP = $(CROSSDEV)strip --strip-unneeded
|
||||
AR = $(CROSSDEV)ar rcs
|
||||
AR = $(CROSSDEV)ar rcsP
|
||||
NM = $(CROSSDEV)nm
|
||||
OBJCOPY = $(CROSSDEV)objcopy
|
||||
OBJDUMP = $(CROSSDEV)objdump
|
||||
|
@ -156,7 +156,7 @@ endif
|
||||
|
||||
LD = $(CROSSDEV)ld
|
||||
STRIP = $(CROSSDEV)strip --strip-unneeded
|
||||
AR = $(CROSSDEV)ar rcs
|
||||
AR = $(CROSSDEV)ar rcsP
|
||||
NM = $(CROSSDEV)nm
|
||||
OBJCOPY = $(CROSSDEV)objcopy
|
||||
OBJDUMP = $(CROSSDEV)objdump
|
||||
|
@ -25,7 +25,7 @@ CROSSDEV = m32c-nuttx-elf-
|
||||
CC = $(CROSSDEV)gcc
|
||||
CPP = $(CROSSDEV)gcc -E
|
||||
LD = $(CROSSDEV)ld
|
||||
AR = $(CROSSDEV)ar rcs
|
||||
AR = $(CROSSDEV)ar rcsP
|
||||
NM = $(CROSSDEV)nm
|
||||
OBJCOPY = $(CROSSDEV)objcopy
|
||||
OBJDUMP = $(CROSSDEV)objdump
|
||||
|
@ -29,7 +29,7 @@ CXX = $(CROSSDEV)g++
|
||||
CPP = $(CROSSDEV)gcc -E -P -x c
|
||||
LD = $(CROSSDEV)ld
|
||||
STRIP = $(CROSSDEV)strip --strip-unneeded
|
||||
AR = $(CROSSDEV)ar rcs
|
||||
AR = $(CROSSDEV)ar rcsP
|
||||
AS = $(CROSSDEV)as
|
||||
NM = $(CROSSDEV)nm
|
||||
OBJCOPY = $(CROSSDEV)objcopy
|
||||
|
@ -29,7 +29,7 @@ CXX = $(CROSSDEV)g++
|
||||
CPP = $(CROSSDEV)gcc -E -P -x c
|
||||
LD = $(CROSSDEV)ld
|
||||
STRIP = $(CROSSDEV)strip --strip-unneeded
|
||||
AR = $(CROSSDEV)ar rcs
|
||||
AR = $(CROSSDEV)ar rcsP
|
||||
AS = $(CROSSDEV)as
|
||||
NM = $(CROSSDEV)nm
|
||||
OBJCOPY = $(CROSSDEV)objcopy
|
||||
|
@ -29,7 +29,7 @@ CXX = $(CROSSDEV)g++
|
||||
CPP = $(CROSSDEV)gcc -E -P -x c
|
||||
LD = $(CROSSDEV)ld
|
||||
STRIP = $(CROSSDEV)strip --strip-unneeded
|
||||
AR = $(CROSSDEV)ar rcs
|
||||
AR = $(CROSSDEV)ar rcsP
|
||||
AS = $(CROSSDEV)as
|
||||
NM = $(CROSSDEV)nm
|
||||
OBJCOPY = $(CROSSDEV)objcopy
|
||||
|
@ -29,7 +29,7 @@ CXX = $(CROSSDEV)g++
|
||||
CPP = $(CROSSDEV)gcc -E -P -x c
|
||||
LD = $(CROSSDEV)ld
|
||||
STRIP = $(CROSSDEV)strip --strip-unneeded
|
||||
AR = $(CROSSDEV)ar rcs
|
||||
AR = $(CROSSDEV)ar rcsP
|
||||
AS = $(CROSSDEV)as
|
||||
NM = $(CROSSDEV)nm
|
||||
OBJCOPY = $(CROSSDEV)objcopy
|
||||
|
@ -39,7 +39,7 @@ CC = $(CROSSDEV)gcc
|
||||
CPP = $(CROSSDEV)gcc -E
|
||||
LD = $(CROSSDEV)ld
|
||||
STRIP = $(CROSSDEV)strip --strip-unneeded
|
||||
AR = $(CROSSDEV)ar rcs
|
||||
AR = $(CROSSDEV)ar rcsP
|
||||
NM = $(CROSSDEV)nm
|
||||
OBJCOPY = $(CROSSDEV)objcopy
|
||||
OBJDUMP = $(CROSSDEV)objdump
|
||||
|
@ -33,10 +33,10 @@ EXTERN(__start)
|
||||
SECTIONS
|
||||
{
|
||||
.text.sbi : {
|
||||
sbi*
|
||||
riscv_atomic*
|
||||
riscv_locks*
|
||||
riscv_asm*
|
||||
*/sbi*
|
||||
*/riscv_atomic*
|
||||
*/riscv_locks*
|
||||
*/riscv_asm*
|
||||
} > ddr
|
||||
|
||||
.l2_scratchpad : ALIGN(0x10)
|
||||
|
@ -166,7 +166,7 @@ STRIP = $(CROSSDEV)strip
|
||||
AR = $(TOPDIR)/tools/macar-rcs.sh
|
||||
else
|
||||
STRIP = $(CROSSDEV)strip --strip-unneeded
|
||||
AR = $(CROSSDEV)ar rcs
|
||||
AR = $(CROSSDEV)ar rcsP
|
||||
endif
|
||||
NM = $(CROSSDEV)nm
|
||||
OBJCOPY = $(CROSSDEV)objcopy
|
||||
|
@ -53,7 +53,7 @@ CC = $(CROSSDEV)gcc
|
||||
CPP = $(CROSSDEV)gcc -E
|
||||
LD = $(CROSSDEV)ld
|
||||
STRIP = $(CROSSDEV)strip --strip-unneeded
|
||||
AR = $(CROSSDEV)ar rcs
|
||||
AR = $(CROSSDEV)ar rcsP
|
||||
NM = $(CROSSDEV)nm
|
||||
OBJCOPY = $(CROSSDEV)objcopy
|
||||
OBJDUMP = $(CROSSDEV)objdump
|
||||
|
@ -51,7 +51,7 @@ CC = $(CROSSDEV)gcc
|
||||
CPP = $(CROSSDEV)gcc -E
|
||||
LD = $(CROSSDEV)ld
|
||||
STRIP = $(CROSSDEV)strip --strip-unneeded
|
||||
AR = $(CROSSDEV)ar rcs
|
||||
AR = $(CROSSDEV)ar rcsP
|
||||
NM = $(CROSSDEV)nm
|
||||
OBJCOPY = $(CROSSDEV)objcopy
|
||||
OBJDUMP = $(CROSSDEV)objdump
|
||||
|
Loading…
Reference in New Issue
Block a user