- tinyblocks-blueprint: dona do estado de edicao (abas, pool de blocos, vinculos parent/prel/next/sub/args, blocos compostos e variaveis) e da serializacao. JSON nativo (to/from) usando a AST JSON do core e export JSON/XML/CSV. Testado com round-trip (test-blueprint). - tinyblocks-json: lexer + parser + emissor JSON independentes. - tinyblocks-xml: lexer + parser de XML -> AST JSON do core + emissor. - tinyblocks-csv: divisor de linhas/campos + parser/emissor sobre a AST JSON. - Editor: botoes Abrir / Salvar / Exportar JSON XML CSV no menu; converte Ed <-> TbBlueprint; barra de caminho com modo; .json pode ser arrastado. - Variaveis: tb_variables_clear e tb_variables_set_text. - Harness: teste de salvar/abrir projeto; tests/blueprint_test.c.
44 lines
1.4 KiB
Makefile
44 lines
1.4 KiB
Makefile
# Makefile da library editor (editor visual estilo Scratch)
|
|
# Constroi build/libtinyblocks-editor.a e build/libtinyblocks-editor.so
|
|
# Inclui o widget Editor.Stage (tb_stage.c).
|
|
CC := gcc
|
|
BUILD := build
|
|
CORE := ../../build
|
|
|
|
CFLAGS := -std=c11 -Wall -Wextra -pedantic -fvisibility=hidden \
|
|
-D_POSIX_C_SOURCE=200809L \
|
|
-I../../include -Iinclude -Isrc \
|
|
-I../tinyblocks-graphics/include \
|
|
-I../tinyblocks-variables/include \
|
|
-I../tinyblocks-blueprint/include
|
|
|
|
OBJ := $(BUILD)/tb_editor.o $(BUILD)/tb_stage_widget.o
|
|
LIB_A := $(BUILD)/libtinyblocks-editor.a
|
|
LIB_SO := $(BUILD)/libtinyblocks-editor.so
|
|
|
|
.PHONY: all static shared clean
|
|
all: static shared
|
|
static: $(LIB_A)
|
|
shared: $(LIB_SO)
|
|
|
|
$(BUILD)/tb_editor.o: src/tb_editor.c include/tb_editor.h src/tb_stage_widget.h \
|
|
../tinyblocks-graphics/include/tb_graphics.h \
|
|
../tinyblocks-variables/include/tb_variables.h \
|
|
../tinyblocks-blueprint/include/tb_blueprint.h
|
|
@mkdir -p $(BUILD)
|
|
$(CC) $(CFLAGS) -fPIC -c $< -o $@
|
|
|
|
$(BUILD)/tb_stage_widget.o: src/tb_stage_widget.c src/tb_stage_widget.h \
|
|
../tinyblocks-graphics/include/tb_graphics.h
|
|
@mkdir -p $(BUILD)
|
|
$(CC) $(CFLAGS) -fPIC -c $< -o $@
|
|
|
|
$(LIB_A): $(OBJ)
|
|
ar rcs $@ $^
|
|
|
|
$(LIB_SO): $(OBJ)
|
|
$(CC) -shared -o $@ $^ -ldl
|
|
|
|
clean:
|
|
$(RM) -r $(BUILD)
|