Skip to content

Commit

Permalink
Add GWT dependencies for Jakarta Inject
Browse files Browse the repository at this point in the history
Issue #4391

RELNOTES=Add GWT dependencies for Jakarta Inject
PiperOrigin-RevId: 665040399
  • Loading branch information
Chang-Eric authored and Dagger Team committed Aug 19, 2024
1 parent c69189e commit bea926c
Show file tree
Hide file tree
Showing 4 changed files with 25 additions and 1 deletion.
1 change: 1 addition & 0 deletions gwt/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ java_library(
name = "manual_deps",
tags = [
"maven_coordinates=com.google.dagger:dagger:%s:jar:sources" % POM_VERSION,
"maven_coordinates=jakarta.inject:jakarta.inject-api:2.0.1:jar:sources",
"maven_coordinates=javax.inject:javax.inject:1:jar:sources",
],
visibility = ["//visibility:private"],
Expand Down
5 changes: 5 additions & 0 deletions gwt/dagger/Dagger.gwt.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,8 @@

<source path=""/>
</module>
<module>
<inherits name="jakarta.inject.Inject" />

<source path=""/>
</module>
18 changes: 18 additions & 0 deletions gwt/jakarta/inject/Inject.gwt.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
<!--
Copyright (C) 2024 The Dagger Authors.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<module>
<source path=""/>
</module>
2 changes: 1 addition & 1 deletion util/validate-artifacts.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ _validate_jar() {
# Validate the package prefixes of the files in the jar.
if [[ $artifact_id == "dagger-gwt" ]]; then
python $(dirname $0)/validate-jar-entry-prefixes.py \
$artifact_jar "dagger/,META-INF/,javax/inject/"
$artifact_jar "dagger/,META-INF/,javax/inject/,jakarta/inject/"
elif [[ $artifact_id == "hilt-android" ]]; then
python $(dirname $0)/validate-jar-entry-prefixes.py \
$artifact_jar "dagger/,META-INF/,hilt_aggregated_deps/"
Expand Down

0 comments on commit bea926c

Please sign in to comment.