Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 52dd5576 authored by Tyler Baker's avatar Tyler Baker Committed by Shuah Khan
Browse files

selftest/memfd: enable cross compilation



Use the CC variable instead of hard coding gcc. Also clean up the compiler
options by creating a CFLAGS variable.

Signed-off-by: default avatarTyler Baker <tyler.baker@linaro.org>
Signed-off-by: default avatarShuah Khan <shuahkh@osg.samsung.com>
parent 48fd77d1
Loading
Loading
Loading
Loading
+4 −3
Original line number Diff line number Diff line
CC = $(CROSS_COMPILE)gcc
CFLAGS += -D_FILE_OFFSET_BITS=64
CFLAGS += -I../../../../include/uapi/
CFLAGS += -I../../../../include/

all:
	gcc $(CFLAGS) memfd_test.c -o memfd_test
	$(CC) $(CFLAGS) memfd_test.c -o memfd_test

TEST_PROGS := memfd_test

include ../lib.mk

build_fuse:
	gcc $(CFLAGS) fuse_mnt.c `pkg-config fuse --cflags --libs` -o fuse_mnt
	gcc $(CFLAGS) fuse_test.c -o fuse_test
	$(CC) $(CFLAGS) fuse_mnt.c `pkg-config fuse --cflags --libs` -o fuse_mnt
	$(CC) $(CFLAGS) fuse_test.c -o fuse_test

run_fuse: build_fuse
	@./run_fuse_test.sh || echo "fuse_test: [FAIL]"