CI: Stick with ubuntu-22.04 for CodeQL analysis
[zfs.git] / module / Makefile.bsd
blob61a664c5bf66bf5bab95d9e5900269c0446ca8f6
1 .if !defined(WITH_CTF)
2 WITH_CTF=1
3 .endif
5 .include <bsd.sys.mk>
7 SRCDIR=${.CURDIR}
8 INCDIR=${.CURDIR:H}/include
10 KMOD=   openzfs
12 .PATH:  ${SRCDIR}/avl \
13         ${SRCDIR}/lua \
14         ${SRCDIR}/nvpair \
15         ${SRCDIR}/icp/algs/blake3 \
16         ${SRCDIR}/icp/algs/edonr \
17         ${SRCDIR}/icp/algs/sha2 \
18         ${SRCDIR}/icp/asm-aarch64/blake3 \
19         ${SRCDIR}/icp/asm-aarch64/sha2 \
20         ${SRCDIR}/icp/asm-arm/sha2 \
21         ${SRCDIR}/icp/asm-ppc64/sha2 \
22         ${SRCDIR}/icp/asm-ppc64/blake3 \
23         ${SRCDIR}/icp/asm-x86_64/blake3 \
24         ${SRCDIR}/icp/asm-x86_64/sha2 \
25         ${SRCDIR}/os/freebsd/spl \
26         ${SRCDIR}/os/freebsd/zfs \
27         ${SRCDIR}/unicode \
28         ${SRCDIR}/zcommon \
29         ${SRCDIR}/zfs \
30         ${SRCDIR}/zstd \
31         ${SRCDIR}/zstd/lib/common \
32         ${SRCDIR}/zstd/lib/compress \
33         ${SRCDIR}/zstd/lib/decompress
35 CFLAGS+= -I${INCDIR}
36 CFLAGS+= -I${SRCDIR}/icp/include
37 CFLAGS+= -I${INCDIR}/os/freebsd
38 CFLAGS+= -I${INCDIR}/os/freebsd/spl
39 CFLAGS+= -I${INCDIR}/os/freebsd/zfs
40 CFLAGS+= -I${SRCDIR}/zstd/include
41 CFLAGS+= -include ${INCDIR}/os/freebsd/spl/sys/ccompile.h
42 CFLAGS+= -I${.CURDIR}
44 CFLAGS+= -D__KERNEL__ -DFREEBSD_NAMECACHE -DBUILDING_ZFS -D__BSD_VISIBLE=1 \
45         -DHAVE_UIO_ZEROCOPY -DWITHOUT_NETDUMP -D__KERNEL -D_SYS_CONDVAR_H_ \
46         -D_SYS_VMEM_H_ -DKDTRACE_HOOKS -DCOMPAT_FREEBSD11
48 .if ${MACHINE_ARCH} == "amd64"
49 CFLAGS+= -D__x86_64 -DHAVE_SSE2 -DHAVE_SSSE3 -DHAVE_SSE4_1 -DHAVE_SSE4_2 \
50         -DHAVE_AVX -DHAVE_AVX2 -DHAVE_AVX512F -DHAVE_AVX512VL -DHAVE_AVX512BW
51 .endif
53 .if defined(WITH_DEBUG) && ${WITH_DEBUG} == "true"
54 CFLAGS+= -DZFS_DEBUG -g
55 .if defined(WITH_INVARIANTS) && ${WITH_INVARIANTS} == "true"
56  CFLAGS+= -DINVARIANTS -DWITNESS -DOPENSOLARIS_WITNESS
57 .endif
58 .if defined(WITH_O0) && ${WITH_O0} == "true"
59  CFLAGS+= -O0
60 .endif
61 .else
62 CFLAGS += -DNDEBUG
63 .endif
65 .if defined(WITH_VFS_DEBUG) && ${WITH_VFS_DEBUG} == "true"
66 # kernel must also be built with this option for this to work
67 CFLAGS+= -DDEBUG_VFS_LOCKS
68 .endif
70 .if defined(WITH_GCOV) && ${WITH_GCOV} == "true"
71 CFLAGS+=         -fprofile-arcs -ftest-coverage
72 .endif
74 DEBUG_FLAGS=-g
76 .if ${MACHINE_ARCH} == "i386" || ${MACHINE_ARCH} == "powerpc" || \
77         ${MACHINE_ARCH} == "powerpcspe" || ${MACHINE_ARCH} == "arm"
78 CFLAGS+= -DBITS_PER_LONG=32
79 .else
80 CFLAGS+= -DBITS_PER_LONG=64
81 .endif
83 SRCS=   vnode_if.h device_if.h bus_if.h
85 #avl
86 SRCS+=  avl.c
88 #icp/algs/blake3
89 SRCS+=  blake3.c \
90         blake3_generic.c \
91         blake3_impl.c
93 #icp/asm-aarch64/blake3
94 SRCS+=  b3_aarch64_sse2.S \
95         b3_aarch64_sse41.S
97 #icp/asm-ppc64/blake3
98 SRCS+=  b3_ppc64le_sse2.S \
99         b3_ppc64le_sse41.S
101 #icp/asm-x86_64/blake3
102 SRCS+=  blake3_avx2.S \
103         blake3_avx512.S \
104         blake3_sse2.S \
105         blake3_sse41.S
107 #icp/algs/edonr
108 SRCS+=  edonr.c
110 #icp/algs/sha2
111 SRCS+=  sha256_impl.c \
112         sha2_generic.c \
113         sha512_impl.c
115 #icp/asm-arm/sha2
116 SRCS+=  sha256-armv7.S \
117         sha512-armv7.S
119 #icp/asm-aarch64/sha2
120 SRCS+=  sha256-armv8.S \
121         sha512-armv8.S
123 #icp/asm-ppc64/sha2
124 SRCS+=  sha256-p8.S \
125         sha256-ppc.S \
126         sha512-p8.S \
127         sha512-ppc.S
129 #icp/asm-x86_64/sha2
130 SRCS+=  sha256-x86_64.S \
131         sha512-x86_64.S
133 #lua
134 SRCS+=  lapi.c \
135         lauxlib.c \
136         lbaselib.c \
137         lcode.c \
138         lcompat.c \
139         lcorolib.c \
140         lctype.c \
141         ldebug.c \
142         ldo.c \
143         lfunc.c \
144         lgc.c \
145         llex.c \
146         lmem.c \
147         lobject.c \
148         lopcodes.c \
149         lparser.c \
150         lstate.c \
151         lstring.c \
152         lstrlib.c \
153         ltable.c \
154         ltablib.c \
155         ltm.c \
156         lvm.c \
157         lzio.c
159 #nvpair
160 SRCS+=  fnvpair.c \
161         nvpair.c \
162         nvpair_alloc_fixed.c \
163         nvpair_alloc_spl.c
165 #os/freebsd/spl
166 SRCS+=  acl_common.c \
167         callb.c \
168         list.c \
169         spl_acl.c \
170         spl_cmn_err.c \
171         spl_dtrace.c \
172         spl_kmem.c \
173         spl_kstat.c \
174         spl_misc.c \
175         spl_policy.c \
176         spl_procfs_list.c \
177         spl_string.c \
178         spl_sunddi.c \
179         spl_sysevent.c \
180         spl_taskq.c \
181         spl_uio.c \
182         spl_vfs.c \
183         spl_vm.c \
184         spl_zlib.c \
185         spl_zone.c
187 .if ${MACHINE_ARCH} == "i386" || ${MACHINE_ARCH} == "powerpc" || \
188         ${MACHINE_ARCH} == "powerpcspe" || ${MACHINE_ARCH} == "arm"
189 SRCS+= spl_atomic.c
190 .endif
192 #os/freebsd/zfs
193 SRCS+=  abd_os.c \
194         arc_os.c \
195         crypto_os.c \
196         dmu_os.c \
197         event_os.c \
198         hkdf.c \
199         kmod_core.c \
200         spa_os.c \
201         sysctl_os.c \
202         vdev_file.c \
203         vdev_geom.c \
204         vdev_label_os.c \
205         zfs_acl.c \
206         zfs_ctldir.c \
207         zfs_debug.c \
208         zfs_dir.c \
209         zfs_file_os.c \
210         zfs_ioctl_compat.c \
211         zfs_ioctl_os.c \
212         zfs_racct.c \
213         zfs_vfsops.c \
214         zfs_vnops_os.c \
215         zfs_znode_os.c \
216         zio_crypt.c \
217         zvol_os.c
219 #unicode
220 SRCS+=  u8_textprep.c \
221         uconv.c
223 #zcommon
224 SRCS+=  cityhash.c \
225         zfeature_common.c \
226         zfs_comutil.c \
227         zfs_deleg.c \
228         zfs_fletcher_avx512.c \
229         zfs_fletcher.c \
230         zfs_fletcher_intel.c \
231         zfs_fletcher_sse.c \
232         zfs_fletcher_superscalar4.c \
233         zfs_fletcher_superscalar.c \
234         zfs_namecheck.c \
235         zfs_prop.c \
236         zfs_valstr.c \
237         zpool_prop.c \
238         zprop_common.c
240 #zfs
241 SRCS+=  abd.c \
242         aggsum.c \
243         arc.c \
244         blake3_zfs.c \
245         blkptr.c \
246         bplist.c \
247         bpobj.c \
248         bptree.c \
249         bqueue.c \
250         brt.c \
251         btree.c \
252         dataset_kstats.c \
253         dbuf.c \
254         dbuf_stats.c \
255         ddt.c \
256         ddt_log.c \
257         ddt_stats.c \
258         ddt_zap.c \
259         dmu.c \
260         dmu_direct.c \
261         dmu_diff.c \
262         dmu_object.c \
263         dmu_objset.c \
264         dmu_recv.c \
265         dmu_redact.c \
266         dmu_send.c \
267         dmu_traverse.c \
268         dmu_tx.c \
269         dmu_zfetch.c \
270         dnode.c \
271         dnode_sync.c \
272         dsl_bookmark.c \
273         dsl_crypt.c \
274         dsl_dataset.c \
275         dsl_deadlist.c \
276         dsl_deleg.c \
277         dsl_destroy.c \
278         dsl_dir.c \
279         dsl_pool.c \
280         dsl_prop.c \
281         dsl_scan.c \
282         dsl_synctask.c \
283         dsl_userhold.c \
284         edonr_zfs.c \
285         fm.c \
286         gzip.c \
287         lz4.c \
288         lz4_zfs.c \
289         lzjb.c \
290         metaslab.c \
291         mmp.c \
292         multilist.c \
293         objlist.c \
294         pathname.c \
295         range_tree.c \
296         refcount.c \
297         rrwlock.c \
298         sa.c \
299         sha2_zfs.c \
300         skein_zfs.c \
301         spa.c \
302         space_map.c \
303         space_reftree.c \
304         spa_checkpoint.c \
305         spa_config.c \
306         spa_errlog.c \
307         spa_history.c \
308         spa_log_spacemap.c \
309         spa_misc.c \
310         spa_stats.c \
311         txg.c \
312         uberblock.c \
313         unique.c \
314         vdev.c \
315         vdev_draid.c \
316         vdev_draid_rand.c \
317         vdev_indirect_births.c \
318         vdev_indirect.c \
319         vdev_indirect_mapping.c \
320         vdev_initialize.c \
321         vdev_label.c \
322         vdev_mirror.c \
323         vdev_missing.c \
324         vdev_queue.c \
325         vdev_raidz.c \
326         vdev_raidz_math_avx2.c \
327         vdev_raidz_math_avx512bw.c \
328         vdev_raidz_math_avx512f.c \
329         vdev_raidz_math.c \
330         vdev_raidz_math_scalar.c \
331         vdev_raidz_math_sse2.c \
332         vdev_raidz_math_ssse3.c \
333         vdev_rebuild.c \
334         vdev_removal.c \
335         vdev_root.c \
336         vdev_trim.c \
337         zap.c \
338         zap_leaf.c \
339         zap_micro.c \
340         zcp.c \
341         zcp_get.c \
342         zcp_global.c \
343         zcp_iter.c \
344         zcp_set.c \
345         zcp_synctask.c \
346         zfeature.c \
347         zfs_byteswap.c \
348         zfs_chksum.c \
349         zfs_fm.c \
350         zfs_fuid.c \
351         zfs_impl.c \
352         zfs_ioctl.c \
353         zfs_log.c \
354         zfs_onexit.c \
355         zfs_quota.c \
356         zfs_ratelimit.c \
357         zfs_replay.c \
358         zfs_rlock.c \
359         zfs_sa.c \
360         zfs_vnops.c \
361         zfs_znode.c \
362         zil.c \
363         zio.c \
364         zio_checksum.c \
365         zio_compress.c \
366         zio_inject.c \
367         zle.c \
368         zrlock.c \
369         zthr.c \
370         zvol.c
372 #zstd
373 SRCS+=  zfs_zstd.c
375 #zstd/common
376 SRCS+=  entropy_common.c \
377         error_private.c \
378         fse_decompress.c \
379         pool.c \
380         xxhash.c \
381         zstd_common.c \
383 #zstd/compress
384 SRCS+=  fse_compress.c \
385         hist.c \
386         huf_compress.c \
387         zstd_compress.c \
388         zstd_compress_literals.c \
389         zstd_compress_sequences.c \
390         zstd_compress_superblock.c \
391         zstd_double_fast.c \
392         zstd_fast.c \
393         zstd_lazy.c \
394         zstd_ldm.c \
395         zstd_opt.c
397 #zstd/decompress
398 SRCS+=  huf_decompress.c \
399         zstd_ddict.c \
400         zstd_decompress_block.c \
401         zstd_decompress.c
403 beforeinstall:
404 .if ${MK_DEBUG_FILES} != "no"
405         mtree -eu \
406             -f /etc/mtree/BSD.debug.dist \
407             -p ${DESTDIR}/usr/lib
408 .endif
410 .include <bsd.kmod.mk>
412 # Generated binary search code is particularly bad with this optimization.
413 # Oddly, range_tree.c is not affected when unrolling is not done and dsl_scan.c
414 # is not affected when unrolling is done.
415 # Disable it until the following upstream issue is resolved:
416 # https://github.com/llvm/llvm-project/issues/62790
417 .if ${CC} == "clang"
418 .if ${MACHINE_ARCH} == "i386" || ${MACHINE_ARCH} == "amd64"
419 CFLAGS.dsl_scan.c= -mllvm -x86-cmov-converter=false
420 CFLAGS.metaslab.c= -mllvm -x86-cmov-converter=false
421 CFLAGS.range_tree.c= -mllvm -x86-cmov-converter=false
422 CFLAGS.zap_micro.c= -mllvm -x86-cmov-converter=false
423 .endif
424 .endif
426 CFLAGS.sysctl_os.c= -include ../zfs_config.h
427 CFLAGS.xxhash.c+= -include ${SYSDIR}/sys/_null.h
429 CFLAGS.gcc+= -Wno-pointer-to-int-cast
431 CFLAGS.abd.c= -Wno-cast-qual
432 CFLAGS.ddt.c= -Wno-cast-qual
433 CFLAGS.ddt_log.c= -Wno-cast-qual -Wno-pointer-arith
434 CFLAGS.ddt_zap.c= -Wno-cast-qual
435 CFLAGS.dmu.c= -Wno-cast-qual
436 CFLAGS.dmu_traverse.c= -Wno-cast-qual
437 CFLAGS.dnode.c= ${NO_WUNUSED_BUT_SET_VARIABLE}
438 CFLAGS.dsl_deadlist.c= -Wno-cast-qual
439 CFLAGS.dsl_dir.c= -Wno-cast-qual
440 CFLAGS.dsl_prop.c= -Wno-cast-qual
441 CFLAGS.edonr.c= -Wno-cast-qual
442 CFLAGS.fm.c= -Wno-cast-qual
443 CFLAGS.hist.c= -U__BMI__ -fno-tree-vectorize ${NO_WBITWISE_INSTEAD_OF_LOGICAL}
444 CFLAGS.lapi.c= -Wno-cast-qual
445 CFLAGS.lcompat.c= -Wno-cast-qual
446 CFLAGS.ldo.c= ${NO_WINFINITE_RECURSION}
447 CFLAGS.lobject.c= -Wno-cast-qual
448 CFLAGS.ltable.c= -Wno-cast-qual
449 CFLAGS.lvm.c= -Wno-cast-qual
450 CFLAGS.lz4.c= -Wno-cast-qual
451 CFLAGS.lz4_zfs.c= -Wno-cast-qual
452 CFLAGS.nvpair.c= -Wno-cast-qual -DHAVE_RPC_TYPES ${NO_WSTRINGOP_OVERREAD}
453 CFLAGS.pool.c+= ${NO_WBITWISE_INSTEAD_OF_LOGICAL}
454 CFLAGS.pool.c= -U__BMI__ -fno-tree-vectorize
455 CFLAGS.spa.c= -Wno-cast-qual
456 CFLAGS.spa_misc.c= -Wno-cast-qual
457 CFLAGS.spl_string.c= -Wno-cast-qual
458 CFLAGS.spl_vm.c= -Wno-cast-qual
459 CFLAGS.spl_zlib.c= -Wno-cast-qual
460 CFLAGS.u8_textprep.c= -Wno-cast-qual
461 CFLAGS.vdev_draid.c= -Wno-cast-qual
462 CFLAGS.vdev_raidz.c= -Wno-cast-qual
463 CFLAGS.vdev_raidz_math.c= -Wno-cast-qual
464 CFLAGS.vdev_raidz_math_avx2.c= -Wno-cast-qual -Wno-duplicate-decl-specifier
465 CFLAGS.vdev_raidz_math_avx512f.c= -Wno-cast-qual -Wno-duplicate-decl-specifier
466 CFLAGS.vdev_raidz_math_scalar.c= -Wno-cast-qual
467 CFLAGS.vdev_raidz_math_sse2.c= -Wno-cast-qual -Wno-duplicate-decl-specifier
468 CFLAGS.zap_leaf.c= -Wno-cast-qual
469 CFLAGS.zap_micro.c= -Wno-cast-qual
470 CFLAGS.zcp.c= -Wno-cast-qual
471 CFLAGS.zfs_fletcher.c= -Wno-cast-qual -Wno-pointer-arith
472 CFLAGS.zfs_fletcher_avx512.c= -Wno-cast-qual -Wno-pointer-arith
473 CFLAGS.zfs_fletcher_intel.c= -Wno-cast-qual -Wno-pointer-arith
474 CFLAGS.zfs_fletcher_sse.c= -Wno-cast-qual -Wno-pointer-arith
475 CFLAGS.zfs_fm.c= -Wno-cast-qual ${NO_WUNUSED_BUT_SET_VARIABLE}
476 CFLAGS.zfs_ioctl.c= -Wno-cast-qual
477 CFLAGS.zfs_log.c= -Wno-cast-qual
478 CFLAGS.zfs_vnops_os.c= -Wno-pointer-arith
479 CFLAGS.zfs_zstd.c= -Wno-cast-qual -Wno-pointer-arith
480 CFLAGS.zil.c= -Wno-cast-qual
481 CFLAGS.zio.c= -Wno-cast-qual
482 CFLAGS.zprop_common.c= -Wno-cast-qual
483 CFLAGS.zrlock.c= -Wno-cast-qual
485 #zstd
486 CFLAGS.entropy_common.c= -U__BMI__ -fno-tree-vectorize ${NO_WBITWISE_INSTEAD_OF_LOGICAL}
487 CFLAGS.error_private.c= -U__BMI__ -fno-tree-vectorize ${NO_WBITWISE_INSTEAD_OF_LOGICAL}
488 CFLAGS.fse_compress.c= -U__BMI__ -fno-tree-vectorize ${NO_WBITWISE_INSTEAD_OF_LOGICAL} ${NO_WUNUSED_BUT_SET_VARIABLE}
489 CFLAGS.fse_decompress.c= -U__BMI__ -fno-tree-vectorize ${NO_WBITWISE_INSTEAD_OF_LOGICAL}
490 CFLAGS.huf_compress.c= -U__BMI__ -fno-tree-vectorize ${NO_WBITWISE_INSTEAD_OF_LOGICAL}
491 CFLAGS.huf_decompress.c= -U__BMI__ -fno-tree-vectorize ${NO_WBITWISE_INSTEAD_OF_LOGICAL}
492 CFLAGS.xxhash.c+= -U__BMI__ -fno-tree-vectorize
493 CFLAGS.xxhash.c+= ${NO_WBITWISE_INSTEAD_OF_LOGICAL}
494 CFLAGS.zstd.c= -U__BMI__ -fno-tree-vectorize ${NO_WBITWISE_INSTEAD_OF_LOGICAL}
495 CFLAGS.zstd_common.c= -U__BMI__ -fno-tree-vectorize ${NO_WBITWISE_INSTEAD_OF_LOGICAL}
496 CFLAGS.zstd_compress.c= -U__BMI__ -fno-tree-vectorize ${NO_WBITWISE_INSTEAD_OF_LOGICAL}
497 CFLAGS.zstd_compress_literals.c= -U__BMI__ -fno-tree-vectorize ${NO_WBITWISE_INSTEAD_OF_LOGICAL}
498 CFLAGS.zstd_compress_sequences.c= -U__BMI__ -fno-tree-vectorize ${NO_WBITWISE_INSTEAD_OF_LOGICAL}
499 CFLAGS.zstd_compress_superblock.c= -U__BMI__ -fno-tree-vectorize ${NO_WBITWISE_INSTEAD_OF_LOGICAL} ${NO_WUNUSED_BUT_SET_VARIABLE}
500 CFLAGS.zstd_ddict.c= -U__BMI__ -fno-tree-vectorize ${NO_WBITWISE_INSTEAD_OF_LOGICAL}
501 CFLAGS.zstd_decompress.c= -U__BMI__ -fno-tree-vectorize ${NO_WBITWISE_INSTEAD_OF_LOGICAL}
502 CFLAGS.zstd_decompress_block.c= -U__BMI__ -fno-tree-vectorize ${NO_WBITWISE_INSTEAD_OF_LOGICAL}
503 CFLAGS.zstd_double_fast.c= -U__BMI__ -fno-tree-vectorize ${NO_WBITWISE_INSTEAD_OF_LOGICAL}
504 CFLAGS.zstd_fast.c= -U__BMI__ -fno-tree-vectorize ${NO_WBITWISE_INSTEAD_OF_LOGICAL}
505 CFLAGS.zstd_lazy.c= -U__BMI__ -fno-tree-vectorize ${NO_WBITWISE_INSTEAD_OF_LOGICAL}
506 CFLAGS.zstd_ldm.c= -U__BMI__ -fno-tree-vectorize ${NO_WBITWISE_INSTEAD_OF_LOGICAL}
507 CFLAGS.zstd_opt.c= -U__BMI__ -fno-tree-vectorize ${NO_WBITWISE_INSTEAD_OF_LOGICAL}
509 .if ${MACHINE_CPUARCH} == "aarch64"
510 __ZFS_ZSTD_AARCH64_FLAGS= -include ${SRCDIR}/zstd/include/aarch64_compat.h
511 CFLAGS.zstd.c+= ${__ZFS_ZSTD_AARCH64_FLAGS}
512 CFLAGS.entropy_common.c+= ${__ZFS_ZSTD_AARCH64_FLAGS}
513 CFLAGS.error_private.c+= ${__ZFS_ZSTD_AARCH64_FLAGS}
514 CFLAGS.fse_compress.c+= ${__ZFS_ZSTD_AARCH64_FLAGS}
515 CFLAGS.fse_decompress.c+= ${__ZFS_ZSTD_AARCH64_FLAGS}
516 CFLAGS.hist.c+= ${__ZFS_ZSTD_AARCH64_FLAGS}
517 CFLAGS.huf_compress.c+= ${__ZFS_ZSTD_AARCH64_FLAGS}
518 CFLAGS.huf_decompress.c+= ${__ZFS_ZSTD_AARCH64_FLAGS}
519 CFLAGS.pool.c+= ${__ZFS_ZSTD_AARCH64_FLAGS}
520 CFLAGS.xxhash.c+= ${__ZFS_ZSTD_AARCH64_FLAGS}
521 CFLAGS.zstd_common.c+= ${__ZFS_ZSTD_AARCH64_FLAGS}
522 CFLAGS.zstd_compress.c+= ${__ZFS_ZSTD_AARCH64_FLAGS}
523 CFLAGS.zstd_compress_literals.c+= ${__ZFS_ZSTD_AARCH64_FLAGS}
524 CFLAGS.zstd_compress_sequences.c+= ${__ZFS_ZSTD_AARCH64_FLAGS}
525 CFLAGS.zstd_compress_superblock.c+= ${__ZFS_ZSTD_AARCH64_FLAGS}
526 CFLAGS.zstd_ddict.c+= ${__ZFS_ZSTD_AARCH64_FLAGS}
527 CFLAGS.zstd_decompress.c+= ${__ZFS_ZSTD_AARCH64_FLAGS}
528 CFLAGS.zstd_decompress_block.c+= ${__ZFS_ZSTD_AARCH64_FLAGS}
529 CFLAGS.zstd_double_fast.c+= ${__ZFS_ZSTD_AARCH64_FLAGS}
530 CFLAGS.zstd_fast.c+= ${__ZFS_ZSTD_AARCH64_FLAGS}
531 CFLAGS.zstd_lazy.c+= ${__ZFS_ZSTD_AARCH64_FLAGS}
532 CFLAGS.zstd_ldm.c+= ${__ZFS_ZSTD_AARCH64_FLAGS}
533 CFLAGS.zstd_opt.c+= ${__ZFS_ZSTD_AARCH64_FLAGS}
535 sha256-armv8.o: sha256-armv8.S
536         ${CC} -c ${CFLAGS:N-mgeneral-regs-only} ${WERROR} ${.IMPSRC} \
537              -o ${.TARGET}
538         ${CTFCONVERT_CMD}
540 sha512-armv8.o: sha512-armv8.S
541         ${CC} -c ${CFLAGS:N-mgeneral-regs-only} ${WERROR} ${.IMPSRC} \
542              -o ${.TARGET}
543         ${CTFCONVERT_CMD}
545 b3_aarch64_sse2.o: b3_aarch64_sse2.S
546         ${CC} -c ${CFLAGS:N-mgeneral-regs-only} ${WERROR} ${.IMPSRC} \
547              -o ${.TARGET}
548         ${CTFCONVERT_CMD}
550 b3_aarch64_sse41.o: b3_aarch64_sse41.S
551         ${CC} -c ${CFLAGS:N-mgeneral-regs-only} ${WERROR} ${.IMPSRC} \
552              -o ${.TARGET}
553         ${CTFCONVERT_CMD}
555 .endif