Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
C
contiki-ng
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
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
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
Admin message
Arrêt du service - 27/06 de 07h45 à 08h00 - Mise à jour de sécurité
Show more breadcrumbs
NATAF Emmanuel
contiki-ng
Commits
8da8c081
Unverified
Commit
8da8c081
authored
3 years ago
by
Nicolas Tsiftes
Committed by
GitHub
3 years ago
Browse files
Options
Downloads
Plain Diff
Merge pull request #1769 from pjonsson/detect-failure
tests: ensure cd is successful
parents
7a9f6324
1806db9b
Branches
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
tests/Makefile.compile-test
+11
-4
11 additions, 4 deletions
tests/Makefile.compile-test
with
11 additions
and
4 deletions
tests/Makefile.compile-test
+
11
−
4
View file @
8da8c081
...
@@ -39,7 +39,7 @@ get_target_vars = $(wordlist 2,15,$(subst :, ,$1))
...
@@ -39,7 +39,7 @@ get_target_vars = $(wordlist 2,15,$(subst :, ,$1))
define
dooneexample
define
dooneexample
@echo -n Building example $(3)
:
$(1) $(4) for target $(2)
@echo -n Building example $(3)
:
$(1) $(4) for target $(2)
@((cd
$(EXAMPLESDIR)/$(1)
;
\
@((cd
$(EXAMPLESDIR)/$(1)
&&
\
$(MAKE)
$(4)
TARGET
=
$(
2
)
clean
&&
make
-j
$(
4
)
TARGET
=
$(
2
)
WERROR
=
1
)
>
\
$(MAKE)
$(4)
TARGET
=
$(
2
)
clean
&&
make
-j
$(
4
)
TARGET
=
$(
2
)
WERROR
=
1
)
>
\
/dev/null 2>make.err
&&
\
/dev/null 2>make.err
&&
\
(
echo
" -> OK"
&&
printf
"%-75s %-40s %-20s TEST OK
\n
"
"
$(
1
)
"
"
$(
4
)
"
"
$(
2
)
"
>
$(
3
)
-
$(
subst /,-,
$(
1
))$(
2
)
.testlog
)
||
\
(
echo
" -> OK"
&&
printf
"%-75s %-40s %-20s TEST OK
\n
"
"
$(
1
)
"
"
$(
4
)
"
"
$(
2
)
"
>
$(
3
)
-
$(
subst /,-,
$(
1
))$(
2
)
.testlog
)
||
\
...
@@ -53,16 +53,23 @@ $(call dooneexample,$(dir $(call get_target,${1})),$(notdir $(call get_target,${
...
@@ -53,16 +53,23 @@ $(call dooneexample,$(dir $(call get_target,${1})),$(notdir $(call get_target,${
endef
endef
#end of GNU make magic
#end of GNU make magic
examples
:
examples
:
| $(EXAMPLESDIR)
$(
foreach ex,
$(
EXAMPLES
)
,
$(
call doexample,
${
ex
}))
$(
foreach ex,
$(
EXAMPLES
)
,
$(
call doexample,
${
ex
}))
$(EXAMPLESDIR)
:
@
echo
"Could not find examples directory
$(
EXAMPLESDIR
)
.
\n
"
@
echo
"If this failure is when running 19-out-of-tree-builds, clone"
@
echo
"https://github.com/contiki-ng/out-of-tree-tests into"
@
echo
"
$(
EXAMPLESDIR
)
and run the test again.
\n
"
@
false
summary
:
examples
summary
:
examples
@
cat
*
.testlog
>
summary
@
cat
*
.testlog
>
summary
@
echo
"========== Summary =========="
@
echo
"========== Summary =========="
@
cat
summary
@
cat
summary
clean
:
clean
:
| $(EXAMPLESDIR)
@
rm
-f
*
.testlog summary
@
rm
-f
*
.testlog summary
@$(
foreach example,
$(
EXAMPLES
)
,
\
@$(
foreach example,
$(
EXAMPLES
)
,
\
$(
foreach target,
$(
EXAMPLESTARGETS
)
,
\
$(
foreach target,
$(
EXAMPLESTARGETS
)
,
\
(
cd
$(
EXAMPLESDIR
)
/
$(
example
)
;
$(
MAKE
)
TARGET
=
$(
target
)
clean
);)
)
(
cd
$(
EXAMPLESDIR
)
/
$(
example
)
&&
$(
MAKE
)
TARGET
=
$(
target
)
clean
);)
)
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