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

[tor-commits] [Git][tpo/applications/tor-browser][tor-browser-155.0a1-17.0-1] 2 commits: BB 41108: Remove privileged macOS installation



Title: GitLab

Pier Angelo Vendrame pushed to branch tor-browser-155.0a1-17.0-1 at The Tor Project / Applications / Tor Browser

Commits:

  • d646ae03
    by Pier Angelo Vendrame at 2026-11-04T21:59:23+01:00
    BB 41108: Remove privileged macOS installation
    
  • 8518d56b
    by Pier Angelo Vendrame at 2026-11-04T21:59:23+01:00
    fixup! Base Browser's .mozconfigs.
    
    BB 45240: Fix updater-related build errors on macOS.
    
    Introduce CONFIG["BASE_BROWSER"].
    

4 changed files:

Changes:

  • browser/app/moz.build
    ... ... @@ -80,6 +80,12 @@ if CONFIG["MOZ_WIDGET_TOOLKIT"] == "cocoa":
    80 80
                 f"!/{FINAL_TARGET}/org.mozilla.updater",
    
    81 81
                 "Library/LaunchServices/org.mozilla.updater",
    
    82 82
             ))
    
    83
    +    moves = [("ChannelPrefs.framework", "Frameworks/ChannelPrefs.framework")]
    
    84
    +    if not CONFIG["BASE_BROWSER"]:
    
    85
    +        moves.append((
    
    86
    +            "org.mozilla.dmgInstallHelper",
    
    87
    +            "Library/LaunchServices/org.mozilla.dmgInstallHelper",
    
    88
    +        ))
    
    83 89
         MacOSBundle(
    
    84 90
             f"!/dist/{CONFIG['MOZ_MACBUNDLE_NAME']}",
    
    85 91
             skeleton="macbuild/Contents",
    
    ... ... @@ -93,13 +99,7 @@ if CONFIG["MOZ_WIDGET_TOOLKIT"] == "cocoa":
    93 99
                 (f"!/{FINAL_TARGET}/{CONFIG['MOZ_APP_NAME']}", CONFIG["MOZ_APP_NAME"])
    
    94 100
             ],
    
    95 101
             extra_files=extra_files,
    
    96
    -        moves=[
    
    97
    -            ("ChannelPrefs.framework", "Frameworks/ChannelPrefs.framework"),
    
    98
    -            (
    
    99
    -                "org.mozilla.dmgInstallHelper",
    
    100
    -                "Library/LaunchServices/org.mozilla.dmgInstallHelper",
    
    101
    -            ),
    
    102
    -        ],
    
    102
    +        moves=moves,
    
    103 103
             pkginfo="APPLTORB",
    
    104 104
         )
    
    105 105
     
    

  • moz.configure
    ... ... @@ -1035,6 +1035,9 @@ def base_browser_version_quoted(value):
    1035 1035
         return f'"{value[0]}"'
    
    1036 1036
     
    
    1037 1037
     
    
    1038
    +set_config(
    
    1039
    +    "BASE_BROWSER", depends(base_browser_version)(lambda v: True if v else False)
    
    1040
    +)
    
    1038 1041
     set_define("BASE_BROWSER_VERSION", base_browser_version)
    
    1039 1042
     set_define("BASE_BROWSER_VERSION_QUOTED", base_browser_version_quoted)
    
    1040 1043
     
    

  • toolkit/moz.build
    ... ... @@ -63,11 +63,12 @@ if CONFIG["MOZ_WIDGET_TOOLKIT"] == "gtk":
    63 63
         ]
    
    64 64
     elif CONFIG["MOZ_WIDGET_TOOLKIT"] == "cocoa":
    
    65 65
         DIRS += [
    
    66
    -        "mozapps/dmgInstallHelper",
    
    67 66
             "mozapps/macos-frameworks",
    
    68 67
             "system/commonproxy",
    
    69 68
             "system/osxproxy",
    
    70 69
         ]
    
    70
    +    if not CONFIG["BASE_BROWSER"]:
    
    71
    +        DIRS += ["mozapps/dmgInstallHelper"]
    
    71 72
     elif CONFIG["MOZ_WIDGET_TOOLKIT"] == "windows":
    
    72 73
         DIRS += [
    
    73 74
             "system/commonproxy",
    

  • toolkit/xre/MacRunFromDmgUtils.mm
    ... ... @@ -279,6 +279,7 @@ static void ShowInstallFailedDialog() {
    279 279
       NS_OBJC_END_TRY_IGNORE_BLOCK;
    
    280 280
     }
    
    281 281
     
    
    282
    +#ifndef BASE_BROWSER_VERSION
    
    282 283
     // Install the DMGInstallHelper as an elevated helper and use it to install
    
    283 284
     bool LaunchElevatedDmgInstall(NSString* aBundlePath, NSString* aDestPath) {
    
    284 285
       NS_OBJC_BEGIN_TRY_BLOCK_RETURN;
    
    ... ... @@ -355,6 +356,7 @@ bool LaunchElevatedDmgInstall(NSString* aBundlePath, NSString* aDestPath) {
    355 356
     
    
    356 357
       NS_OBJC_END_TRY_BLOCK_RETURN(false);
    
    357 358
     }
    
    359
    +#endif
    
    358 360
     
    
    359 361
     // Note: both arguments are expected to contain the app name (to end with
    
    360 362
     // '.app').
    
    ... ... @@ -381,6 +383,7 @@ static bool InstallFromPath(NSString* aBundlePath, NSString* aDestPath) {
    381 383
       os_log_info(runFromDMGLogger, "Unelevated installation: %s",
    
    382 384
                   installSuccessful ? "success" : "failed");
    
    383 385
     
    
    386
    +#ifndef BASE_BROWSER_VERSION
    
    384 387
       // The installation may have been unsuccessful if the user did not have the
    
    385 388
       // rights to write to the Applications directory. Check for this situation and
    
    386 389
       // launch an elevated helper application.
    
    ... ... @@ -396,6 +399,7 @@ static bool InstallFromPath(NSString* aBundlePath, NSString* aDestPath) {
    396 399
           return false;
    
    397 400
         }
    
    398 401
       }
    
    402
    +#endif
    
    399 403
     
    
    400 404
       if (!installSuccessful) {
    
    401 405
         os_log_error(runFromDMGLogger, "Unknown install failure.");
    

  • _______________________________________________
    tor-commits mailing list -- tor-commits@xxxxxxxxxxxxxxxxxxxx
    To unsubscribe send an email to tor-commits-leave@xxxxxxxxxxxxxxxxxxxx