Bug 572799 - Replace arm64 with aarch64

Replace occurrences of arm64 with aarch64 in fragment and arch name.

build.sh changes:
Use -arch arm64 for building as aarch64 gives invalid arch name error,
set DEFAULT_OS_ARCH to aarch64

Change-Id: Ie724754dba974e157031682cac25f9f2c833b286
Reviewed-on: https://git.eclipse.org/r/c/equinox/rt.equinox.framework/+/179845
Tested-by: Thomas Watson <tjwatson@us.ibm.com>
Reviewed-by: Thomas Watson <tjwatson@us.ibm.com>
diff --git a/bundles/org.eclipse.equinox.launcher.cocoa.macosx.arm64/.project b/bundles/org.eclipse.equinox.launcher.cocoa.macosx.aarch64/.project
similarity index 87%
rename from bundles/org.eclipse.equinox.launcher.cocoa.macosx.arm64/.project
rename to bundles/org.eclipse.equinox.launcher.cocoa.macosx.aarch64/.project
index 5efe02e..3adb290 100644
--- a/bundles/org.eclipse.equinox.launcher.cocoa.macosx.arm64/.project
+++ b/bundles/org.eclipse.equinox.launcher.cocoa.macosx.aarch64/.project
@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <projectDescription>
-	<name>org.eclipse.equinox.launcher.cocoa.macosx.arm64</name>
+	<name>org.eclipse.equinox.launcher.cocoa.macosx.aarch64</name>
 	<comment></comment>
 	<projects>
 	</projects>
diff --git a/bundles/org.eclipse.equinox.launcher.cocoa.macosx.arm64/META-INF/MANIFEST.MF b/bundles/org.eclipse.equinox.launcher.cocoa.macosx.aarch64/META-INF/MANIFEST.MF
similarity index 79%
rename from bundles/org.eclipse.equinox.launcher.cocoa.macosx.arm64/META-INF/MANIFEST.MF
rename to bundles/org.eclipse.equinox.launcher.cocoa.macosx.aarch64/META-INF/MANIFEST.MF
index 0f1ab59..9507c59 100644
--- a/bundles/org.eclipse.equinox.launcher.cocoa.macosx.arm64/META-INF/MANIFEST.MF
+++ b/bundles/org.eclipse.equinox.launcher.cocoa.macosx.aarch64/META-INF/MANIFEST.MF
@@ -2,9 +2,9 @@
 Bundle-ManifestVersion: 2
 Bundle-Name: %pluginName
 Bundle-Vendor: %providerName
-Bundle-SymbolicName: org.eclipse.equinox.launcher.cocoa.macosx.arm64;singleton:=true
+Bundle-SymbolicName: org.eclipse.equinox.launcher.cocoa.macosx.aarch64;singleton:=true
 Bundle-Version: 1.2.200.qualifier
 Fragment-Host: org.eclipse.equinox.launcher;bundle-version="[1.5.0,1.7.0)"
-Eclipse-PlatformFilter: (& (osgi.ws=cocoa) (osgi.os=macosx) (osgi.arch=arm64) )
-Bundle-Localization: launcher.cocoa.macosx.arm64
+Eclipse-PlatformFilter: (& (osgi.ws=cocoa) (osgi.os=macosx) (osgi.arch=aarch64) )
+Bundle-Localization: launcher.cocoa.macosx.aarch64
 Eclipse-BundleShape: dir
diff --git a/bundles/org.eclipse.equinox.launcher.cocoa.macosx.arm64/about.html b/bundles/org.eclipse.equinox.launcher.cocoa.macosx.aarch64/about.html
similarity index 100%
rename from bundles/org.eclipse.equinox.launcher.cocoa.macosx.arm64/about.html
rename to bundles/org.eclipse.equinox.launcher.cocoa.macosx.aarch64/about.html
diff --git a/bundles/org.eclipse.equinox.launcher.cocoa.macosx.arm64/build.properties b/bundles/org.eclipse.equinox.launcher.cocoa.macosx.aarch64/build.properties
similarity index 92%
rename from bundles/org.eclipse.equinox.launcher.cocoa.macosx.arm64/build.properties
rename to bundles/org.eclipse.equinox.launcher.cocoa.macosx.aarch64/build.properties
index ab3f656..27c538b 100644
--- a/bundles/org.eclipse.equinox.launcher.cocoa.macosx.arm64/build.properties
+++ b/bundles/org.eclipse.equinox.launcher.cocoa.macosx.aarch64/build.properties
@@ -12,7 +12,7 @@
 #     IBM Corporation - initial API and implementation
 ###############################################################################
 bin.includes = META-INF/,\
