mirror of
https://github.com/clearlinux/graphene.git
synced 2026-09-06 22:01:29 +00:00
* add memusg to pal_loader script * Stop bleeding PAL handles. Deprecating DkOjectReference and reference counting in PAL handle. Deprecating DkSemaphoreDestroy and DkEventDestroy (replaced by DkObjectClose). Cleaning unused PAL handles in the library OS. Adding a heap tracing feature to profile usage of PAL handles. * fix a bug in SGX mode that mapping untrusted files into memory never got free by DkVirtualMemoryFree() * adding lighttpd SSL option * fixing the freeing convention of PAL handles; On SGX, event and mutex handles need to be freed seperately. * changing how mutexes and events are allocated on SGX * fixing GCC regression tests (for both Linux and SGX) * fix a double-free problem of the first thread handle
65 lines
1.5 KiB
Makefile
65 lines
1.5 KiB
Makefile
include src/Makefile.Host
|
|
|
|
ifeq ($(OS),Linux)
|
|
NPROCS ?= $(shell grep -c ^processor /proc/cpuinfo)
|
|
else
|
|
NPROCS ?= 1
|
|
endif
|
|
|
|
ifeq ($(OS),Linux)
|
|
LINUX_GEN := 3.x
|
|
LINUX_SRC := linux-3.19
|
|
LINUX_KERNEL := $(LINUX_SRC)/arch/x86/boot/bzImage
|
|
endif
|
|
|
|
DIRS = src test regression
|
|
|
|
all clean:
|
|
for d in $(DIRS); \
|
|
do \
|
|
$(MAKE) -C $$d $@ || exit $?; \
|
|
done
|
|
|
|
.PHONY: linux-kernel
|
|
linux-kernel: $(LINUX_KERNEL)
|
|
|
|
ifneq ($(LINUX_KERNEL),)
|
|
$(LINUX_KERNEL): $(LINUX_SRC)/Makefile $(LINUX_SRC)/graphene $(LINUX_SRC)/.config
|
|
$(MAKE) -C $(LINUX_SRC) -j$(NPROCS)
|
|
|
|
$(LINUX_SRC)/Makefile:
|
|
[ -f $(LINUX_SRC).tar.gz ] || \
|
|
wget https://www.kernel.org/pub/linux/kernel/v$(LINUX_GEN)/$(LINUX_SRC).tar.gz
|
|
tar -xzf $(LINUX_SRC).tar.gz
|
|
cd $(LINUX_SRC) && patch -p1 < ../$(LINUX_SRC).patch
|
|
|
|
$(LINUX_SRC)/graphene: linux-kernel/graphene
|
|
cd $(LINUX_SRC) && ln -s ../linux-kernel/graphene graphene
|
|
|
|
$(LINUX_SRC)/.config: $(LINUX_SRC)/Makefile
|
|
cd $(LINUX_SRC) && make menuconfig
|
|
|
|
kernel_install: kernel
|
|
$(MAKE) -C $(LINUX_SRC) install modules_install headers_install
|
|
|
|
linux-deb:
|
|
if [ ! -f $(LINUX_SRC)/.config ]; then \
|
|
cp /boot/config-$(shell uname -r) $(LINUX_SRC)/.config && \
|
|
cd $(LINUX_SRC) && $(MAKE) menuconfig; fi
|
|
cd $(LINUX_SRC) && \
|
|
CONCURRENCY_LEVEL=$(NPROCS) make-kpkg --rootcmd fakeroot \
|
|
--append-to-version -graphene --initrd \
|
|
kernel_image kernel_headers $(if $(DEBUG),kernel_debug,)
|
|
else
|
|
kernel_install:
|
|
endif
|
|
|
|
.PHONY: test
|
|
test:
|
|
$(MAKE) -C test test
|
|
|
|
.PHONY: pack
|
|
pack:
|
|
$(MAKE) -C test pack
|
|
$(MAKE) -C regression pack
|