Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
R
RIOT
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
cm-projects
RIOT
Commits
d69291c3
Commit
d69291c3
authored
7 years ago
by
Kaspar Schleiser
Browse files
Options
Downloads
Patches
Plain Diff
make: handle optional features in Makefile.dep
parent
a20745b6
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
Makefile.dep
+9
-0
9 additions, 0 deletions
Makefile.dep
makefiles/modules.inc.mk
+0
-2
0 additions, 2 deletions
makefiles/modules.inc.mk
with
9 additions
and
2 deletions
Makefile.dep
+
9
−
0
View file @
d69291c3
...
...
@@ -698,6 +698,15 @@ endif
# include package dependencies
-include
$(USEPKG:%=$(RIOTPKG)/%/Makefile.dep)
# remove required features from optional features
FEATURES_OPTIONAL
:=
$(
filter-out
$(
FEATURES_REQUIRED
)
,
$(
FEATURES_OPTIONAL
))
# add all optional but provided features to the list of used features
FEATURES_USED
:=
$(
sort
$(
FEATURES_REQUIRED
)
$(
filter
$(
FEATURES_OPTIONAL
)
,
$(
FEATURES_PROVIDED
)))
# all periph features correspond to a periph submodule
USEMODULE
+=
$(
filter periph_%,
$(
FEATURES_USED
))
# recursively catch transitive dependencies
USEMODULE
:=
$(
sort
$(
USEMODULE
))
USEPKG
:=
$(
sort
$(
USEPKG
))
...
...
This diff is collapsed.
Click to expand it.
makefiles/modules.inc.mk
+
0
−
2
View file @
d69291c3
USEMODULE
:=
$(
filter-out
$(
filter-out
$(
FEATURES_PROVIDED
)
,
$(
FEATURES_OPTIONAL
))
,
$(
sort
$(
USEMODULE
)))
ED
=
$(
addprefix FEATURE_,
$(
sort
$(
filter
$(
FEATURES_PROVIDED
)
,
$(
FEATURES_REQUIRED
))))
ED
+=
$(
addprefix MODULE_,
$(
sort
$(
USEMODULE
)
$(
USEPKG
)))
EXTDEFINES
=
$(
addprefix
-D
,
$(
shell
echo
'
$(
ED
)
'
|
tr
'a-z-'
'A-Z_'
))
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment