1# RUN: ld64.lld -arch x86_64 -dylib %s -o %t %p/Inputs/x86_64/libSystem.yaml
2# RUN: llvm-nm %t | FileCheck %s
3#
4# Test that a data-only dylib can be built.
5#
6
7--- !mach-o
8arch:            x86_64
9file-type:       MH_OBJECT
10flags:           [ MH_SUBSECTIONS_VIA_SYMBOLS ]
11sections:
12  - segment:         __DATA
13    section:         __data
14    type:            S_REGULAR
15    attributes:      [  ]
16    alignment:       2
17    address:         0x0000000000000000
18    content:         [ 0x00, 0x00, 0x00, 0x00 ]
19global-symbols:
20  - name:            _myData
21    type:            N_SECT
22    scope:           [ N_EXT ]
23    sect:            1
24    value:           0x0000000000000000
25...
26
27# CHECK: _myData
28