Java Code Examples for com.android.SdkConstants#FN_AIDL
The following examples show how to use
com.android.SdkConstants#FN_AIDL .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: LocalSdk.java From java-n-IDE-for-Android with Apache License 2.0 | 6 votes |
@NonNull private BuildToolInfo createLegacyBuildTools(@NonNull LocalPlatformToolPkgInfo ptInfo) { File platformTools = new File(getLocation(), SdkConstants.FD_PLATFORM_TOOLS); File platformToolsLib = ptInfo.getLocalDir(); File platformToolsRs = new File(platformTools, SdkConstants.FN_FRAMEWORK_RENDERSCRIPT); return new BuildToolInfo( ptInfo.getDesc().getFullRevision(), platformTools, new File(platformTools, SdkConstants.FN_AAPT), new File(platformTools, SdkConstants.FN_AIDL), new File(platformTools, SdkConstants.FN_DX), new File(platformToolsLib, SdkConstants.FN_DX_JAR), new File(platformTools, SdkConstants.FN_RENDERSCRIPT), new File(platformToolsRs, SdkConstants.FN_FRAMEWORK_INCLUDE), new File(platformToolsRs, SdkConstants.FN_FRAMEWORK_INCLUDE_CLANG), null, null, null, null, new File(platformTools, SdkConstants.FN_ZIPALIGN)); }
Example 2
Source File: LocalSdk.java From javaide with GNU General Public License v3.0 | 6 votes |
@NonNull private BuildToolInfo createLegacyBuildTools(@NonNull LocalPlatformToolPkgInfo ptInfo) { File platformTools = new File(getLocation(), SdkConstants.FD_PLATFORM_TOOLS); File platformToolsLib = ptInfo.getLocalDir(); return new BuildToolInfo( ptInfo.getDesc().getFullRevision(), platformTools, new File(platformTools, SdkConstants.FN_AAPT), new File(platformTools, SdkConstants.FN_AIDL), new File(platformTools, SdkConstants.FN_DX), new File(platformToolsLib, SdkConstants.FN_DX_JAR), null, null, null, null, new File(platformTools, SdkConstants.FN_ZIPALIGN)); }
Example 3
Source File: PlatformToolPackage.java From java-n-IDE-for-Android with Apache License 2.0 | 4 votes |
/** * Manually create a new package with one archive and the given attributes or properties. * This is used to create packages from local directories in which case there must be * one archive which URL is the actual target location. * <p/> * By design, this creates a package with one and only one archive. */ public static Package create( SdkSource source, Properties props, int revision, String license, String description, String descUrl, String archiveOsPath) { PlatformToolPackage ptp = new PlatformToolPackage(source, props, revision, license, description, descUrl, archiveOsPath); File platformToolsFolder = new File(archiveOsPath); String error = null; if (!platformToolsFolder.isDirectory()) { error = "platform-tools folder is missing"; } else { File[] files = platformToolsFolder.listFiles(); if (files == null || files.length == 0) { error = "platform-tools folder is empty"; } else { Set<String> names = new HashSet<String>(); for (File file : files) { names.add(file.getName()); } // Package-tools revision 17+ matches sdk-repository-8 and above // and only requires adb (other tools moved to the build-tool packages.) String[] expected = new String[] { SdkConstants.FN_ADB }; if (ptp.getRevision().getMajor() < 17) { // Platform-tools before revision 17 should have adb, aapt, aidl and dx. expected = new String[] { SdkConstants.FN_ADB, SdkConstants.FN_AAPT, SdkConstants.FN_AIDL, SdkConstants.FN_DX }; } for (String name : expected) { if (!names.contains(name)) { if (error == null) { error = "platform-tools folder is missing "; } else { error += ", "; } error += name; } } } } if (error != null) { String shortDesc = ptp.getShortDescription() + " [*]"; //$NON-NLS-1$ String longDesc = String.format( "Broken Platform-Tools Package: %1$s\n" + "[*] Package cannot be used due to error: %2$s", description, error); BrokenPackage ba = new BrokenPackage(props, shortDesc, longDesc, IMinApiLevelDependency.MIN_API_LEVEL_NOT_SPECIFIED, IExactApiLevelDependency.API_LEVEL_INVALID, archiveOsPath, PkgDesc.Builder.newPlatformTool(ptp.getRevision()) .setDescriptionShort(shortDesc) .create()); return ba; } return ptp; }