Commit graph

1,911 commits

Author SHA1 Message Date
c67ce9fa1b py-mod.mk: Make python compilation errors fatal
Pass doraise=True to py_compile.compile()

Signed-off-by: Jan Lindemann <jan@janware.com>
2019-06-04 10:38:07 +00:00
f7b41f0652 mcu-flash.mk: Work around broken clean target
If MCU_BOARD_LC is empty, rm $(MCU_MEM|FLASH_FETCH_FILE_BIN) fails with unknown options.

Signed-off-by: Jan Lindemann <jan@janware.com>
2019-06-03 21:01:32 +00:00
c480eeaaca defs.mk, make.mk: Add CREATE_PKG_CONFIG variable
It was possible for DEVEL_TARGETS to contain install_PKG_CONFIG without a
package config file being built, fixed that.

Signed-off-by: Jan Lindemann <jan@janware.com>
2019-06-03 09:06:41 +00:00
956aea82eb py-*.mk: Fix python version detection
Signed-off-by: Jan Lindemann <jan@janware.com>
2019-06-03 08:00:39 +00:00
ae48f6aab6 projects-dir.mk: Ditch auto-detection of interactive use
PS1 isn't set if make is run interactively, which is why auto-detection of
interactive use doesn't work. Ditch that and introduce the INTERACTIVE
variable, which can be passed as INTERACTIVE=[y|n]. Default value als of now
is "n".

Signed-off-by: Jan Lindemann <jan@janware.com>
2019-06-03 07:41:43 +00:00
13fa28e23f make, scripts: Flip some more switches from pathon 2 to 3 (untested!)
This commit flips some more switches from Python 2 to Python 3 in makefiles and
Python code. Build runs through, but it's still likely to break things.

Signed-off-by: Jan Lindemann <jan@janware.com>
2019-06-02 12:28:13 +00:00
0d2e255bff projects-dir.mk: Only clean projects which have .done files lying around
Signed-off-by: Jan Lindemann <jan@janware.com>
2019-05-30 13:33:12 +00:00
5f92c65b0f project.conf: Add build dependency on xdg-utils
Signed-off-by: Jan Lindemann <jan@janware.com>
2019-05-25 07:47:29 +00:00
fb22c800dc projects-dir.mk: Add xdg-utils to BASE_PKGS (for xdg-open)
Signed-off-by: Jan Lindemann <jan@janware.com>
2019-05-25 07:35:32 +00:00
55cc335140 fix: PROJECT = jw-pf-3dprinter -> jw-pf
The contents of the PROJECT variable was misdetected from the directory name in
that everything after a number was discarded. This commit fixes that.

Signed-off-by: Jan Lindemann <jan@janware.com>
2019-05-19 13:13:14 +00:00
09a4c0a89f js.mk: Beautify error for non-existent closure-compiler.jar
Signed-off-by: Jan Lindemann <jan@janware.com>
2019-05-17 12:33:24 +00:00
91d7ba8aa4 projects-dir.mk: Add time to BASE_PKGS
Signed-off-by: Jan Lindemann <jan@janware.com>
2019-05-16 20:34:07 +00:00
bdeb2be59b subtree.mk: Files were RPM-shipped with development user id
Signed-off-by: Jan Lindemann <jan@janware.com>
2019-05-16 15:39:27 +00:00
a91420c3d2 defs-cpp.mk: Add support for openocd-st-xxx-jlink.cfg
Add support for openocd-st-nucleo-f103rb-jlink.cfg and
openocd-stmqspi-st-stm32f769i-disco-jlink.cfg

