mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-26 17:40:27 +00:00
35 lines
1,005 B
Makefile
35 lines
1,005 B
Makefile
OBJS = \
|
|
DirectoryView.o \
|
|
main.o
|
|
|
|
APP = FileManager
|
|
|
|
ARCH_FLAGS =
|
|
STANDARD_FLAGS = -std=c++17 -nostdinc++ -nostdlib -nostdinc
|
|
USERLAND_FLAGS = -ffreestanding -fno-stack-protector -fno-ident
|
|
WARNING_FLAGS = -Wextra -Wall -Wundef -Wcast-qual -Wwrite-strings
|
|
FLAVOR_FLAGS = -march=i386 -m32 -fno-exceptions -fno-rtti -fmerge-all-constants -fno-unroll-loops -fno-pie -fno-pic
|
|
OPTIMIZATION_FLAGS = -Oz -fno-asynchronous-unwind-tables
|
|
INCLUDE_FLAGS = -I.. -I. -I../LibC
|
|
|
|
DEFINES = -DSERENITY -DSANITIZE_PTRS -DUSERLAND
|
|
|
|
CXXFLAGS = -MMD -MP $(WARNING_FLAGS) $(OPTIMIZATION_FLAGS) $(USERLAND_FLAGS) $(FLAVOR_FLAGS) $(ARCH_FLAGS) $(STANDARD_FLAGS) $(INCLUDE_FLAGS) $(DEFINES)
|
|
CXX = clang
|
|
LD = ld
|
|
AR = ar
|
|
LDFLAGS = -static --strip-debug -melf_i386 -e _start --gc-sections
|
|
|
|
all: $(APP)
|
|
|
|
$(APP): $(OBJS)
|
|
$(LD) -o $(APP) $(LDFLAGS) $(OBJS) ../LibGUI/LibGUI.a ../LibC/LibC.a
|
|
|
|
.cpp.o:
|
|
@echo "CXX $<"; $(CXX) $(CXXFLAGS) -o $@ -c $<
|
|
|
|
-include $(OBJS:%.o=%.d)
|
|
|
|
clean:
|
|
@echo "CLEAN"; rm -f $(APPS) $(OBJS) *.d
|
|
|