-               launcher.cocoa.macosx.arm64.properties,\
+               launcher.cocoa.macosx.aarch64.properties,\
                about.html
                
 customBuildCallbacks=customBuildCallbacks.xml
diff --git a/bundles/org.eclipse.equinox.launcher.cocoa.macosx.arm64/customBuildCallbacks.xml b/bundles/org.eclipse.equinox.launcher.cocoa.macosx.aarch64/customBuildCallbacks.xml
similarity index 100%
rename from bundles/org.eclipse.equinox.launcher.cocoa.macosx.arm64/customBuildCallbacks.xml
rename to bundles/org.eclipse.equinox.launcher.cocoa.macosx.aarch64/customBuildCallbacks.xml
diff --git a/bundles/org.eclipse.equinox.launcher.cocoa.macosx.arm64/forceQualifierUpdate.txt b/bundles/org.eclipse.equinox.launcher.cocoa.macosx.aarch64/forceQualifierUpdate.txt
similarity index 100%
rename from bundles/org.eclipse.equinox.launcher.cocoa.macosx.arm64/forceQualifierUpdate.txt
rename to bundles/org.eclipse.equinox.launcher.cocoa.macosx.aarch64/forceQualifierUpdate.txt
diff --git a/bundles/org.eclipse.equinox.launcher.cocoa.macosx.arm64/launcher.cocoa.macosx.arm64.properties b/bundles/org.eclipse.equinox.launcher.cocoa.macosx.aarch64/launcher.cocoa.macosx.aarch64.properties
similarity index 89%
rename from bundles/org.eclipse.equinox.launcher.cocoa.macosx.arm64/launcher.cocoa.macosx.arm64.properties
rename to bundles/org.eclipse.equinox.launcher.cocoa.macosx.aarch64/launcher.cocoa.macosx.aarch64.properties
index 8db0544..c13c830 100644
--- a/bundles/org.eclipse.equinox.launcher.cocoa.macosx.arm64/launcher.cocoa.macosx.arm64.properties
+++ b/bundles/org.eclipse.equinox.launcher.cocoa.macosx.aarch64/launcher.cocoa.macosx.aarch64.properties
@@ -11,5 +11,5 @@
 # Contributors:
 #     IBM Corporation - initial API and implementation
 ###############################################################################
-pluginName = Equinox Launcher MacOSX Cocoa ARM64 Fragment
+pluginName = Equinox Launcher MacOSX Cocoa AARCH64/ARM64 Fragment
 providerName = Eclipse.org - Equinox
diff --git a/bundles/org.eclipse.equinox.launcher.cocoa.macosx.arm64/pom.xml b/bundles/org.eclipse.equinox.launcher.cocoa.macosx.aarch64/pom.xml
similarity index 91%
rename from bundles/org.eclipse.equinox.launcher.cocoa.macosx.arm64/pom.xml
rename to bundles/org.eclipse.equinox.launcher.cocoa.macosx.aarch64/pom.xml
index 4475212..f014d73 100644
--- a/bundles/org.eclipse.equinox.launcher.cocoa.macosx.arm64/pom.xml
+++ b/bundles/org.eclipse.equinox.launcher.cocoa.macosx.aarch64/pom.xml
@@ -18,14 +18,14 @@
     <relativePath>../../launcher-binary-parent</relativePath>
   </parent>
   <groupId>org.eclipse.equinox</groupId>
