]> git.eshelyaron.com Git - emacs.git/commitdiff
Allow be-resources to fail
authorPo Lu <luangruo@yahoo.com>
Tue, 29 Nov 2022 06:25:04 +0000 (06:25 +0000)
committerPo Lu <luangruo@yahoo.com>
Tue, 29 Nov 2022 06:26:16 +0000 (06:26 +0000)
* lib-src/be_resources.cc (be_perror): Print additional blurb.
(main): Return 0 on failure as well, but print the blurb.
Problem reported by the Haiku packager.

lib-src/be_resources.cc

index 414f91a192d1e3cd5fd11f50931b8f59fc062591..ece573a85a601020ffc9048e75cbd4f1f2a4c271 100644 (file)
@@ -71,9 +71,11 @@ be_perror (status_t code, char *arg)
        }
     }
   else
-    {
-      abort ();
-    }
+    abort ();
+
+  fprintf (stderr, "Setting resources failed on the `src/Emacs' binary.\n"
+          "This may result in the installed `Emacs' binary not launching\n"
+          " from the tracker, but is inconsequential during packaging.\n");
 }
 
 int
@@ -111,19 +113,19 @@ main (int argc, char **argv)
   if (code != B_OK)
     {
       be_perror (code, argv[2]);
-      return EXIT_FAILURE;
+      return 0;
     }
   code = info.SetTo (&file);
   if (code != B_OK)
     {
       be_perror (code, argv[2]);
-      return EXIT_FAILURE;
+      return 0;
     }
   code = info.SetAppFlags (B_EXCLUSIVE_LAUNCH | B_ARGV_ONLY);
   if (code != B_OK)
     {
       be_perror (code, argv[2]);
-      return EXIT_FAILURE;
+      return 0;
     }
 
   icon = BTranslationUtils::GetBitmapFile (argv[1], NULL);