Experimental Titan build for Raspberry Pi [message #1745284] |
Fri, 07 October 2016 09:37 |
|
Dear all,
on the below link
https://www.eclipse.org/downloads/download.php?file=/titan/ttcn3-5.5.pl1-ARMv8-gcc4.9-raspbian.tgz
you can find a Titan core (compiler and executor) built for Raspberry Pi.
The exact build environment was:
Raspberry Pi 3 (64 bit quad-core ARMv8 CPU, 1 GB RAM)
Rasbpian - Debian 8 (Linux 4.4.21-v7, GCC 4.9.2)
If there will be interest for this build, manifested in at least a few downloads,
we will publish official releases for Raspberry/Raspbian as well.
In case you want to build from source, please follow the instructions in README.linux with the following addition:
"-fsigned-char" needs to be added to compielr flags in Makefile.cfg:
COMPILERFLAGS := -Wall -fsigned-char
Best regards
Elemer
|
|
|
Re: Experimental Titan build for Raspberry Pi [message #1748575 is a reply to message #1745284] |
Thu, 24 November 2016 16:13 |
Gyorgy Rethy Messages: 31 Registered: April 2015 |
Member |
|
|
Good experience with Titan on Raspberry Pi3, we could compile and execute both the CoAP example from this Forum and the ETSI cooperative ITS conformance test suite (actually, the microSD card's speed matters when compiling big code! ).
But note, Raspbian by default is missing the libssl-dev and libxml2-dev packages, needed for Titan to compile your code:
(just to synch with the raspbian repo before installing them)
sudo apt-get install libssl-dev libxml2-dev expect
(expect is required by ttcn3_start that makes command line test execution easier and automated).
The new Titan version 6.2.0 uses Openssl 1.0.0, which was not included into my Raspbian jessie (2017-09-07-raspbian-stretch.zip), so I needed to add it too:
sudo wget http://ftp.nl.debian.org/debian/pool/main/o/openssl/libssl1.0.0_1.0.1t-1+deb8u6_armhf.deb
sudo dpkg -i libssl1.0.0_1.0.1t-1+deb8u6_armhf.deb
and, of course don't forget to add the needed environment settings to the bash initialization script.
(just have used the default user name)
Add the lines:
TTCN3_DIR=<path where you have extracted the Titan package>
LD_LIBRARYPATH=/usr/lib
PATH=$PATH:$TTCN3_DIR/bin
export TTCN3_DIR LD_LIBRARYPATH PATH
Basically, that's all, you can start using it...
[Updated on: Mon, 30 October 2017 15:02] Report message to a moderator
|
|
|
|
Re: Experimental Titan build for Raspberry Pi [message #1838965 is a reply to message #1748618] |
Wed, 10 March 2021 14:14 |
Fabian So Messages: 4 Registered: January 2021 |
Junior Member |
|
|
Hello,
i was trying to build Titan 7.1.0 for a Raspberry Pi 4B.
I could build titan and my sources.
But when running a testcase, it works fine until almost the end until this message arrives and the MTC is stopped unexpectedly:
realloc(): invalid next size
./../bin/myets: Abort was called
./../bin/myets[0x21ed8c]
/lib/arm-linux-gnueabihf/libc.so.6(__default_sa_restorer+0x0)[0xb6836120]
Error: Unexpected end of MTC connection from 127.0.0.1 [127.0.0.1].
MC@nbiotclient: The control connection to MTC is lost. Destroying all PTC connections.
MC@nbiotclient: MTC terminated.
ttcn3_start: error: the MTC terminated unexpectedly
exit
The log-file looks fine and events are logged until i unmap my port. I just used a serial port for this test and that testcase was running successfully on an ubuntu host.
When i comment out the unmapping i get essentially the same error:
free(): invalid pointer
./../bin/myets: Abort was called
./../bin/myets[0x21ec3c]
/lib/arm-linux-gnueabihf/libc.so.6(__default_sa_restorer+0x0)[0xb68d7120]
The HelloWorld-Example runs without this problem.
I do not know if there are problems in the way i built the things or if the testports have to be adapted.
Does anybody have an idea, what could be the problem here?
The building process was as follows:
I set the compilerflags in Makefile.cfg and in Makefile.personal to:
COMPILERFLAGS := -Wall -fsigned-char
When building titan i got some suspicious warnings (format, format-overflow,..) when building, which i didn't get when building it for ubuntu 18.04. Anyways all was built successfully and also after make install both testcases pass.
select_union.sus->get_su_byIndex(i)->error("In the %lu. branch: '%s' is not an alternative of union type '%s'", i+1, id->get_ttcnname().c_str(), t_gov->get_typename().c_str());
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~
Statement.cc:3428:61: warning: format '%lu' expects argument of type 'long unsigned int', but argument 4 has type 'size_t' {aka 'unsigned int'} [-Wformat=]
select_union.sus->get_su_byIndex(i2)->error("The '%s' is already present in the %lu. branch of select union", id->get_ttcnname().c_str(), i+1);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~
Statement.cc: In static member function 'static void Ttcn::Statement::chk_index_redirect(Ttcn::Reference*, Ttcn::ArrayDimensions*, bool, const char*)':
Statement.cc:5426:34: warning: format '%lu' expects argument of type 'long unsigned int', but argument 3 has type 'size_t' {aka 'unsigned int'} [-Wformat=]
p_index_ref->error("This index redirect would result in a record "
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
"of integer of length %lu, which is not allowed by the length "
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
"restrictions of type `%s'",
~~~~~~~~~~~~~~~~~~~~~~~~~~~
nof_dims, ref_type->get_typename().c_str());
~~~~~~~~
(C++) TtcnTemplate.cc
TtcnTemplate.cc: In member function 'char* Ttcn::Template::generate_code_init_seof(char*, const char*)':
TtcnTemplate.cc:4323:33: warning: format '%lu' expects argument of type 'long unsigned int', but argument 4 has type 'size_t' {aka 'unsigned int'} [-Wformat=]
str = mputprintf(str, "%s.set_size(%lu", name, fixed_part);
I got similar warnings when building my sources.
|
|
|
|
|
|
|
|
|
Re: Experimental Titan build for Raspberry Pi [message #1839018 is a reply to message #1839017] |
Thu, 11 March 2021 11:58 |
Fabian So Messages: 4 Registered: January 2021 |
Junior Member |
|
|
Yes the manual execution works and also i tried it now with the HelloWorld-Example and also here it shows the errors and wont connect.
I tried the sanitizer and it shows (for the example of the link you provided and for the testsuite):
==2146==ASan runtime does not come first in initial library list; you should either link runtime to your application or manually preload it with LD_PRELOAD.
Edit:
The previous error was specific to the sanitizer. I had to add -static-libasan to the linker flags.
With the help of the sanitizer i could see that there was a memory leak in a testport, that i adapted. After fixing that it worked all fine. On Ubuntu anyways it worked fine even with that error in the testport. So now i have it running on a Raspberry 4 with Raspbian10 and Titan 7.1.0.
Thank you for your help.
[Updated on: Thu, 18 March 2021 05:39] Report message to a moderator
|
|
|
Powered by
FUDForum. Page generated in 0.04737 seconds