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

[tor-commits] [Git][tpo/applications/tor-browser-build][main] Bug 41102: Compress firefox source tarball in a container



Title: GitLab

boklm pushed to branch main at The Tor Project / Applications / tor-browser-build

Commits:

  • 5e9f8f0c
    by Nicolas Vigier at 2024-03-11T15:47:20+01:00
    Bug 41102: Compress firefox source tarball in a container
    
    As the xz version on the host can be different and produce different
    output, we compress the firefox source tarball inside a container.
    
    At the same time we use xz's --threads option to make compression
    faster by using multiple threads.
    
    We also move the src-tarballs step definition from rbm.conf to
    projects/firefox/config since it's not used in any other project.
    

3 changed files:

Changes:

  • projects/firefox/config
    ... ... @@ -58,9 +58,25 @@ steps:
    58 58
       src-tarballs:
    
    59 59
         filename: 'src-[% project %]-[% c("version") %].tar.xz'
    
    60 60
         version: '[% c("git_hash") %]'
    
    61
    -    input_files: []
    
    61
    +    input_files:
    
    62
    +      - project: container-image
    
    63
    +        pkg_type: build
    
    64
    +    compress_tar: ''
    
    62 65
         container:
    
    63
    -      use_container: 0
    
    66
    +      use_container: 1
    
    67
    +    var:
    
    68
    +      # single-thread and multi-thread xz will generate a different result,
    
    69
    +      # se we use at least 2 threads
    
    70
    +      xz_threads: '[% c("num_procs") == "1" ? "2" : c("num_procs") %]'
    
    71
    +    src-tarballs: |
    
    72
    +      #!/bin/bash
    
    73
    +      set -e
    
    74
    +      mkdir -p '[% dest_dir %]'
    
    75
    +      # Files copied to the container are owned by group root (rbm#40074),
    
    76
    +      # and it seems xz doesn't like that and exits with an error
    
    77
    +      chgrp rbm '[% project %]-[% c("version") %].tar'
    
    78
    +      xz --threads=[% c("var/xz_threads") %] -f '[% project %]-[% c("version") %].tar'
    
    79
    +      mv -vf '[% project %]-[% c("version") %].tar.xz' '[% dest_dir %]/[% c("filename") %]'
    
    64 80
         targets:
    
    65 81
           nightly:
    
    66 82
             version: '[% c("abbrev") %]'
    

  • projects/release/config
    ... ... @@ -229,8 +229,7 @@ input_files:
    229 229
        pkg_type: src-tarballs
    
    230 230
        target:
    
    231 231
          - '[% c("var/build_target") %]'
    
    232
    -     - browser-src
    
    233
    -     - '[% c("var/browser_type") %]'
    
    232
    +     - '[% c("var/browser_type") %]-macos'
    
    234 233
     
    
    235 234
     steps:
    
    236 235
       signtag:
    

  • rbm.conf
    ... ... @@ -14,14 +14,6 @@ container:
    14 14
         build: 1
    
    15 15
     
    
    16 16
     steps:
    
    17
    -  src-tarballs:
    
    18
    -    compress_tar: xz
    
    19
    -    src-tarballs: |
    
    20
    -      #!/bin/bash
    
    21
    -      set -e
    
    22
    -      mkdir -p '[% dest_dir %]'
    
    23
    -      mv -vf '[% project %]-[% c("version") %].tar.xz' '[% dest_dir %]/[% c("filename") %]'
    
    24
    -
    
    25 17
       list_toolchain_updates:
    
    26 18
         build_log: '-'
    
    27 19
         list_toolchain_updates: '[% INCLUDE list_toolchain_updates %]'
    

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