arm-none-eabi-g++: error: src/main.ino.cpp: No such file or directory
arm-none-eabi-g++: fatal error: no input files
compilation terminated.
*** [.pio/build/cube/src/main.ino.cpp.o] Error 1
after platformio run --target clean
and new compilation I have
Assembler messages:
Fatal error: can’t create .pio/build/cube/FrameworkArduinoVariant/variant_RUMBA32.cpp.o: No such file or directory
*** [.pio/build/cube/FrameworkArduinoVariant/variant_RUMBA32.cpp.o] Error 1
Assembler messages:
Fatal error: can’t create .pio/build/cube/SrcWrapper/src/HAL/stm32yyxx_hal.c.o: No such file or directory
*** [.pio/build/cube/SrcWrapper/src/HAL/stm32yyxx_hal.c.o] Error 1
Assembler messages:
Fatal error: can’t create .pio/build/cube/SrcWrapper/src/HAL/stm32yyxx_hal_adc_ex.c.o: No such file or directory
*** [.pio/build/cube/SrcWrapper/src/HAL/stm32yyxx_hal_adc_ex.c.o] Error 1
Assembler messages:
Fatal error: can’t create .pio/build/cube/SrcWrapper/src/HAL/stm32yyxx_hal_adc.c.o: No such file or directory
*** [.pio/build/cube/SrcWrapper/src/HAL/stm32yyxx_hal_adc.c.o] Error 1
Also if it cannot create the output file, is the project directory on a sort of special path that may not be writable? Copying it to e.g. the home directory and retrying does not make a difference?
I have no antivirus
the directory has been used for ages without problems (Dropbox)
/Users/xxx/Dropbox/
I also have this error
*** [.pio/build/cube/FrameworkArduinoVariant] /Users/****/Dropbox/elektro/git/*** master/.pio/build/cube/FrameworkArduinoVariant: No such file or directory
FileNotFoundError: [Errno 2] No such file or directory: '/Users/****/Dropbox/elektro/git/SonicBio/mgr4/Code/MGR4 master/.pio/build/cube/.sconsign39.tmp':
File "/Users/****/.platformio/packages/tool-scons/scons-local-4.3.0/SCons/Script/Main.py", line 1401:
_exec_main(parser, values)
File "/Users/****/.platformio/packages/tool-scons/scons-local-4.3.0/SCons/Script/Main.py", line 1365:
_main(parser)
File "/Users/****/.platformio/packages/tool-scons/scons-local-4.3.0/SCons/Script/Main.py", line 1134:
nodes = _build_targets(fs, options, targets, target_top)
File "/Users/****/.platformio/packages/tool-scons/scons-local-4.3.0/SCons/Script/Main.py", line 1340:
jobs.run(postfunc = jobs_postfunc)
File "/Users/****/.platformio/packages/tool-scons/scons-local-4.3.0/SCons/Job.py", line 110:
postfunc()
File "/Users/****/.platformio/packages/tool-scons/scons-local-4.3.0/SCons/Script/Main.py", line 1337:
SCons.SConsign.write()
File "/Users/****/.platformio/packages/tool-scons/scons-local-4.3.0/SCons/SConsign.py", line 133:
syncmethod()
File "/Users/****/.platformio/packages/tool-scons/scons-local-4.3.0/SCons/dblite.py", line 148:
with self._open(self._tmp_name, "wb", self._mode) as f:
Exception ignored in: <function dblite.__del__ at 0x1034d4d30>
Traceback (most recent call last):
File "/Users/****/.platformio/packages/tool-scons/scons-local-4.3.0/SCons/dblite.py", line 144, in __del__
File "/Users/****/.platformio/packages/tool-scons/scons-local-4.3.0/SCons/dblite.py", line 141, in close
File "/Users/****/.platformio/packages/tool-scons/scons-local-4.3.0/SCons/dblite.py", line 148, in sync
FileNotFoundError: [Errno 2] No such file or directory: '/Users/****/Dropbox/elektro/git/*** master/.pio/build/cube/.sconsign39.tmp'
========================================================================================================================== [FAILED] Took 4.33 seconds ================
and when I clean
I have
*** [/Users/***/.platformio/packages/framework-arduinoststm32/variants/STM32F4xx/F446V(C-E)T/PeripheralPins.c] /Users-***/Dropbox/elektro/git/***master/.pio/build/cube/.sconsign39.dblite: No such file or directory
The .pio folder might have computer-specific caches in them, specifically e.g. .sconsign39.tmp. Maybe the .pio was synchronized from one computer to another computer and used there? You can let dropbox ignore a folder per How to set a Dropbox file or folder to be ignored - Dropbox Help
I have similar build issues. My workaround is to revert back to PlatformIO Core 5.2.5 (last release before core 6). Instructions on how to do this are found here:
Hoping a permanent fix is released soon. In the meantime this works for me.
Please open an issue about that at Issues · platformio/platformio-core · GitHub with the project that is exhibiting this behavior and system info (pio system info), only that way can sensible advancements be made that don’t include “revert back a major version”.
@maxgerhardt
The random build problem has been reported by others. The latest 6.0.x dev release has fixed some installations, but not all. For recent information please see the info posted last week by @TD-er, found here:
If @deladriere reports success with reverting to 5.2.5 then perhaps the info posted in his issue ticket will help solve the problem for good.
Glad the workaround resolved the build failure for you. Hopefully your posted details help lead to a fix so we can use Core 6.
One theory for what might cause this bug is related to PC performance. @TD-er observed that his fast desktop had better build success when compared to his slower notebook. That would seem to suggest that a process during a build is slow to create some files that another process tries to request. Just a wild guess on my part – this may have nothing to do with the build problem.
build failures for our users when using PlatformIO
Build failures on 6.0.1 which were confirmed fixed and were due to missing build flags don’t match the “I can only build twice perfectly fine and then it breaks with the compiler not being found”, that sounds like a whole different issue to me which enables a new issue to be opened.