Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use a submodule for secp256k1 instead of copying files #17

Merged
merged 6 commits into from
Mar 19, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[submodule "secp256k1"]
path = secp256k1
url = https://github.com/pm47/secp256k1.git
18 changes: 14 additions & 4 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,20 @@
language: scala
before_install:
- sudo apt-get install libgmp-dev
install:
# first let's build the libsecp256k1 jni lib
- cd secp256k1
- ./autogen.sh
- ./configure --enable-jni --enable-experimental --enable-module-ecdh
- make
- cd ..
# then we build the java/scala lib
- mvn install -DskipTests
script:
# test with bouncycastle
- mvn test
# test with libsecp256k1
- export LD_LIBRARY_PATH=secp256k1/.libs
- mvn test
- LD_LIBRARY_PATH=$TRAVIS_BUILD_DIR/src/test/resources mvn test
scala:
- 2.11.7
- 2.11.11
jdk:
- oraclejdk8
63 changes: 32 additions & 31 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,38 @@

<build>
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>build-helper-maven-plugin</artifactId>
<version>3.0.0</version>
<executions>
<execution>
<id>add-source</id>
<phase>generate-sources</phase>
<goals>
<goal>add-source</goal>
</goals>
<configuration>
<sources>
<source>secp256k1/src/java</source>
<source>src/main/scala</source>
</sources>
</configuration>
</execution>
<execution>
<id>add-test-source</id>
<phase>generate-test-sources</phase>
<goals>
<goal>add-test-source</goal>
</goals>
<configuration>
<sources>
<source>src/test/scala</source>
</sources>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
Expand Down Expand Up @@ -112,37 +144,6 @@
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>build-helper-maven-plugin</artifactId>
<version>3.0.0</version>
<executions>
<execution>
<id>add-source</id>
<phase>generate-sources</phase>
<goals>
<goal>add-source</goal>
</goals>
<configuration>
<sources>
<source>src/main/scala</source>
</sources>
</configuration>
</execution>
<execution>
<id>add-test-source</id>
<phase>generate-test-sources</phase>
<goals>
<goal>add-test-source</goal>
</goals>
<configuration>
<sources>
<source>src/test/scala</source>
</sources>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
Expand Down
1 change: 1 addition & 0 deletions secp256k1
Submodule secp256k1 added at 2e16ac
Loading