[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[tor-commits] [tor-browser-build/master] Add a testbuild target



commit 52ad50f034e007a72936be8775ad111bc968a42d
Author: Nicolas Vigier <boklm@xxxxxxxxxxxxxx>
Date:   Fri Feb 17 15:27:47 2017 +0100

    Add a testbuild target
---
 .gitignore                 |  1 +
 Makefile                   | 15 +++++++++++++++
 README                     |  6 ++++++
 projects/release/config    |  6 ++++++
 projects/tor-browser/build | 10 +++++++---
 rbm.conf                   | 11 +++++++++++
 rbm.local.conf.example     | 15 +++++++++++++++
 7 files changed, 61 insertions(+), 3 deletions(-)

diff --git a/.gitignore b/.gitignore
index e38b069..9b6754f 100644
--- a/.gitignore
+++ b/.gitignore
@@ -6,5 +6,6 @@ alpha
 alpha_nightly
 nightly
 hardened
+testbuild
 rbm.local.conf
 logs
diff --git a/Makefile b/Makefile
index ca46c9e..9481537 100644
--- a/Makefile
+++ b/Makefile
@@ -62,6 +62,21 @@ alpha_nightly-windows-i686: submodule-update
 alpha_nightly-osx-x86_64: submodule-update
 	$(rbm) build release --target alpha_nightly --target torbrowser-osx-x86_64
 
+testbuild: submodule-update
+	$(rbm) build release --target testbuild --target torbrowser-all
+
+testbuild-linux-x86_64: submodule-update
+	$(rbm) build release --target testbuild --target torbrowser-linux-x86_64
+
+testbuild-linux-i686: submodule-update
+	$(rbm) build release --target testbuild --target torbrowser-linux-i686
+
+testbuild-windows-i686: submodule-update
+	$(rbm) build release --target testbuild --target torbrowser-windows-i686
+
+testbuild-osx-x86_64: submodule-update
+	$(rbm) build release --target testbuild --target torbrowser-osx-x86_64
+
 hardened-linux-x86_64: submodule-update
 	$(rbm) build release --target hardened --target torbrowser-linux-x86_64
 
diff --git a/README b/README
index e3672ec..a14fb42 100644
--- a/README
+++ b/README
@@ -70,6 +70,12 @@ name to the makefile target:
   $ make nightly-windows-i686
   $ make nightly-osx-x86_64
 
+When you want to quickly do a build to test a change, you can use the
+testbuild makefile target, and find the build in the testbuild directory.
+The build will be the same as regular alpha builds, except that in order
+to make the build faster, only the en-US locale will be built, and no
+mar file will be created.
+
 
 Updating git sources
 --------------------
diff --git a/projects/release/config b/projects/release/config
index febe801..e2b2eb9 100644
--- a/projects/release/config
+++ b/projects/release/config
@@ -54,6 +54,12 @@ targets:
     var:
       build_target: alpha
 
+  testbuild:
+    output_dir: 'testbuild'
+    version: '.'
+    var:
+      build_target: torbrowser-testbuild
+
   hardened_nightly:
     output_dir: 'hardened_nightly'
     version: '[% c("var/today") %]'
diff --git a/projects/tor-browser/build b/projects/tor-browser/build
index 3763b21..f952a95 100644
--- a/projects/tor-browser/build
+++ b/projects/tor-browser/build
@@ -240,9 +240,13 @@ python $MARTOOLS/createprecomplete.py
 popd
 
 cd $distdir
-# Create full MAR file and compressed package.
-MAR_FILE=tor-browser-[% c("var/mar_osname") %]-[% c("var/torbrowser_version") %]_${PKG_LOCALE}.mar
-MAR=$MARTOOLS/mar MBSDIFF=$MARTOOLS/mbsdiff $MARTOOLS/make_full_update.sh -q $OUTDIR/$MAR_FILE "$TBDIR"
+
+[% IF c("var/build_mar") -%]
+  # Create full MAR file and compressed package.
+  MAR_FILE=tor-browser-[% c("var/mar_osname") %]-[% c("var/torbrowser_version") %]_${PKG_LOCALE}.mar
+  MAR=$MARTOOLS/mar MBSDIFF=$MARTOOLS/mbsdiff $MARTOOLS/make_full_update.sh -q $OUTDIR/$MAR_FILE "$TBDIR"
+[% END -%]
+
 [% IF c("var/linux") %]
   [% c('tar', {
         tar_src => [ '$PKG_DIR' ],
diff --git a/rbm.conf b/rbm.conf
index 5faf4cb..5a29308 100644
--- a/rbm.conf
+++ b/rbm.conf
@@ -10,6 +10,7 @@ var:
   torbrowser_version: '6.5n'
   project_name: tor-browser
   multi_lingual: 0
+  build_mar: 1
   # By default, we sort the list of installed packages. This allows sharing
   # containers with identical list of packages, even if they are not listed
   # in the same order. In the cases where the installation order is
@@ -63,6 +64,16 @@ targets:
     var:
       multi_lingual: 1
 
+  torbrowser-testbuild:
+    - testbuild
+    - alpha
+  testbuild:
+    var:
+      # To make build faster, don't build any locale
+      locales: []
+      # Don't create mar files to save time
+      build_mar: 0
+
   torbrowser-linux-x86_64:
     - linux-x86_64
     - linux
diff --git a/rbm.local.conf.example b/rbm.local.conf.example
index ac54935..2a86647 100644
--- a/rbm.local.conf.example
+++ b/rbm.local.conf.example
@@ -39,4 +39,19 @@ var:
   ### file.
   #sign_build_gpg_opts: '--local-user XXXXXXXX'
 
+targets:
+
+  ### testbuild is based on alpha by default. Uncomment this if you want it
+  ### to be based on nightly.
+  #torbrowser-testbuild:
+  #  - testbuild
+  #  - nightly
+
+  testbuild:
+    var:
+      testbuild: 1
+
+      ### Uncomment this if you want to create mar files in your test build.
+      #build_mar: 1
+
 # vim: filetype=yaml sw=2

_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits