Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/kern One more section type in the Mach-O format. Now /us...



details:   https://anonhg.NetBSD.org/src/rev/679fa09069a5
branches:  trunk
changeset: 553716:679fa09069a5
user:      manu <manu%NetBSD.org@localhost>
date:      Mon Oct 20 22:42:40 2003 +0000

description:
One more section type in the Mach-O format. Now /usr/X11R6/bin/quartz-wm links
and run (it aborts because the dock is not launched).

diffstat:

 sys/kern/exec_macho.c |  13 ++++++-------
 1 files changed, 6 insertions(+), 7 deletions(-)

diffs (41 lines):

diff -r 74ba634cd802 -r 679fa09069a5 sys/kern/exec_macho.c
--- a/sys/kern/exec_macho.c     Mon Oct 20 22:16:33 2003 +0000
+++ b/sys/kern/exec_macho.c     Mon Oct 20 22:42:40 2003 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: exec_macho.c,v 1.28 2003/10/19 07:52:22 manu Exp $     */
+/*     $NetBSD: exec_macho.c,v 1.29 2003/10/20 22:42:40 manu Exp $     */
 
 /*-
  * Copyright (c) 2001 The NetBSD Foundation, Inc.
@@ -37,7 +37,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: exec_macho.c,v 1.28 2003/10/19 07:52:22 manu Exp $");
+__KERNEL_RCSID(0, "$NetBSD: exec_macho.c,v 1.29 2003/10/20 22:42:40 manu Exp $");
 
 #include <sys/param.h>
 #include <sys/proc.h>
@@ -207,6 +207,7 @@
            strcmp(ls->segname, "__LOCK") != 0 &&
            strcmp(ls->segname, "__OBJC") != 0 &&
            strcmp(ls->segname, "__CGSERVER") != 0 &&
+           strcmp(ls->segname, "__IMAGE") != 0 &&
            strcmp(ls->segname, "__LINKEDIT") != 0) {
                DPRINTF(("Unknown exec_macho segment %s\n", ls->segname));
                return ENOEXEC;
@@ -218,11 +219,9 @@
                        emea->macho_hdr = 
                            (struct exec_macho_object_header *)addr;
                }
-               if (strcmp(ls->segname, "__DATA") == 0) {
-                       epp->ep_daddr = addr;
-                       epp->ep_dsize = round_page(ls->vmsize);
-               }
-               if ((strcmp(ls->segname, "__OBJC") == 0) ||
+               if ((strcmp(ls->segname, "__DATA") == 0) ||
+                   (strcmp(ls->segname, "__OBJC") == 0) ||
+                   (strcmp(ls->segname, "__IMAGE") == 0) ||
                    (strcmp(ls->segname, "__CGSERVER") == 0)) {
                        epp->ep_daddr = addr;
                        epp->ep_dsize = round_page(ls->vmsize);



Home | Main Index | Thread Index | Old Index