From cc979a2a88e803f649a61645999944fe328fd352 Mon Sep 17 00:00:00 2001 From: mdankov Date: Sat, 24 Aug 2013 20:07:02 +0000 Subject: Add:port_android:Build localized Android string resources from gettext db. git-svn-id: http://svn.code.sf.net/p/navit/code/trunk/navit@5599 ffa7fe5e-494d-0410-b361-a75ebd5db220 --- cmake/strings_xml_parser.cmake | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 cmake/strings_xml_parser.cmake (limited to 'cmake') diff --git a/cmake/strings_xml_parser.cmake b/cmake/strings_xml_parser.cmake new file mode 100644 index 000000000..747af1c58 --- /dev/null +++ b/cmake/strings_xml_parser.cmake @@ -0,0 +1,10 @@ +file(STRINGS "${SRC}" TEXT_LINES REGEX "]+>(.*).*" "\\1" MSGID ${LINE}) + string(REGEX REPLACE "\\\\'" "'" MSGID ${MSGID}) + string(REGEX REPLACE ".*]+name=\"([^>\"]+)\">.*.*" "\\1" RESID ${LINE}) + file(APPEND ${DST} "// Android resource: @strings/${RESID}\n_(\"${MSGID}\")\n") +endforeach() + -- cgit v1.2.1