-  <artifactId>org.eclipse.equinox.launcher.cocoa.macosx.arm64</artifactId>
+  <artifactId>org.eclipse.equinox.launcher.cocoa.macosx.aarch64</artifactId>
   <version>1.2.200-SNAPSHOT</version>
   <packaging>eclipse-plugin</packaging>
 
   <properties>
     <os>macosx</os>
     <ws>cocoa</ws>
-    <arch>arm64</arch>
+    <arch>aarch64</arch>
     <skipAPIAnalysis>true</skipAPIAnalysis>
   </properties>
 
diff --git a/bundles/org.eclipse.equinox.launcher.cocoa.macosx/.project b/bundles/org.eclipse.equinox.launcher.cocoa.macosx/.project
index 5efe02e..3adb290 100644
--- a/bundles/org.eclipse.equinox.launcher.cocoa.macosx/.project
+++ b/bundles/org.eclipse.equinox.launcher.cocoa.macosx/.project
@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <projectDescription>
-	<name>org.eclipse.equinox.launcher.cocoa.macosx.arm64</name>
+	<name>org.eclipse.equinox.launcher.cocoa.macosx.aarch64</name>
 	<comment></comment>
 	<projects>
 	</projects>
diff --git a/bundles/org.eclipse.equinox.launcher.cocoa.macosx/META-INF/MANIFEST.MF b/bundles/org.eclipse.equinox.launcher.cocoa.macosx/META-INF/MANIFEST.MF
index 6b44c85..d5c7fa0 100644
--- a/bundles/org.eclipse.equinox.launcher.cocoa.macosx/META-INF/MANIFEST.MF
+++ b/bundles/org.eclipse.equinox.launcher.cocoa.macosx/META-INF/MANIFEST.MF
@@ -5,6 +5,6 @@
 Bundle-SymbolicName: org.eclipse.equinox.launcher.cocoa.macosx;singleton:=true
 Bundle-Version: 1.2.200.qualifier
 Fragment-Host: org.eclipse.equinox.launcher;bundle-version="[1.5.0,1.7.0)"
-Eclipse-PlatformFilter: (& (osgi.ws=cocoa) (osgi.os=macosx) (osgi.arch=arm64) )
-Bundle-Localization: launcher.cocoa.macosx.arm64
+Eclipse-PlatformFilter: (& (osgi.ws=cocoa) (osgi.os=macosx) (osgi.arch=aarch64) )
+Bundle-Localization: launcher.cocoa.macosx.aarch64
 Eclipse-BundleShape: dir
diff --git a/bundles/org.eclipse.equinox.launcher.cocoa.macosx/build.properties b/bundles/org.eclipse.equinox.launcher.cocoa.macosx/build.properties
index ab3f656..27c538b 100644
--- a/bundles/org.eclipse.equinox.launcher.cocoa.macosx/build.properties
+++ b/bundles/org.eclipse.equinox.launcher.cocoa.macosx/build.properties
@@ -12,7 +12,7 @@
 #     IBM Corporation - initial API and implementation
 ###############################################################################
 bin.includes = META-INF/,\
-               launcher.cocoa.macosx.arm64.properties,\
+               launcher.cocoa.macosx.aarch64.properties,\
                about.html
                
 customBuildCallbacks=customBuildCallbacks.xml
diff --git a/bundles/org.eclipse.equinox.launcher.cocoa.macosx.arm64/launcher.cocoa.macosx.arm64.properties b/bundles/org.eclipse.equinox.launcher.cocoa.macosx/launcher.cocoa.macosx.aarch64.properties
similarity index 89%
copy from bundles/org.eclipse.equinox.launcher.cocoa.macosx.arm64/launcher.cocoa.macosx.arm64.properties
copy to bundles/org.eclipse.equinox.launcher.cocoa.macosx/launcher.cocoa.macosx.aarch64.properties
index 8db0544..c13c830 100644
--- a/bundles/org.eclipse.equinox.launcher.cocoa.macosx.arm64/launcher.cocoa.macosx.arm64.properties
+++ b/bundles/org.eclipse.equinox.launcher.cocoa.macosx/launcher.cocoa.macosx.aarch64.properties
@@ -11,5 +11,5 @@
 # Contributors:
 #     IBM Corporation - initial API and implementation
 ###############################################################################
