Makefile 742 字节
Newer Older
1 2
# Makefile for vm selftests

3 4 5 6
ifndef OUTPUT
  OUTPUT := $(shell pwd)
endif

7
CFLAGS = -Wall -I ../../../../usr/include $(EXTRA_CFLAGS)
8
LDLIBS = -lrt
9 10 11 12 13 14 15 16 17 18
TEST_GEN_FILES = compaction_test
TEST_GEN_FILES += hugepage-mmap
TEST_GEN_FILES += hugepage-shm
TEST_GEN_FILES += map_hugetlb
TEST_GEN_FILES += mlock2-tests
TEST_GEN_FILES += on-fault-limit
TEST_GEN_FILES += thuge-gen
TEST_GEN_FILES += transhuge-stress
TEST_GEN_FILES += userfaultfd
TEST_GEN_FILES += mlock-random-test
19

20 21 22
TEST_PROGS := run_vmtests

include ../lib.mk
23

24 25
$(OUTPUT)/userfaultfd: ../../../../usr/include/linux/kernel.h
$(OUTPUT)/userfaultfd: LDLIBS += -lpthread
26

27
$(OUTPUT)/mlock-random-test: LDLIBS += -lcap
28

29 30
../../../../usr/include/linux/kernel.h:
	make -C ../../../.. headers_install