Update the files which contain no license information with the
'Apache-2.0' SPDX license identifier. Many source files in the tree are
missing licensing information, which makes it harder for compliance
tools to determine the correct license.
By default all files without license information are under the default
license of Zephyr, which is Apache version 2.
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
Not needed in Python. Detected by check C0325 in pylint3.
Also replace an
if len(tag):
with just
if tag:
Empty strings, byte strings, lists, etc., are falsy in Python.
Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
Found by "disordered --shuffle-dirents=yes".
Sorting os.walk() in scripts/subfolder_list.py removes the randomness in
the following files:
build/zephyr/misc/generated/syscalls_subdirs.txt
build/zephyr/CMakeFiles/syscall_list_h_target.dir/ or build.ninja
Sorting os.walk() in scripts/parse_syscalls.py removes the randomness
in:
build/zephyr/misc/generated/syscalls.json
build/zephyr/include/generated/syscall_dispatch.c
build/zephyr/include/generated/syscall_list.h
Note my (limited so far) testing did *not* observe any randomness in any
object file that this would address; the main purpose here is to remove
a very large amount of noise in diffoscope.
Signed-off-by: Marc Herbert <marc.herbert@intel.com>
Fixes: #8380
This commit fixes the side-effect of PR #8211 where a 'ninja clean'
would try to remove dependency folders.
Changes:
- Symlinks are created during build and CMake targets now depends on
the symlinks. Thus, same behavior is achived with regards to
dependency handling, while at the same time, the output can be
cleaned as the dependencies are now attached to the symlinks.
- Dependencies have been changed so that generation of json files
depends on the trigger file and CMake depends upon the subdir txt
file. This prevents additional CMake runs after a clean.
Signed-off-by: Torsten Rasmussen <torsten.rasmussen@nordicsemi.no>
Fixes: #8210
Following changes has been made to ensure correct behavior on different
system:
- Python script to detect changes to directories, including empty ones.
When files are modified the list is updated
If sub-directories are added / removed a trigger file is touched to
notify cmake to re-run
- Windows: To detect changes to header files in include for
parse_syscalls.py all files must be individual monitored.
Hence all headers are globbed added to dependencies.
CMake configure depends on the folders so the added /
removed files are picked up.
- Other: Folders are monitored through the python list file so that
added / remove / modified
Added / removed sub-directories are detected through trigger
file in order to re-run cmake.
Signed-off-by: Torsten Rasmussen <torsten.rasmussen@nordicsemi.no>