1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 05:27:45 +00:00

LibDraw: Introduce (formerly known as SharedGraphics.)

Instead of LibGUI and WindowServer building their own copies of the drawing
and graphics code, let's it in a separate LibDraw library.

This avoids building the code twice, and will encourage better separation
of concerns. :^)
This commit is contained in:
Andreas Kling 2019-07-18 10:15:00 +02:00
parent 2167f60235
commit 1c0669f010
120 changed files with 201 additions and 190 deletions

View file

@ -0,0 +1,35 @@
include ../../Makefile.common
OBJS = \
CharacterBitmap.o \
Color.o \
DisjointRectSet.o \
Font.o \
GraphicsBitmap.o \
Painter.o \
PNGLoader.o \
Rect.o \
StylePainter.o
LIBRARY = libdraw.a
DEFINES += -DUSERLAND
all: $(LIBRARY)
$(LIBRARY): $(OBJS)
@echo "LIB $@"; $(AR) rcs $@ $(OBJS) $(LIBS)
.cpp.o:
@echo "CXX $<"; $(CXX) $(CXXFLAGS) -o $@ -c $<
-include $(OBJS:%.o=%.d)
clean:
@echo "CLEAN"; rm -f $(LIBRARY) $(OBJS) *.d
install: $(LIBRARY)
mkdir -p ../../Root/usr/include/LibGfx
# Copy headers
rsync -r -a --include '*/' --include '*.h' --exclude '*' . ../../Root/usr/include/LibGfx
# Install the library
cp $(LIBRARY) ../../Root/usr/lib