Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
A
ardupilot
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
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
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
ACS
ardupilot
Commits
fcfed2e8
Commit
fcfed2e8
authored
12 years ago
by
Andrew Tridgell
Browse files
Options
Downloads
Patches
Plain Diff
autotest: build all binaries for master on each commit
parent
9487eb6c
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
Tools/autotest/autotest.py
+12
-0
12 additions, 0 deletions
Tools/autotest/autotest.py
Tools/scripts/build_binaries.sh
+97
-0
97 additions, 0 deletions
Tools/scripts/build_binaries.sh
with
109 additions
and
0 deletions
Tools/autotest/autotest.py
+
12
−
0
View file @
fcfed2e8
...
...
@@ -76,6 +76,14 @@ def build_all():
return
False
return
True
def
build_binaries
():
'''
run the build_binaries.sh script
'''
print
(
"
Running build_binaries.sh
"
)
if
util
.
run_cmd
(
util
.
reltopdir
(
'
Tools/scripts/build_binaries.sh
'
),
dir
=
util
.
reltopdir
(
'
.
'
))
!=
0
:
print
(
"
Failed build_binaries.sh
"
)
return
False
return
True
def
build_examples
():
'''
run the build_examples.sh script
'''
print
(
"
Running build_examples.sh
"
)
...
...
@@ -142,6 +150,7 @@ import arducopter, arduplane, apmrover2
steps
=
[
'
prerequesites
'
,
'
build.All
'
,
'
build.Binaries
'
,
'
build.Examples
'
,
'
build1280.ArduPlane
'
,
...
...
@@ -247,6 +256,9 @@ def run_step(step):
if
step
==
'
build.All
'
:
return
build_all
()
if
step
==
'
build.Binaries
'
:
return
build_binaries
()
if
step
==
'
build.Examples
'
:
return
build_examples
()
...
...
This diff is collapsed.
Click to expand it.
Tools/scripts/build_binaries.sh
0 → 100755
+
97
−
0
View file @
fcfed2e8
#!/bin/bash
# script to build the latest binaries for each vehicle type, ready to upload
# Andrew Tridgell, March 2013
set
-e
set
-x
export
PATH
=
$PATH
:/bin:/usr/bin
export
TMPDIR
=
$PWD
/build.tmp.
$$
echo
$TMDIR
rm
-rf
$TMPDIR
echo
"Building in
$TMPDIR
"
githash
=
$(
git rev-parse HEAD
)
hdate
=
$(
date
+
"%Y-%m/%Y-%m-%d-%H:%m"
)
mkdir
-p
binaries/
$hdate
binaries
=
$PWD
/../buildlogs/binaries
copyit
()
{
file
=
"
$1
"
dir
=
"
$2
"
bname
=
$(
basename
$dir
)
ldir
=
$(
dirname
$(
dirname
$dir
))
/latest/
$bname
mkdir
-p
"
$dir
"
/bin/cp
"
$file
"
"
$dir
"
mkdir
-p
"
$ldir
"
rsync
"
$file
"
"
$ldir
"
}
echo
"Building ArduPlane binaries"
pushd
ArduPlane
for
b
in
apm1 apm2 apm1-hilsensors apm2-hilsensors
;
do
pwd
make clean
make
$b
-j4
copyit
$TMPDIR
/ArduPlane.build/ArduPlane.hex
$binaries
/Plane/
$hdate
/
$b
done
popd
echo
"Building ArduCopter binaries"
pushd
ArduCopter
for
b
in
apm1 apm2 apm1-hil apm2-hil
;
do
pwd
make clean
make
$b
-j4
copyit
$TMPDIR
/ArduCopter.build/ArduCopter.hex
$binaries
/Copter/
$hdate
/
$b
done
popd
echo
"Building APMRover2 binaries"
pushd
APMrover2
for
b
in
apm1 apm2
;
do
pwd
make clean
make
$b
-j4
copyit
$TMPDIR
/APMrover2.build/APMrover2.hex
$binaries
/Rover/
$hdate
/
$b
done
popd
.
config.mk
test
-n
"
$PX4_ROOT
"
&&
test
-d
"
$PX4_ROOT
"
&&
{
echo
"Building ArduPlane PX4 binaries"
pushd
ArduPlane
make px4-clean
make px4
copyit
$PX4_ROOT
/Images/px4fmu.px4
$binaries
/Plane/
$hdate
/PX4
popd
echo
"Building ArduCopter PX4 binaries"
pushd
ArduCopter
make px4-clean
make px4
copyit
$PX4_ROOT
/Images/px4fmu.px4
$binaries
/Copter/
$hdate
/PX4
popd
echo
"Building APMrover2 PX4 binaries"
pushd
APMrover2
make px4-clean
make px4
copyit
$PX4_ROOT
/Images/px4fmu.px4
$binaries
/Rover/
$hdate
/PX4
popd
echo
"Building PX4IO firmware"
pushd
$PX4_ROOT
make clean
make configure_px4io
make
copyit
$PX4_ROOT
/Images/px4io.bin
$binaries
/PX4IO/
$hdate
/PX4IO
make configure_px4fmu
popd
}
rm
-rf
$TMPDIR
exit
0
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