Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 18 Dec 2015 01:44:03 +0000 (UTC)
From:      Ed Maste <emaste@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org
Subject:   svn commit: r292421 - stable/10/usr.sbin/crunch/crunchide
Message-ID:  <201512180144.tBI1i3ev082396@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: emaste
Date: Fri Dec 18 01:44:03 2015
New Revision: 292421
URL: https://svnweb.freebsd.org/changeset/base/292421

Log:
  Sync crunchide(1) arch support with HEAD
  
  MFC r276764, r281781, r282291, r292106
  
  Add support to crunchide for handling AArch64 (arm64) ELF files.
  Remove local EM_* ELF definitions provided by system ELF headers
  Restore local EM_AARCH64 constant for bootstrapping
  Add RISC-V to supported machine types
  
  Sponsored by:	The FreeBSD Foundation

Modified:
  stable/10/usr.sbin/crunch/crunchide/exec_elf32.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/usr.sbin/crunch/crunchide/exec_elf32.c
==============================================================================
--- stable/10/usr.sbin/crunch/crunchide/exec_elf32.c	Fri Dec 18 01:32:43 2015	(r292420)
+++ stable/10/usr.sbin/crunch/crunchide/exec_elf32.c	Fri Dec 18 01:44:03 2015	(r292421)
@@ -175,37 +175,20 @@ ELFNAMEEND(check)(int fd, const char *fn
 	switch (xe16toh(eh.e_machine)) {
 	case EM_386: break;
 	case EM_ALPHA: break;
-#ifndef EM_ARM
-#define EM_ARM		40
+#ifndef EM_AARCH64
+#define	EM_AARCH64	183
 #endif
+	case EM_AARCH64: break;
 	case EM_ARM: break;
-#ifndef EM_MIPS
-#define EM_MIPS		8
-#endif
-#ifndef EM_MIPS_RS4_BE		/* same as EM_MIPS_RS3_LE */
-#define EM_MIPS_RS4_BE	10
-#endif
 	case EM_MIPS: break;
 	case /* EM_MIPS_RS3_LE */ EM_MIPS_RS4_BE: break;
-#ifndef EM_IA_64
-#define	EM_IA_64	50
-#endif
-	case EM_IA_64: break;
-#ifndef EM_PPC
-#define	EM_PPC		20
-#endif
 	case EM_PPC: break;
-#ifndef EM_PPC64
-#define	EM_PPC64	21
-#endif
 	case EM_PPC64: break;
-#ifndef EM_SPARCV9
-#define	EM_SPARCV9	43
+#ifndef EM_RISCV
+#define	EM_RISCV	243
 #endif
+	case EM_RISCV: break;
 	case EM_SPARCV9: break;
-#ifndef EM_X86_64
-#define	EM_X86_64	62
-#endif
 	case EM_X86_64: break;
 /*        ELFDEFNNAME(MACHDEP_ID_CASES) */
 



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201512180144.tBI1i3ev082396>