@@ -53,27 +53,27 @@ ProjectSnapshotGenerator.installSnapshotArtefacts = function(projectRoot) {
53
53
const buildPath = ProjectSnapshotGenerator . calculateBuildPath ( projectRoot ) ;
54
54
const platformPath = path . join ( projectRoot , "platforms/android" ) ;
55
55
const assetsPath = path . join ( platformPath , "src/main/assets" ) ;
56
+ const configDestinationPath = path . join ( platformPath , "configurations" , SnapshotGenerator . SNAPSHOT_PACKAGE_NANE ) ;
56
57
57
58
// Remove build folder to make sure that the apk will be fully rebuild
58
59
shelljs . rm ( "-rf" , path . join ( platformPath , "build" ) ) ;
59
60
61
+ // Copy include.gradle to the specified destination in the platforms folder
62
+ shelljs . mkdir ( "-p" , configDestinationPath ) ;
63
+ shelljs . cp ( path . join ( buildPath , "include.gradle" ) , path . join ( configDestinationPath , "include.gradle" ) ) ;
64
+
60
65
// Copy tns-java-classes.js
61
66
if ( shelljs . test ( "-e" , path . join ( buildPath , "tns-java-classes.js" ) ) ) {
62
67
shelljs . cp ( path . join ( buildPath , "tns-java-classes.js" ) , path . join ( assetsPath , "app/tns-java-classes.js" ) ) ;
63
68
}
64
69
65
70
if ( shelljs . test ( "-e" , path . join ( buildPath , "ndk-build/libs" ) ) ) {
66
71
// useLibs = true
67
- const libsDestinationPath = path . join ( projectRoot , "platforms/android/src" , SnapshotGenerator . SNAPSHOT_PACKAGE_NANE , "jniLibs" ) ;
68
- const configDestinationPath = path . join ( projectRoot , "platforms/android/configurations" , SnapshotGenerator . SNAPSHOT_PACKAGE_NANE ) ;
72
+ const libsDestinationPath = path . join ( platformPath , "src" , SnapshotGenerator . SNAPSHOT_PACKAGE_NANE , "jniLibs" ) ;
69
73
70
74
// Copy the libs to the specified destination in the platforms folder
71
75
shelljs . mkdir ( "-p" , libsDestinationPath ) ;
72
76
shelljs . cp ( "-R" , path . join ( buildPath , "ndk-build/libs" ) + "/" , libsDestinationPath ) ;
73
-
74
- // Copy include.gradle to the specified destination in the platforms folder
75
- shelljs . mkdir ( "-p" , configDestinationPath ) ;
76
- shelljs . cp ( path . join ( buildPath , "include.gradle" ) , path . join ( configDestinationPath , "include.gradle" ) ) ;
77
77
}
78
78
else {
79
79
// useLibs = false
0 commit comments