]> source.dussan.org Git - vaadin-framework.git/commitdiff
chore: avoid repackaging of google elemental dep and use it directly (#12459)
authorAnna Koskinen <Ansku@users.noreply.github.com>
Fri, 29 Oct 2021 10:04:02 +0000 (13:04 +0300)
committerGitHub <noreply@github.com>
Fri, 29 Oct 2021 10:04:02 +0000 (13:04 +0300)
(#12416)

The google elemental dependency is not OSGi compatible so it's
repackaged into shared module to use it directly from there. But there
is a custom Vaadin version of google elemental dep and it's OSGi
compatible. Flow uses this version and to be able to use FW in MPR the
versions should match. So the Vaadin google elemental dep is added
instead of repackaging.

Authored-by: Denis <denis@vaadin.com>
shared/bnd.bnd
shared/pom.xml

index 56b69fdfd06fbea4d1f471b6771aa7675ea591be..93e05116cf49494d2c903331fcdeda9dc23a4910 100644 (file)
@@ -3,7 +3,6 @@ Bundle-Activator: com.vaadin.osgi.resources.OsgiVaadinResources
 Bundle-Name: Vaadin Shared
 Bundle-RequiredExecutionEnvironment: JavaSE-1.8
 Bundle-License: http://www.apache.org/licenses/LICENSE-2.0
-Import-Package: org.osgi*
+Import-Package: org.osgi*, elemental.json*
 Export-Package: com.vaadin.osgi.resources;-noimport:=true,\
-  com.vaadin.shared*;-noimport:=true,\
-  elemental.json*;-noimport:=true
+  com.vaadin.shared*;-noimport:=tru
index a206b0d137e29fb39b77364d731a593e72b3d407..085f94ecbc84fc6a75795e192370fe04691b4a0b 100644 (file)
             <groupId>org.osgi</groupId>
             <artifactId>osgi.cmpn</artifactId>
         </dependency>
+
+        <dependency>
+            <groupId>com.vaadin.external.gwt</groupId>
+            <artifactId>gwt-elemental</artifactId>
+            <version>2.8.2.vaadin2</version>
+        </dependency>
     </dependencies>
 
     <build>
                 </executions>
             </plugin>
 
-            <!-- Copy needed GWT dependencies to package -->
-            <plugin>
-                <groupId>org.apache.maven.plugins</groupId>
-                <artifactId>maven-dependency-plugin</artifactId>
-                <executions>
-                    <execution>
-                        <id>unpack-dependencies</id>
-                        <phase>generate-resources</phase>
-                        <goals>
-                            <goal>unpack</goal>
-                        </goals>
-                        <configuration>
-                            <artifactItems>
-                                <artifactItem>
-                                    <groupId>com.google.gwt</groupId>
-                                    <artifactId>gwt-elemental</artifactId>
-                                    <includes>
-                                        elemental/json/**,
-                                        elemental/util/Array*,
-                                        elemental/util/Can*,
-                                        elemental/util/Map*
-                                    </includes>
-                                </artifactItem>
-                            </artifactItems>
-                        </configuration>
-                    </execution>
-                </executions>
-            </plugin>
-
-            <!-- Unpacked Dependencies as source -->
-            <plugin>
-                <groupId>org.codehaus.mojo</groupId>
-                <artifactId>build-helper-maven-plugin</artifactId>
-
-                <!-- Needs extra source folder for unpacked dependencies -->
-                <executions>
-                    <execution>
-                        <id>add-source-path</id>
-                        <phase>generate-sources</phase>
-                        <goals>
-                            <goal>add-source</goal>
-                        </goals>
-                        <configuration>
-                            <sources>
-                                <source>${dependency.unpack.directory}</source>
-                            </sources>
-                        </configuration>
-                    </execution>
-                </executions>
-            </plugin>
-
             <plugin>
                 <artifactId>maven-resources-plugin</artifactId>
                 <executions>