Skip to content

Commit

Permalink
update to libtorrent master HEAD
Browse files Browse the repository at this point in the history
  • Loading branch information
aldenml committed Oct 21, 2024
1 parent f2163ba commit 7261cab
Show file tree
Hide file tree
Showing 7 changed files with 32 additions and 4 deletions.
2 changes: 2 additions & 0 deletions src/main/java/org/libtorrent4j/swig/file_storage.java
Original file line number Diff line number Diff line change
Expand Up @@ -258,6 +258,8 @@ public String file_name_ex(int index) {

public final static long max_file_size = libtorrent_jni.file_storage_max_file_size_get();
public final static long max_file_offset = libtorrent_jni.file_storage_max_file_offset_get();
public final static int max_num_pieces = libtorrent_jni.file_storage_max_num_pieces_get();
public final static int max_piece_size = libtorrent_jni.file_storage_max_piece_size_get();
public final static file_flags_t flag_pad_file = new file_flags_t(libtorrent_jni.file_storage_flag_pad_file_get(), false);
public final static file_flags_t flag_hidden = new file_flags_t(libtorrent_jni.file_storage_flag_hidden_get(), false);
public final static file_flags_t flag_executable = new file_flags_t(libtorrent_jni.file_storage_flag_executable_get(), false);
Expand Down
2 changes: 2 additions & 0 deletions src/main/java/org/libtorrent4j/swig/libtorrent_jni.java
Original file line number Diff line number Diff line change
Expand Up @@ -970,6 +970,8 @@ public class libtorrent_jni {
public final static native long new_file_storage__SWIG_1(long jarg1, file_storage jarg1_);
public final static native long file_storage_max_file_size_get();
public final static native long file_storage_max_file_offset_get();
public final static native int file_storage_max_num_pieces_get();
public final static native int file_storage_max_piece_size_get();
public final static native boolean file_storage_is_valid(long jarg1, file_storage jarg1_);
public final static native void file_storage_reserve(long jarg1, file_storage jarg1_, int jarg2);
public final static native void file_storage_rename_file(long jarg1, file_storage jarg1_, int jarg2, String jarg3);
Expand Down
2 changes: 1 addition & 1 deletion swig/build-macos-arm64.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash

export BOOST_ROOT=$DEVELOPMENT_ROOT/boost_1_80_0
export BOOST_ROOT=$DEVELOPMENT_ROOT/boost_1_86_0
export LIBTORRENT_ROOT=$PWD/deps/libtorrent
export OPENSSL_ROOT=$DEVELOPMENT_ROOT/openssl-macos

Expand Down
2 changes: 1 addition & 1 deletion swig/build-macos.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash

export BOOST_ROOT=$DEVELOPMENT_ROOT/boost_1_80_0
export BOOST_ROOT=$DEVELOPMENT_ROOT/boost_1_86_0
export LIBTORRENT_ROOT=$PWD/deps/libtorrent
export OPENSSL_ROOT=$DEVELOPMENT_ROOT/openssl-macos

Expand Down
2 changes: 1 addition & 1 deletion swig/deps/libtorrent
Submodule libtorrent updated 160 files
24 changes: 24 additions & 0 deletions swig/libtorrent_jni.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -29261,6 +29261,30 @@ SWIGEXPORT jlong JNICALL Java_org_libtorrent4j_swig_libtorrent_1jni_file_1storag
}


SWIGEXPORT jint JNICALL Java_org_libtorrent4j_swig_libtorrent_1jni_file_1storage_1max_1num_1pieces_1get(JNIEnv *jenv, jclass jcls) {
jint jresult = 0 ;
int result;

(void)jenv;
(void)jcls;
result = (int)libtorrent::file_storage::max_num_pieces;
jresult = (jint)result;
return jresult;
}


SWIGEXPORT jint JNICALL Java_org_libtorrent4j_swig_libtorrent_1jni_file_1storage_1max_1piece_1size_1get(JNIEnv *jenv, jclass jcls) {
jint jresult = 0 ;
int result;

(void)jenv;
(void)jcls;
result = (int)libtorrent::file_storage::max_piece_size;
jresult = (jint)result;
return jresult;
}


SWIGEXPORT jboolean JNICALL Java_org_libtorrent4j_swig_libtorrent_1jni_file_1storage_1is_1valid(JNIEnv *jenv, jclass jcls, jlong jarg1, jobject jarg1_) {
jboolean jresult = 0 ;
libtorrent::file_storage *arg1 = (libtorrent::file_storage *) 0 ;
Expand Down
2 changes: 1 addition & 1 deletion swig/run-swig.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash

BOOST_ROOT=$DEVELOPMENT_ROOT/boost_1_80_0
BOOST_ROOT=$DEVELOPMENT_ROOT/boost_1_86_0
LIBTORRENT_ROOT=deps/libtorrent

function fixCode() {
Expand Down

0 comments on commit 7261cab

Please sign in to comment.