SW4STM32 and SW4Linux fully supports the STM32MP1 asymmetric multicore Cortex/A7+M4 MPUs

   With System Workbench for Linux, Embedded Linux on the STM32MP1 family of MPUs from ST was never as simple to build and maintain, even for newcomers in the Linux world. And, if you install System Workbench for Linux in System Workbench for STM32 you can seamlessly develop and debug asymmetric applications running partly on Linux, partly on the Cortex-M4.
You can get more information from the ac6-tools website and download (registration required) various documents highlighting:

System Workbench for STM32

Build directory cannot be created

I had no problem to compile projects with makefile up to the AC6 version 1.8
Recently, I installed the AC6 version 1.14, then I was no longer able to compile the project: I noticed the “build” directory could not be created under my project directory. Error message says:
/usr/make/sh: -c: line 0: syntax error near unexpected token `(’
/usr/make/sh: -c: line 0: `if not exist build\Src\ (echo ” MKDIR build\Src" & mkdir build\Src\)’
I am using Windows7. Same problem with AC6 2.0

What should I change?



This has been raised in another topicQuestion a month ago.

Waiting for a fix you can copy mkdir.exe from mingw into SystemWorkbench\plugins\fr.ac6.mcu.externaltools.arm-none.win32_xxx\tools\make.

Attached my version.

Hi jLn_38
Thank you for your answer. I’m afraid, it seems not to be exactly the same issue as the topic raised 1 month ago.
However I tried putting the mkdir in the directory you mentionned, without correct result.

Working with Windows 7, I was puzzled by the error message:

/usr/make/sh: -c: line 0: syntax error near unexpected token `(’

which made me think it reacts as if I was with Linux (opening a shell). I precise that the error occurs in the decision branch between windows or linux in my makefile.

After a lot of trials, I finally decided to remove (in fact to rename) the ‘sh.exe’ that exists in the directory C:\Ac6\SystemWorkbench\plugins\fr.ac6.mcu.externaltools.arm-none.win32_1.13.2.201705091103\tools\make

And now, it works!

But I still don’t understand why it worked with ac6 v1.8 and before, and no longer after...



Hi Bernard,

The reason it changed between 1.8 and no more in 1.14 or 2.0 was that, to avoid other problems, we included a bourne-compatible shell with make. So the fix proposed by jLn_38 is correct (include mkdir) but it’s not enough...

In fact you should adapt sligtly your makefile for it to work. There is two options there:

  1. Adapt your test to use the shell built-in test feature:
    if [ ! -d build ]; then mkdir build; fi
  2. Take advantage of the fact the mkdir is now a unix-like mkdir, which support the -p options, that allows you to just omit the test:
    mkdir -p build

Suppressing sh.exe from the plugin may fix your issue, but you will then have problems with, for example, projects generated by CubeMX; moreover, keeping the shell will allow you to use advanced makefile techniques.

In the future System Workbench for Linux may well require the shell to be able to compile correctly, so it’s probably better you correct your makefiles.

Hope this clarifies things,

Bernard (Ac6)

Very clear !
It works.
Thank you.



I’ve just created a new project and I’m having a lot of issues with it. When I tried to build it, a message appeared saying that ‘building is finished’.But lot of errors in console window. I figured out that binaries is missing under my file name in the project explorer. Please see the attachment showing the error message. I am building the default ‘void’ program available in the system workbench. Please reply.

I am using STM32 AC6 software system workbench & STM32F3 DISCOVERY Board. Please do the needful

Please reply then only i can start my research work. I am a new learner of this software.