Signed-off-by: Jan Lindemann <jan@janware.com>
2019-05-12 18:24:31 +00:00
73ced2f4ec debugger.mk performance: Don't run gdb if no core file is present
Signed-off-by: Jan Lindemann <jan@janware.com>
2019-04-27 15:28:14 +00:00
49f269bdfe make: Modify only BUILD_*FLAGS in jw-build/make/*.mk
Assign only to BUILD_XXXFLAGS in jw-build/make/*.mk, and leave PROJECT_XXXFLAGS
and LOCAL_XXXFLAGS alone.

Signed-off-by: Jan Lindemann <jan@janware.com>
2019-04-10 06:43:40 +00:00
17a080138c make: Prefix BUILD_ to a couple of makefile variables
Rename variables to avoid collision:

  OBJ      -> BUILD_OBJ
  INCLUDE  -> BUILD_INCLUDE
  LIBFLAGS -> BUILD_LIBFLAGS
  LPPFLAGS -> BUILD_LPPFLAGS

Signed-off-by: Jan Lindemann <jan@janware.com>
2019-04-08 18:26:45 +00:00
8e0bd97eae git-submod.mk: Fix multiple branches in SUBMOD_MAIN_BRANCH
Signed-off-by: Jan Lindemann <jan@janware.com>
2019-04-08 13:18:47 +00:00
3ae0916ff4 defs-cpp.mk, platform.mk: Add support for st-disc1-f429i
Signed-off-by: Jan Lindemann <jan@janware.com>
2019-04-04 14:36:38 +00:00
e7d9cc3701 defs-cpp.mk: Don't use -ldl for MinGW targets
-ldl breaks build on MinGW: cannot find -ldl

Signed-off-by: Jan Lindemann <jan@janware.com>
2019-03-30 13:20:41 +00:00
32b9837373 defs.mk, mcu-exe.mk: Code beautification
Signed-off-by: Jan Lindemann <jan@janware.com>
2019-03-30 10:47:48 +00:00
80f9466648 mcu-flash.mk: Prefix flash commands with time -p
Flashing 64MB of external flash turns out to be really slow

Signed-off-by: Jan Lindemann <jan@janware.com>
2019-03-30 10:17:26 +00:00
c6fa2f3807 defs-cpp.mk, mcu-defs.mk: Do MCU_OPENOCD_CFG_NAME definition from one place
MCU_OPENOCD_CFG_NAME was defined in cfg-cpp.mk and mcu-defs.mk. Not sure which
is the best place, but have them compete is clearly the worst idea. This patch
puts them into defs-cpp.mk. A future patch should place the whole bunch
somewhere else, I guess.

Signed-off-by: Jan Lindemann <jan@janware.com>
2019-03-30 10:17:19 +00:00
29b4d4f2a5 dev-utils.mk: Fix in-tree process-text-files.py location
Signed-off-by: Jan Lindemann <jan@janware.com>
2019-03-29 16:45:39 +00:00
e54c20de8c defs.mk: Add function uniq
Signed-off-by: Jan Lindemann <jan@janware.com>
2019-03-29 16:45:20 +00:00
5210ba2acf make: Improve dependency tracking for exe targets
- Add wildcarded linker scripts to dependencies
- Run flash-push only on current hex file

Signed-off-by: Jan Lindemann <jan@janware.com>
2019-03-29 16:44:42 +00:00
9c773838c7 make: Improve flash-fetch targets
- Add support MCU_FLASH_BANK_NAME to support multiple banks
- Prefix binaries with TARGET_PRODUCT, if defined
- Fix flash data for stm32f769i-disco

Signed-off-by: Jan Lindemann <jan@janware.com>
2019-03-29 13:32:16 +00:00
ed76759a42 defs-cpp.mk, mcu-defs.mk, rules.mk: Code beautification and re-ordering
Signed-off-by: Jan Lindemann <jan@janware.com>
2019-03-22 21:43:16 +00:00
419d3b2a08 defs-cpp.mk, defs.mk, platform.mk: More cleanup to defs-cpp.mk
- Group more consistently into overall default choices, template cascade and
  compiler flags
- Add definitions for st-nucleo-f103rb (for now)

Signed-off-by: Jan Lindemann <jan@janware.com>
2019-03-20 15:06:25 +00:00
afffbd2566 defs-cpp.mk: Fix debug / optimize conditions for arm-none-eabi
Signed-off-by: Jan Lindemann <jan@janware.com>
2019-03-20 13:49:11 +00:00
f09eb174ef defs-cpp.mk, mcu-defs.mk, mcu-tags.mk: Dissolve mcu-tags.mk into defs-cpp.mk
Signed-off-by: Jan Lindemann <jan@janware.com>
2019-03-19 13:16:53 +00:00
58ab619f0b make: Rename CFLAGS, CXXFLAGS and CPPFLAGS variables
Rename CFLAGS and friends to follow the conventions of the implicit rules
defined by GNU Make:

 - $(CPPFLAGS) is passed to both C++ and C compiler
 - $(CXXFLAGS) is passed to C++ compiler only
 - $(CFLAGS) is passed to C compiler only
 - C++ compiler is in $(CXX)

Signed-off-by: Jan Lindemann <jan@janware.com>
2019-03-19 07:07:00 +00:00
dcba7d68bd make.mk: Minor code beautification
Signed-off-by: Jan Lindemann <jan@janware.com>
2019-03-18 19:14:55 +00:00
4a5ae9c734 mcu-*.mk: Support arm-none-eabi / modm
This commit adds compiler flags needed for compilation with modm. Cleanup is
needed, most notably should mcu-tags.mk be dissolved into defs-cpp.mk. The good
part is that it works.

Signed-off-by: Jan Lindemann <jan@janware.com>
2019-03-18 17:35:18 +00:00
714cf468f3 Add more default flags for arm-none-eabi:
LIBTYPE        ?= static
  BUILD_CPPFLAGS += -fno-exceptions -fno-rtti

Signed-off-by: Jan Lindemann <jan@janware.com>
2019-03-18 11:20:50 +00:00
0657d2104e process-text-files.py: Change jw-python script directory
Don't require process-text-files.py to be copied to jw-python/bin to run.

Signed-off-by: Jan Lindemann <jan@janware.com>
2019-03-18 10:34:02 +00:00
bc7468894e defs-dev.mk: Default USE_STACK_PROTECTOR to false
Signed-off-by: Jan Lindemann <jan@janware.com>
2019-03-18 10:34:01 +00:00
2a9cdc5540 debugger.mk, defs-cpp.mk: More consistent compiler flags
Implement more consistent handling of flags -std=xx, -gdb, -gdwarf-x.

Signed-off-by: Jan Lindemann <jan@janware.com>
2019-03-18 10:31:15 +00:00
68f25261ba make: Clean-indented makefiles
Signed-off-by: Jan Lindemann <jan@janware.com>
2019-03-17 16:24:26 +00:00
aa87adad04 platform.mk: Fix undefined SYSTEM_LIBDIR variable
Signed-off-by: Jan Lindemann <jan@janware.com>
2019-03-17 15:28:24 +00:00
526d559ca2 targets-tools.mk: Ongoing additions to clang-tidy target
Signed-off-by: Jan Lindemann <jan@janware.com>
2019-03-17 15:17:58 +00:00
2ea96f88a8 targets-tools.mk: Ongoing additions to clang-tidy-xxx targets
Signed-off-by: Jan Lindemann <jan@janware.com>
2019-03-17 15:11:14 +00:00
ed6e3fd70f git-submod.mk: Include $(MODDIR)/make/defs.mk
If defs.mk isn't included, CWD is undefined, which leads to an
attempt to add the wrong submodule path upon initialization

Signed-off-by: Jan Lindemann <jan@janware.com>
2019-03-17 15:10:22 +00:00
594becf931 Fix: CREATE_DEVEL wasn't set to true when it should
Fix a situation in which no devel RPM package was built

Signed-off-by: Jan Lindemann <jan@janware.com>
2019-03-17 15:02:33 +00:00
0c11e65d9c proj.mk: Rename classes in ytools / jw-cpp
Rename namespace:

	CppUtils      -> jw

Rename classes:

	YError        -> jw::Error
	YLogger       -> jw::Logger
	YMutex        -> jw::Mutex
	YDebugMutex   -> jw::DebugMutex
	YSlogMetaData -> jw::LogMetaData
	YTimeB        -> jw::Time

Signed-off-by: Jan Lindemann <jan@janware.com>
2019-03-16 14:48:16 +00:00
d8e76b4400 targets-tools.mk: Add some clang-tidy-xxx targets
Still to be refined

Signed-off-by: Jan Lindemann <jan@janware.com>
2019-03-16 10:43:23 +00:00
d71e6f92f5 dev-utils.mk: Follow change in jw-python/process-text-files.py
Signed-off-by: Jan Lindemann <jan@janware.com>
2019-03-16 10:42:42 +00:00
275d33d78b Fix: Libdl was statically linked by default
Signed-off-by: Jan Lindemann <jan@janware.com>
2019-03-13 16:38:32 +00:00
4a1c5b94df topdir.mk: Make git-init-remote more robust (at least in theory)
Signed-off-by: Jan Lindemann <jan@janware.com>
2019-03-13 15:45:01 +00:00
5b38496ce1 lib.mk: Disable building of .so and friends if no .a is present
Signed-off-by: Jan Lindemann <jan@janware.com>
2019-03-13 15:26:22 +00:00