-pluginName = Equinox Launcher MacOSX Cocoa ARM64 Fragment
+pluginName = Equinox Launcher MacOSX Cocoa AARCH64/ARM64 Fragment
 providerName = Eclipse.org - Equinox
diff --git a/bundles/org.eclipse.equinox.launcher.cocoa.macosx/launcher.cocoa.macosx.arm64.properties b/bundles/org.eclipse.equinox.launcher.cocoa.macosx/launcher.cocoa.macosx.arm64.properties
deleted file mode 100644
index 8db0544..0000000
--- a/bundles/org.eclipse.equinox.launcher.cocoa.macosx/launcher.cocoa.macosx.arm64.properties
+++ /dev/null
@@ -1,15 +0,0 @@
-###############################################################################
-# Copyright (c) 2008, 2009 IBM Corporation and others.
-#
-# This program and the accompanying materials
-# are made available under the terms of the Eclipse Public License 2.0
-# which accompanies this distribution, and is available at
-# https://www.eclipse.org/legal/epl-2.0/
-#
-# SPDX-License-Identifier: EPL-2.0
-# 
-# Contributors:
-#     IBM Corporation - initial API and implementation
-###############################################################################
-pluginName = Equinox Launcher MacOSX Cocoa ARM64 Fragment
-providerName = Eclipse.org - Equinox
diff --git a/bundles/org.eclipse.equinox.launcher.cocoa.macosx/pom.xml b/bundles/org.eclipse.equinox.launcher.cocoa.macosx/pom.xml
index 27e7b82..91cfc8e 100644
--- a/bundles/org.eclipse.equinox.launcher.cocoa.macosx/pom.xml
+++ b/bundles/org.eclipse.equinox.launcher.cocoa.macosx/pom.xml
@@ -25,7 +25,7 @@
   <properties>
     <os>macosx</os>
     <ws>cocoa</ws>
-    <arch>arm64</arch>
+    <arch>aarch64</arch>
     <skipAPIAnalysis>true</skipAPIAnalysis>
   </properties>
 
diff --git a/features/org.eclipse.equinox.executable.feature/bin/cocoa/macosx/arm64/Eclipse.app/Contents/Info.plist b/features/org.eclipse.equinox.executable.feature/bin/cocoa/macosx/aarch64/Eclipse.app/Contents/Info.plist
similarity index 100%
rename from features/org.eclipse.equinox.executable.feature/bin/cocoa/macosx/arm64/Eclipse.app/Contents/Info.plist
rename to features/org.eclipse.equinox.executable.feature/bin/cocoa/macosx/aarch64/Eclipse.app/Contents/Info.plist
diff --git a/features/org.eclipse.equinox.executable.feature/build.properties b/features/org.eclipse.equinox.executable.feature/build.properties
index cee6117..2ab3c26 100644
--- a/features/org.eclipse.equinox.executable.feature/build.properties
+++ b/features/org.eclipse.equinox.executable.feature/build.properties
@@ -33,8 +33,8 @@
 root.macosx.cocoa.x86_64=bin/cocoa/macosx/x86_64
 root.macosx.cocoa.x86_64.permissions.755=Eclipse.app/Contents/MacOS/launcher
 
-root.macosx.cocoa.arm64=bin/cocoa/macosx/arm64
-root.macosx.cocoa.arm64.permissions.755=Eclipse.app/Contents/MacOS/launcher
+root.macosx.cocoa.aarch64=bin/cocoa/macosx/aarch64
+root.macosx.cocoa.aarch64.permissions.755=Eclipse.app/Contents/MacOS/launcher
 
 root.linux.gtk.x86_64=bin/gtk/linux/x86_64,gtk_root
 root.linux.gtk.x86_64.permissions.755=libcairo-swt.so
diff --git a/features/org.eclipse.equinox.executable.feature/feature.xml b/features/org.eclipse.equinox.executable.feature/feature.xml
index 3d4b3ec..d331854 100755
--- a/features/org.eclipse.equinox.executable.feature/feature.xml
+++ b/features/org.eclipse.equinox.executable.feature/feature.xml
@@ -33,10 +33,10 @@
          fragment="true"/>
 
    <plugin
