Add FreeInkBook EPUB engine migration guide
Document migration plan from CrossPoint's lib/Epub to FreeInkBook, a memory-efficient clean-room EPUB engine. Covers advantages (O(paragraph+page) memory via SAX parsing, arena allocation, host-testable, full UAX#14 typography, runtime TTF/OTF support), 9-step migration strategy, ESP32-C3 constraints, and integration approach preserving existing UI layer while replacing parsing/layout stack.
This commit is contained in:
@@ -0,0 +1,34 @@
|
||||
# CpFontAdapter binds .cpfont metrics to FreeInkBook's RenderFont interface;
|
||||
# the suite needs the engine's freestanding headers. Prefer the submodule;
|
||||
# fall back to the sibling working checkout while the submodule pin predates
|
||||
# libs/book (drop the fallback once the pin advances).
|
||||
set(FREEINK_BOOK_INCLUDE "${REPO_ROOT}/freeink-sdk/libs/book/FreeInkBook/include")
|
||||
if(NOT EXISTS "${FREEINK_BOOK_INCLUDE}")
|
||||
set(FREEINK_BOOK_INCLUDE "$ENV{HOME}/GitHub/freeink-sdk/libs/book/FreeInkBook/include")
|
||||
endif()
|
||||
|
||||
if(NOT EXISTS "${FREEINK_BOOK_INCLUDE}")
|
||||
message(WARNING "FreeInkBook headers not found - skipping CpFontAdapterTest")
|
||||
else()
|
||||
add_executable(CpFontAdapterTest
|
||||
CpFontAdapterTest.cpp
|
||||
${REPO_ROOT}/src/activities/reader/CpFontAdapter.cpp
|
||||
${REPO_ROOT}/lib/EpdFont/EpdFont.cpp
|
||||
${REPO_ROOT}/lib/EpdFont/EpdFontFamily.cpp
|
||||
${REPO_ROOT}/lib/Utf8/Utf8.cpp
|
||||
)
|
||||
|
||||
target_include_directories(CpFontAdapterTest PRIVATE
|
||||
${REPO_ROOT}/src/activities/reader
|
||||
${REPO_ROOT}/lib/EpdFont
|
||||
${REPO_ROOT}/lib/Utf8
|
||||
${FREEINK_BOOK_INCLUDE}
|
||||
)
|
||||
|
||||
target_link_libraries(CpFontAdapterTest PRIVATE
|
||||
crosspoint_test_common
|
||||
GTest::gtest_main
|
||||
)
|
||||
|
||||
gtest_discover_tests(CpFontAdapterTest)
|
||||
endif()
|
||||
Reference in New Issue
Block a user