I am new in FreeRTOS and I am trying to execute de Posix_GCC on Ubuntu 22.04.4 LTS.
I am using gcc 11.4.0 and make 4.3
When I launch the ./posix_demo I got this
[WARN] pthread_attr_setstack failed with return value: 22. Default stack will be used.
[WARN] Increase the stack size to PTHREAD_STACK_MIN.
Trace started.
The trace will be dumped to disk if a call to configASSERT() fails.
Starting full demo
*** stack smashing detected ***: terminated
Which version are you using? I tried the mainline and I do not see this crash. Here is my command history:
gh repo clone git@github.com:FreeRTOS/FreeRTOS.git
cd FreeRTOS/
git submodule update --init --recursive
cd FreeRTOS/Demo/Posix_GCC/
make
./build/posix_demo
And here is the output I see -
Trace started.
The trace will be dumped to disk if a call to configASSERT() fails.
Starting full demo
OK: No errors - tick count 10001
OK: No errors - tick count 20001
make and gcc versions are also same as yours:
$ make --version
GNU Make 4.3
Built for x86_64-pc-linux-gnu
Copyright (C) 1988-2020 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
$ gcc --version
gcc (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0
Copyright (C) 2021 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.