-         id="org.eclipse.equinox.launcher.cocoa.macosx.arm64"
+         id="org.eclipse.equinox.launcher.cocoa.macosx.aarch64"
          os="macosx"
          ws="cocoa"
-         arch="arm64"
+         arch="aarch64"
          download-size="0"
          install-size="0"
          version="0.0.0"
@@ -46,7 +46,7 @@
          id="org.eclipse.equinox.launcher.cocoa.macosx"
          os="macosx"
          ws="cocoa"
-         arch="arm64"
+         arch="aarch64"
          download-size="0"
          install-size="0"
          version="0.0.0"
diff --git a/features/org.eclipse.equinox.executable.feature/library/cocoa/build.sh b/features/org.eclipse.equinox.executable.feature/library/cocoa/build.sh
index f049eec..cba8a60 100755
--- a/features/org.eclipse.equinox.executable.feature/library/cocoa/build.sh
+++ b/features/org.eclipse.equinox.executable.feature/library/cocoa/build.sh
@@ -60,18 +60,21 @@
 # Set up environment variables needed by the makefiles.
 PROGRAM_OUTPUT="$programOutput"
 DEFAULT_OS="$defaultOS"
-DEFAULT_OS_ARCH="$defaultOSArch"
 DEFAULT_WS="$defaultWS"
 DEPLOYMENT_TARGET=10.10
 EXEC_DIR=../../../../../rt.equinox.binaries/org.eclipse.equinox.executable
-PROGRAM_OUTPUT_DIR="$EXEC_DIR/bin/$defaultWS/$defaultOS/$defaultOSArch/Eclipse.app/Contents/MacOS"
-if [ "$defaultOSArch" == "arm64" ]
+if [ "$defaultOSArch" == "arm64" ] || [ "$defaultOSArch" == "aarch64" ]
 then
   SDKROOT_PATH="/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk"
+  DEFAULT_OS_ARCH="aarch64"
+  defaultOSArch="arm64"
 else
   SDKROOT_PATH="/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk"
+  DEFAULT_OS_ARCH="$defaultOSArch"
 fi
 
+PROGRAM_OUTPUT_DIR="$EXEC_DIR/bin/$defaultWS/$defaultOS/$DEFAULT_OS_ARCH/Eclipse.app/Contents/MacOS"
+
 # /System/Library/Frameworks/JavaVM.framework/Headers does not exist anymore on Yosemite
 if [ -e /System/Library/Frameworks/JavaVM.framework/Headers ]; then
   JAVA_HEADERS="-I/System/Library/Frameworks/JavaVM.framework/Headers"
diff --git a/features/org.eclipse.equinox.executable.feature/pom.xml b/features/org.eclipse.equinox.executable.feature/pom.xml
index e416275..e12604d 100644
--- a/features/org.eclipse.equinox.executable.feature/pom.xml
+++ b/features/org.eclipse.equinox.executable.feature/pom.xml
@@ -123,7 +123,7 @@
                     <copy todir="bin" verbose="true" includeEmptyDirs="false" failonerror="true">
                       <fileset dir="${rt.equinox.binaries.loc}/org.eclipse.equinox.executable/bin/">
                         <include name="cocoa/macosx/x86_64/**/*"/>
-                        <include name="cocoa/macosx/arm64/**/*"/>
+                        <include name="cocoa/macosx/aarch64/**/*"/>
                         <include name="gtk/linux/ppc64le/**/*"/>
                         <include name="gtk/linux/aarch64/**/*"/>
                         <include name="gtk/linux/x86_64/**/*"/>
diff --git a/features/org.eclipse.equinox.executable.feature/resources/build.properties b/features/org.eclipse.equinox.executable.feature/resources/build.properties
index aa8ac04..44f1fcc 100644
--- a/features/org.eclipse.equinox.executable.feature/resources/build.properties
+++ b/features/org.eclipse.equinox.executable.feature/resources/build.properties
@@ -26,8 +26,8 @@
 root.macosx.cocoa.x86_64=bin/cocoa/macosx/x86_64
 root.macosx.cocoa.x86_64.permissions.755=Contents/MacOS/${launcherName}
 
