forked from bisq-network/tor-binary
-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathpom.xml
More file actions
86 lines (78 loc) · 3.94 KB
/
pom.xml
File metadata and controls
86 lines (78 loc) · 3.94 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<parent>
<groupId>com.github.haveno-dex.tor-binary</groupId>
<artifactId>tor-binary</artifactId>
<version>0.4.9.5</version>
</parent>
<modelVersion>4.0.0</modelVersion>
<artifactId>tor-binary-linux32</artifactId>
<packaging>jar</packaging>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-remote-resources-plugin</artifactId>
<version>1.6.0</version>
<configuration>
<resourceBundles>
<resourceBundle>com.github.haveno-dex.tor-binary:tor-binary-resources:${project.version}</resourceBundle>
</resourceBundles>
</configuration>
<executions>
<execution>
<goals>
<goal>process</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<artifactId>maven-antrun-plugin</artifactId>
<version>1.8</version>
<executions>
<execution>
<id>download-and-verify</id>
<phase>generate-resources</phase>
<configuration>
<target>
<!-- Setup directories -->
<delete dir="${project.build.directory}/linux-x86" failonerror="false" />
<mkdir dir="${project.build.directory}/linux-x86" />
<!-- Unpack the expert bundle (.tar.gz) -->
<exec executable="tar" dir="${project.build.directory}/linux-x86" failonerror="true">
<arg value="-xzf" />
<arg value="${project.remote-resource.directory}/tor-expert-bundle-linux-i686-${torbrowser.version}.tar.gz" />
</exec>
<!-- Identify binary path (expert bundles put files in 'tor') -->
<available file="${project.build.directory}/linux-x86/tor" type="dir" property="binpath" value="${project.build.directory}/linux-x86/tor/" />
<property name="binpath" value="${project.build.directory}/linux-x86/" />
<!-- Re-package into the project's internal format (.tar.xz) -->
<delete dir="${project.basedir}/src/" failonerror="false" />
<mkdir dir="${project.basedir}/src/main/resources/native/linux/x86/" />
<exec executable="tar" dir="${binpath}" failonerror="true">
<arg line="-cJvf ${project.basedir}/src/main/resources/native/linux/x86/tor.tar.xz ." />
</exec>
<!-- Cleanup -->
<delete dir="${project.remote-resource.directory}" />
</target>
</configuration>
<goals>
<goal>run</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
<pluginManagement>
<plugins>
<plugin>
<artifactId>maven-antrun-plugin</artifactId>
<version>1.8</version>
</plugin>
</plugins>
</pluginManagement>
</build>
</project>