javadoc expects directories on the sourcepath, not jar files.
The original commit 88b607994a
in 2009 was already passing the jar files, and every revision
since then seems to have kept this habit through cargo cult.
This CL removes the superfluous jar file arguments from the
sourcepath argument to javadoc.
Test: Treehugger
Bug: 76436487
Change-Id: I44b4b8ba248ad4deafbb6462e6f7398f15bd2845
to make sure if the inputs contains specific file path when
doclava throws the missing file error.
Test: m out/target/common/docs/core-current-stubs-gen-timestamp
Bug: b/76397326
Change-Id: Ib319912ae85e80fd53e7520f2c89268bb4b91c43
Use zipsync instead of extract_srcjars.sh.
Also fixes an issue where unzipping a resource zip would
ignore anything that wasn't a *.java file.
Bug: 73885582
Test: m checkbuild
Change-Id: I1c25f65afa196614879071c8655866febebac185
When LOCAL_NO_STANDARD_LIBRARIES is set to true, droiddoc only omits
framework libraries from the required libs. This enables us to use
droiddoc even when frameworks/base is absent (i.e. master-art branch).
Test: m -j core.current.stubs
Test: build in master-art branch
Change-Id: Ia9f0b8bda84b006881b3e62e6573a7784ca56a8c
The module name of system_$(VER) prebuilt file is system_sdk_v$(VER).
But this is inconsistent with sdk_v$(LOCAL_SDK_VERSION) in prebuilts/sdk.
So, system_sdk_v$(VER) is changed to sdk_vsystem_$(VER) to use the same
naming policy.
Bug: 72031391
Test: build
Change-Id: I379c0f9aa0de7407489eeec2b07ee7727e81d69d
core_current is a pseudo SDK version which is a core Java API subset of
the Android API. It is expected to be mainly used for external Java
projects which are agnostic to Android; such as junit, guava, etc.
A module built with this SDK version can only link to java modules of
the same kind. It can't depend on modules built with LOCAL_SDK_VERSION
:= current or without LOCAL_SDK_VERSION.
Bug: 72206056
Test: m -j
Change-Id: I34a9696393aa6704fd6684a40ea5b05d3fb46b23
BUILD_DROIDDOC allows LOCAL_SRC_FILES to refer to sources in
$(LOCAL_PATH) and LOCAL_INTERMEDIATE_SOURCES to refer to sources
in $(TARGET_OUT_COMMON_INTERMEDIATES). The droiddoc rules that
use files generated in Soong were trying to abuse LOCAL_SRC_FILES
to point to files in $(OUT_DIR)/soong using ../.. to counter
$(LOCAL_PATH), but failed if $(OUT_DIR) was absolute. Add
LOCAL_GENERATED_SOURCES that can take a path relative to the
top of the source tree or an absolute path.
Bug: 70166718
Test: m OUT_DIR=/tmp/out docs
Change-Id: Iaf0d622a3405da0bf520f7312e11e75e9328062e
Merged-In: Iaf0d622a3405da0bf520f7312e11e75e9328062e
(cherry-picked from commit 4c44a94dab)
Fix the build error when TARGET_BUILD_APPS is set
Bug: 67724799
Test: m -j TARGET_PRODUCT=full TARGET_BUILD_APPS=TVTestInput
Merged-In: I981b0a245d7e8f2dabbd4e51db52d17aeacc6106
Change-Id: I981b0a245d7e8f2dabbd4e51db52d17aeacc6106
(cherry picked from commit 8e7a4c413f)
The system_$(VER) can be set in LOCAL_SDK_VERSION, and the apk will use
android_system.jar at build time.
If LOCAL_SDK_VERSION is not defined and this module is installed in
vendor.img, LOCAL_SDK_VERSION is set to system_current.
Bug: 67724799
Test: 1. build && run on taimen
2. LOCAL_SDK_VERSION:=system_27 in ims.apk && build ims.apk && check
the vsdk_v27_intermediates.
Merged-In: I5b11c78b8fcd4a2f2a5e3b141527cd34dbe80018
Change-Id: I5b11c78b8fcd4a2f2a5e3b141527cd34dbe80018
(cherry picked from commit ef212cbe8d)
This CL topic breaks the single flag value EXPERIMENTAL_USE_OPENJDK9
into two flags USE_OPENJDK9 and TARGET_OPENJDK9 which are computed
independently in config.mk and config.go; this means that later
build logic no longer depends on / duplicates the semantics of an
unset EXPERIMENTAL_USE_OPENJDK9, because that later build logic
can use USE_OPENJDK9 and TARGET_OPENJDK9 instead. Thus, it becomes
slightly easier to change this default in future CLs (touching
only config.mk and config.go).
It also makes it more straightforward to convert .mk files
to .bp.
This CL also introduces a new allowed value "false" for
EXPERIMENTAL_USE_OPENJDK9. This fourth possible value currently
has the same semantics as a default/unset
EXPERIMENTAL_USE_OPENJDK9, but allows people to explicitly
switch back to the old semantics when the default changes.
Test: make showcommands core-oj (in environments with
EXPERIMENTAL_USE_OPENJDK9 set to "", "1.8", and "true").
Bug: 38177295
Change-Id: Iaade9610b237722e5d175143808b8653b1e98996
Soong generates the R.java for framework-res.apk to a srcjar.
Droiddoc will need to consume them, so add support to the droiddoc
rules for extracting sources from a srcjar.
Test: m checkbuild
Change-Id: I064889c9063b642835d9f668e2568b61d0fabe35
1. Use merge_zips to merge jars without unzipping/rezipping static Java
libraries. And seperate merging process as a independent Make target so
that Javac can only depend on Turbine.
2. Remove duplicate vars: "full_java_lib_deps" in droiddoc.mk
3. Also use classes-header.jar for link_apk & link_instr
Bug: b/65455145
Test: m clean && m -j32
Change-Id: I7b0307664a6b86075c983284fce099bd3946318c
full_java_lib_deps has trailing whitespace if $(LOCAL_CLASSPATH)
is empty. Because the calculation of PRIVATE_CLASSPATH was
missing a $(strip ...), this resulted in an (unintentional)
trailing ':' in the values of the -classpath and -sourcepath
arguments to the javadoc tool, which that tool is documented
to interpret as '.' (the working directory).
This CL converts the expression to a call to normalize-path-list,
from definitions.mk, which contains the $(strip ...):
define normalize-path-list
$(subst $(space),:,$(strip $(1)))
endef
After this CL, an empty $(LOCAL_CLASSPATH) no longer gets
misinterpreted as the current working directory.
This issue was minor (it made no difference in practice).
Test: Treehugger
Bug: 62049770
Change-Id: Ia0e3e5657d0fa057fe998515f34bc7b8df5f6f16
OpenJDK 9's javadoc tool doesn't support the -bootclasspath
command line option, even with -source 1.8.
Instead, under OpenJDK 9, javadoc needs to be passed a
--patch-module argument to tell it the location of the
classes patching packages from java.* modules.
The source files in libcore/{dalvik,libart,luni,ojluni} and
external/icu/android_icu4j that go into PRIVATE_BOOTCLASSPATH
patch packages from the modules java.base, java.desktop,
java.logging, java.prefs, java.sql, jdk.net, and
jdk.unsupported. However, this CL takes the simpler approach
of placing them all in java.base, which appears to work for
the purposes of the javadoc run.
Test: Ran the following both on OpenJDK 8 toolchain and on
OpenJDK 9 (with EXPERIMENTAL_USE_OPENJDK9=true):
rm -rf out/target/common/docs/ && make docs
Test: Compared (via meld) the contents of out/target/common/docs
for the two toolchains (there were some differences, see bug).
Bug: 62049770
Change-Id: If3dd927477ca32dab7ffb528350de872e1017184
Replace java -> $(JAVA), etc. to prepare for moving java binaries
out of the path and using full paths to them.
Test: builds
Bug: 62956999
Change-Id: I5dfcd0d4e855ecde69cd127169e9545e59723d12
Some of our minimal branches don't have the necessary droiddoc
templates, so don't cause a FindEmulator warning when the template dir
is missing and ALLOW_MISSING_DEPENDENCIES is set. The warnings will soon
be errors.
When the template directory is missing, ensure that the command doesn't
succeed by adding the directory into the dependency list. Passing a
missing directory doesn't cause an error otherwise, it just wouldn't use
the template.
Test: build-aosp_arm64.ninja is identical before and after this change
Test: Move away build/tools/droiddoc/templates-sdk; m -j libcore-docs
Change-Id: I122f3916b6ab348a5a98dcf2520992eda3655e26
This flag allowed for building with an OpenJDK 7 toolchain. It was
used for build bot builds that now work with an OpenJDK 8 toolchain.
Hence, this feature is no longer required. This CL drops it.
Bug: 27583810
Test: Treehugger build succeeds.
Change-Id: I7efca363d665292bfb88f4a4d6f3a120fc8f93f3
This CL resubmits a fixed version of commit
e2a8da2683.
This CL applies the following changes:
- explicitly set the path where desugar will dump temporary class files.
This ensures that the system property is set before it is read during
InnerClassLambdaMetafactory.<clinit>. Before this CL, the system
property was set by Desugar.createAndRegisterLambdaDumpDirectory(),
which may run too late.
- explicitly specify -source 1.8 for droiddoc's javadoc run.
Previously, the command used the language version of the build
toolchain, which might fail due the backward-incompatible restrictions
imposed by the proposed module system.
Some Android build targets use LOCAL_JAVA_LANGUAGE_VERSION 1.7,
but droiddoc combines sources from multiple build targets and there
where no backwards incompatible changes in 1.8, so it should be fine
to use 1.8 for code from either language level.
Bug: 38318052
Bug: 38225656
Bug: 38177295
Test: make clean && make ANDROID_COMPILE_WITH_JACK=false checkbuild tests \
&& make checkbuild tests
(using OpenJDK 8 toolchain)
Change-Id: I2fffe6668747f48be44e34c67332af9b8a996d2a
- explicitly set the path where desugar will dump temporary class files.
This ensures that the system property is set before it is read during
InnerClassLambdaMetafactory.<clinit>. Before this CL, the system
property was set by Desugar.createAndRegisterLambdaDumpDirectory(),
which may run too late.
- explicitly specify -source 1.8 for droiddoc's javadoc run.
Previously, the command used the language version of the build
toolchain, which might fail due the backward-incompatible restrictions
imposed by the proposed module system.
Some Android build targets use LOCAL_JAVA_LANGUAGE_VERSION 1.7,
but droiddoc combines sources from multiple build targets and there
where no backwards incompatible changes in 1.8, so it should be fine
to use 1.8 for code from either language level.
Bug: 38318052
Bug: 38225656
Bug: 38177295
Test: make clean && make checkbuild docs
(using OpenJDK 8 toolchain)
Change-Id: Ie5fe0502dfe2f99fc58b1a723b7c18d5896a2646
This flag enables stack traces when invoking doclava, which were
otherwise being truncated to simply be the exception name, which was
useless for debugging things.
Test: make -j32 online-system-api-sdk-docs
Bug: 38164929
Change-Id: Ie281e2b2ed988bb6d587af33256fcdee1450fc79
Creates a build_system_stats.txt build artifact that contains statistics
on how many BUILD_* modules are defined in a build. Also writes out
information about the Soong module types sent from the Soong build.
Merged-In: Iaf0c7062f542dc6942b5349854f3d49267cac4a5
Change-Id: Iaf0c7062f542dc6942b5349854f3d49267cac4a5
Creates a build_system_stats.txt build artifact that contains statistics
on how many BUILD_* modules are defined in a build. Also writes out
information about the Soong module types sent from the Soong build.
Change-Id: Iaf0c7062f542dc6942b5349854f3d49267cac4a5
And everything special-cased on that. Add a warning if USE_NINJA is
set to let users know that it no longer changes anything.
Change-Id: Ib8739151fe26ea6bf8f76b7ac2b8f4097dab0b47
Temporary revert to help out Brillo folks.
It will be resubmitted tomorrow.
This reverts commit 4495f6afb8.
Change-Id: Id378c7d3a6e72e9be50f9404b19d5763568987a5
To return to OpenJDK 7:
export LEGACY_USE_JAVA7=true
And run envsetup.sh/lunch again.
Bug: 25786468
Change-Id: I8e00591a24d13e3b8b6baaafe0fdff6536c58770
This reverts commit c288d65762.
The launch control change that switched various builds
to JDK 8 was reverted so JDK 8 can't be mandatory without
breaking builds.
Change-Id: I5e3feb21488d3bb57c5718cfe105a931eeaa9587
Reverting until all continuous builds that cover branches downstream of master can be updated to use JDK 8.
This reverts commit 1bd16b67c4.
Change-Id: Icb0daa440a6286e07d3cfd9ff8b082b4154ebc21
To return to OpenJDK 7:
export LEGACY_USE_JAVA7=true
And run envsetup.sh/lunch again.
Bug: 25786468
Change-Id: Iba08a9d3cf73bae7124e431dfe87c20ac219591e
With some core classes moved to separate core-oj jar
we need to use the new jar.
(cherry picked from commit 89b94c827f)
Change-Id: I025c0adc70535bf23def3ab0ce28a1bfaef72514
Mac builds use a javadoc tool that fails on more warnings than linux
builds. Add -Xdoclint:none to all java 8 standard doclet javadoc
commands.
Don't add it to javadoc commands that use the com.google.doclava.Doclava
doclet, it doesn't understand -Xdoclint:none.
(cherry-picked from commit 8bf7b5d51a)
Change-Id: Ic5b8431ec2facb7989473b06ebe07246f6d2317f