-root.macosx.cocoa.arm64=bin/cocoa/macosx/arm64
-root.macosx.cocoa.arm64.permissions.755=Contents/MacOS/${launcherName}
+root.macosx.cocoa.aarch64=bin/cocoa/macosx/aarch64
+root.macosx.cocoa.aarch64.permissions.755=Contents/MacOS/${launcherName}
 
 root.linux.gtk.x86_64=bin/gtk/linux/x86_64,gtk_root
 root.linux.gtk.x86_64.permissions.755=libcairo-swt.so
diff --git a/features/org.eclipse.equinox.executable.feature/resources/build.xml b/features/org.eclipse.equinox.executable.feature/resources/build.xml
index 5c7055d..fa0a16c 100644
--- a/features/org.eclipse.equinox.executable.feature/resources/build.xml
+++ b/features/org.eclipse.equinox.executable.feature/resources/build.xml
@@ -76,13 +76,13 @@
 		<chmod perm="755" dir="${feature.base}/macosx.cocoa.x86_64/${collectingFolder}" includes="${launcherName}" />
 		<chmod perm="755" dir="${feature.base}/macosx.cocoa.x86_64/${collectingFolder}" includes="Eclipse.app/Contents/MacOS/launcher" />
 	</target>
-	<target name="rootFilesmacosx_cocoa_arm64">
-		<mkdir dir="${feature.base}/macosx.cocoa.arm64/${collectingFolder}"/>
-		<copy todir="${feature.base}/macosx.cocoa.arm64/${collectingFolder}" failonerror="true" overwrite="true">
-			<fileset dir="${basedir}/bin/cocoa/macosx/arm64" includes="**"			/>
+	<target name="rootFilesmacosx_cocoa_aarch64">
+		<mkdir dir="${feature.base}/macosx.cocoa.aarch64/${collectingFolder}"/>
+		<copy todir="${feature.base}/macosx.cocoa.aarch64/${collectingFolder}" failonerror="true" overwrite="true">
+			<fileset dir="${basedir}/bin/cocoa/macosx/aarch64" includes="**"			/>
 		</copy>
-		<chmod perm="755" dir="${feature.base}/macosx.cocoa.arm64/${collectingFolder}" includes="${launcherName}" />
-		<chmod perm="755" dir="${feature.base}/macosx.cocoa.arm64/${collectingFolder}" includes="Eclipse.app/Contents/MacOS/launcher" />
+		<chmod perm="755" dir="${feature.base}/macosx.cocoa.aarch64/${collectingFolder}" includes="${launcherName}" />
+		<chmod perm="755" dir="${feature.base}/macosx.cocoa.aarch64/${collectingFolder}" includes="Eclipse.app/Contents/MacOS/launcher" />
 	</target>
 	<target name="rootFileslinux_gtk_ppc64le">
 		<mkdir dir="${feature.base}/linux.gtk.ppc64le/${collectingFolder}"/>
diff --git a/pom.xml b/pom.xml
index 169feb8..1186d11 100644
--- a/pom.xml
+++ b/pom.xml
@@ -88,7 +88,7 @@
     <module>bundles/org.eclipse.equinox.launcher</module>
     <module>bundles/org.eclipse.equinox.launcher.cocoa.macosx</module>
     <module>bundles/org.eclipse.equinox.launcher.cocoa.macosx.x86_64</module>
-    <module>bundles/org.eclipse.equinox.launcher.cocoa.macosx.arm64</module>
+    <module>bundles/org.eclipse.equinox.launcher.cocoa.macosx.aarch64</module>
     <module>bundles/org.eclipse.equinox.launcher.gtk.linux.aarch64</module>
     <module>bundles/org.eclipse.equinox.launcher.gtk.linux.ppc64le</module>
     <module>bundles/org.eclipse.equinox.launcher.gtk.linux.x86_64</module>