summaryrefslogtreecommitdiffstats
path: root/llvm/tools/llvm-objcopy/CMakeLists.txt
blob: 3b6c345b292b6fbe0b31aaea810af3b90ede36d3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
set(LLVM_LINK_COMPONENTS
  Object
  Option
  Support
  MC
  )

set(LLVM_TARGET_DEFINITIONS ObjcopyOpts.td)
tablegen(LLVM ObjcopyOpts.inc -gen-opt-parser-defs)
add_public_tablegen_target(ObjcopyOptsTableGen)

set(LLVM_TARGET_DEFINITIONS StripOpts.td)
tablegen(LLVM StripOpts.inc -gen-opt-parser-defs)
add_public_tablegen_target(StripOptsTableGen)

add_llvm_tool(llvm-objcopy
  Buffer.cpp
  CopyConfig.cpp
  llvm-objcopy.cpp
  COFF/COFFObjcopy.cpp
  COFF/Reader.cpp
  COFF/Writer.cpp
  ELF/ELFObjcopy.cpp
  ELF/Object.cpp
  DEPENDS
  ObjcopyOptsTableGen
  StripOptsTableGen
  )

add_llvm_tool_symlink(llvm-strip llvm-objcopy)

if(LLVM_INSTALL_BINUTILS_SYMLINKS)
  add_llvm_tool_symlink(objcopy llvm-objcopy)
  add_llvm_tool_symlink(strip llvm-objcopy)
endif()
OpenPOWER on IntegriCloud