mirror of https://github.com/KLayout/klayout.git
Updated build scripts, fixed JUnit format emulation.
This commit is contained in:
parent
7c59235889
commit
807b044731
|
|
@ -66,6 +66,8 @@ target=$pwd/bin-release-$arch
|
|||
build=$pwd/build-release-$arch
|
||||
src=$pwd/src
|
||||
scripts=$pwd/scripts
|
||||
# Update in NSIS script too:
|
||||
plugins=audio generic iconengines imageformats platforms printsupport sqldrivers
|
||||
|
||||
echo "------------------------------------------------------------------"
|
||||
echo "Running build for architecture $arch .."
|
||||
|
|
@ -94,12 +96,14 @@ if ! [ -e $target/klayout.exe ]; then
|
|||
fi
|
||||
|
||||
# ----------------------------------------------------------
|
||||
# Image formats
|
||||
# Plugins
|
||||
|
||||
echo "Installing image format plugins .."
|
||||
cp -R $mingw_inst/share/qt5/plugins/imageformats $target
|
||||
# remove the debug versions - otherwise they pull in the debug Qt libs
|
||||
rm $target/imageformats/*d.dll
|
||||
for p in $plugins; do
|
||||
cp -R $mingw_inst/share/qt5/plugins/$p $target
|
||||
# remove the debug versions - otherwise they pull in the debug Qt libs
|
||||
rm $target/$p/*d.dll
|
||||
done
|
||||
|
||||
# ----------------------------------------------------------
|
||||
# Ruby dependencies
|
||||
|
|
@ -190,14 +194,6 @@ while [ "$new_libs" != "" ]; do
|
|||
|
||||
done
|
||||
|
||||
# ----------------------------------------------------------
|
||||
# Run Tests
|
||||
|
||||
set +e
|
||||
echo "Running unit tests .."
|
||||
TESTSRC=. TESTTMP=$build/testtmp $target/ut_runner -a | tee $build/ut_runner.xml
|
||||
set -e
|
||||
|
||||
# ----------------------------------------------------------
|
||||
# Run NSIS
|
||||
|
||||
|
|
@ -216,7 +212,7 @@ echo "Making .zip file $zipname.zip .."
|
|||
|
||||
rm -rf $zipname $zipname.zip
|
||||
mkdir $zipname
|
||||
cp -Rv *.dll .*-paths.txt imageformats lib $zipname | sed -u 's/.*/echo -n ./' | sh
|
||||
cp -Rv *.dll .*-paths.txt $plugins lib $zipname | sed -u 's/.*/echo -n ./' | sh
|
||||
cp klayout.exe $zipname/klayout_app.exe
|
||||
cp klayout.exe $zipname/klayout_vo_app.exe
|
||||
echo ""
|
||||
|
|
|
|||
|
|
@ -64,15 +64,16 @@ section
|
|||
# define output path
|
||||
setOutPath $INSTDIR
|
||||
|
||||
# specify files to go in output path
|
||||
# not installed because of disk space:
|
||||
# file strm2gds.exe
|
||||
# file strm2oas.exe
|
||||
# file strmclip.exe
|
||||
# file strmcmp.exe
|
||||
file strm*.exe
|
||||
file *.dll
|
||||
file .*-paths.txt
|
||||
file /r audio
|
||||
file /r generic
|
||||
file /r iconengines
|
||||
file /r imageformats
|
||||
file /r platforms
|
||||
file /r printsupport
|
||||
file /r sqldrivers
|
||||
file /r lib
|
||||
file /oname=${EXENAME}.exe ${EXEBASE}.exe
|
||||
file /oname=${EXENAME_VO}.exe ${EXEBASE}.exe
|
||||
|
|
|
|||
|
|
@ -17,9 +17,9 @@ SOURCES = \
|
|||
RESOURCES = \
|
||||
|
||||
DEFINES += \
|
||||
KLAYOUT_VERSION=$$KLAYOUT_VERSION \
|
||||
KLAYOUT_VERSION_REV=$$KLAYOUT_VERSION_REV \
|
||||
KLAYOUT_VERSION_DATE=$$KLAYOUT_VERSION_DATE \
|
||||
KLAYOUT_VERSION=$$(KLAYOUT_VERSION) \
|
||||
KLAYOUT_VERSION_REV=$$(KLAYOUT_VERSION_REV) \
|
||||
KLAYOUT_VERSION_DATE=$$(KLAYOUT_VERSION_DATE) \
|
||||
|
||||
INCLUDEPATH += ../tl ../gsi ../db ../rdb ../laybasic ../lay ../ext ../img ../ant ../lib
|
||||
DEPENDPATH += ../tl ../gsi ../db ../rdb ../laybasic ../lay ../ext ../img ../ant ../lib
|
||||
|
|
|
|||
|
|
@ -491,12 +491,18 @@ private:
|
|||
};
|
||||
|
||||
std::string
|
||||
noquotes (const std::string &s)
|
||||
escape_xml (const std::string &s)
|
||||
{
|
||||
std::string res;
|
||||
for (const char *cp = s.c_str (); *cp; ++cp) {
|
||||
if (*cp == '\"') {
|
||||
res += """;
|
||||
} else if (*cp == '<') {
|
||||
res += "<";
|
||||
} else if (*cp == '>') {
|
||||
res += ">";
|
||||
} else if (*cp == '&') {
|
||||
res += "&";
|
||||
} else {
|
||||
res += *cp;
|
||||
}
|
||||
|
|
@ -931,8 +937,8 @@ main_cont (int argc, char **argv)
|
|||
ut::sp_python_interpreter->push_console (&console);
|
||||
}
|
||||
|
||||
ut::ctrl << "<testsuite>";
|
||||
ut::ctrl << "<system-out>";
|
||||
ut::ctrl << "<?xml version=\"1.0\" encoding=\"UTF-8\" ?>";
|
||||
ut::ctrl << "<testsuites>";
|
||||
|
||||
ut::noctrl << replicate ("=", console.real_columns ());
|
||||
ut::noctrl << "Entering KLayout test suite";
|
||||
|
|
@ -973,8 +979,6 @@ main_cont (int argc, char **argv)
|
|||
selected_tests = &ut::Registrar::instance()->tests ();
|
||||
}
|
||||
|
||||
ut::ctrl << "</system-out>";
|
||||
|
||||
ut::s_verbose_flag = false;
|
||||
int failed_ne = 0, failed_e = 0;
|
||||
std::vector <ut::TestBase *> failed_tests_e, failed_tests_ne;
|
||||
|
|
@ -986,6 +990,7 @@ main_cont (int argc, char **argv)
|
|||
if ((non_editable && e == 0) || (editable && e == 1)) {
|
||||
|
||||
std::string mode (e == 0 ? "non-editable" : "editable");
|
||||
ut::ctrl << "<testsuite name=\"ut-runner-" << mode << "\">";
|
||||
|
||||
ut::noctrl << replicate ("=", console.real_columns ());
|
||||
ut::noctrl << "Running tests in " << mode << " mode ...";
|
||||
|
|
@ -1022,7 +1027,7 @@ main_cont (int argc, char **argv)
|
|||
|
||||
if (! (*t)->do_test (mode)) {
|
||||
|
||||
ut::ctrl << "<error message=\"" << "Test " << noquotes ((*t)->name ()) << " failed (continued mode - see previous messages)" << "\"/>";
|
||||
ut::ctrl << "<error message=\"" << "Test " << escape_xml ((*t)->name ()) << " failed (continued mode - see previous messages)" << "\"/>";
|
||||
tl::error << "Test " << (*t)->name () << " failed (continued mode - see previous messages)";
|
||||
|
||||
failed_tests.push_back (*t);
|
||||
|
|
@ -1040,7 +1045,7 @@ main_cont (int argc, char **argv)
|
|||
|
||||
} catch (tl::Exception &ex) {
|
||||
|
||||
ut::ctrl << "<failure message=\"" << noquotes (ex.msg ()) << "\"/>";
|
||||
ut::ctrl << "<failure message=\"" << escape_xml (ex.msg ()) << "\"/>";
|
||||
tl::error << "Test " << (*t)->name () << " failed:";
|
||||
tl::info << ex.msg ();
|
||||
|
||||
|
|
@ -1100,6 +1105,8 @@ main_cont (int argc, char **argv)
|
|||
ut::noctrl << "Total time: " << timer.sec_wall () << "s (wall) " << timer.sec_user () << "s (user) " << timer.sec_sys () << "s (sys)";
|
||||
ut::ctrl << "<x-summary-times mode=\"" << mode << "\" wall=\"" << timer.sec_wall () << "\" user=\"" << timer.sec_user () << "\" sys=\"" << timer.sec_sys () << "\"/>";
|
||||
|
||||
ut::ctrl << "</testsuite>";
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -1213,7 +1220,7 @@ main_cont (int argc, char **argv)
|
|||
result = -1;
|
||||
}
|
||||
|
||||
ut::ctrl << "</testsuite>";
|
||||
ut::ctrl << "</testsuites>";
|
||||
|
||||
return result;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue