[jitsi-dev] How do I build linux native libs for libjitsi


#1

I need to build native libs like libjnopenssl.so on ubuntu by following the
instruction in libjitsi/build.xml.
Using target rebuild for example. It does build and package but it does not
produce new .so files.

Without this build, it will fail to load the jnopenssl lib on target
machine and performance is seriously degraded.

So my question is, are the instructions still correct and complete?

/Olof

Disclaimer

The information contained in this communication from the sender is confidential. It is intended solely for use by the recipient and others authorized to receive it. If you are not the recipient, you are hereby notified that any disclosure, copying, distribution or taking action in relation of the contents of this information is strictly prohibited and may be unlawful.


#2

Olof,

I am curious to know why you need to build libjnopenssl.so?

Best regards,

/Kaiduan

···

On Wed, Apr 25, 2018 at 3:41 AM, Olof Källander <olof.kallander@symphony.com > wrote:

I need to build native libs like libjnopenssl.so on ubuntu by following
the instruction in libjitsi/build.xml.
Using target rebuild for example. It does build and package but it does
not produce new .so files.

Without this build, it will fail to load the jnopenssl lib on target
machine and performance is seriously degraded.

So my question is, are the instructions still correct and complete?

/Olof

*Disclaimer*

The information contained in this communication from the sender is
confidential. It is intended solely for use by the recipient and others
authorized to receive it. If you are not the recipient, you are hereby
notified that any disclosure, copying, distribution or taking action in
relation of the contents of this information is strictly prohibited and may
be unlawful.

_______________________________________________
dev mailing list
dev@jitsi.org
Unsubscribe instructions and other list options:
http://lists.jitsi.org/mailman/listinfo/dev

--
Founder of Goodstartsoft
https://www.goodstartsoft.com


#3

We managed to build the jnopenssl lib and it solved lion part of the
performance problem.

The issue we had was this:
When running the JVB on CentOS7 and RedHat linux machines, as required by
customer, about 40% of used CPU went into computing HMAC SHA1 hash of RTP
packets. The reason was that those linux flavours have cryptolib 1.0.2, and
1.0.1 which are not the ones used by jnopenssl in libjitsi artifacts pulled
with maven. There is a warning log that the jnopenssl could not be loaded
due to missing native dependency. However, JVB continues to work by doing
fallback to bouncycastle java implementation of SHA1.

kind regards
/Olof

···

On Wed, Apr 25, 2018 at 3:13 PM, Kaiduan Xie <kaiduanx@gmail.com> wrote:

Olof,

I am curious to know why you need to build libjnopenssl.so?

Best regards,

/Kaiduan

On Wed, Apr 25, 2018 at 3:41 AM, Olof Källander < > olof.kallander@symphony.com> wrote:

I need to build native libs like libjnopenssl.so on ubuntu by following
the instruction in libjitsi/build.xml.
Using target rebuild for example. It does build and package but it does
not produce new .so files.

Without this build, it will fail to load the jnopenssl lib on target
machine and performance is seriously degraded.

So my question is, are the instructions still correct and complete?

/Olof

*Disclaimer*

The information contained in this communication from the sender is
confidential. It is intended solely for use by the recipient and others
authorized to receive it. If you are not the recipient, you are hereby
notified that any disclosure, copying, distribution or taking action in
relation of the contents of this information is strictly prohibited and may
be unlawful.

_______________________________________________
dev mailing list
dev@jitsi.org
Unsubscribe instructions and other list options:
http://lists.jitsi.org/mailman/listinfo/dev

--
Founder of Goodstartsoft
https://www.goodstartsoft.com

_______________________________________________
dev mailing list
dev@jitsi.org
Unsubscribe instructions and other list options:
http://lists.jitsi.org/mailman/listinfo/dev

Disclaimer

The information contained in this communication from the sender is confidential. It is intended solely for use by the recipient and others authorized to receive it. If you are not the recipient, you are hereby notified that any disclosure, copying, distribution or taking action in relation of the contents of this information is strictly prohibited and may be unlawful.


#4

Olof,

Does the error look like below?

JVB [2018-05-03 13:16:03.730] [WARNING]: [145]
[org.jitsi.impl.neomedia.transform.srtp.OpenSSLWrapperLoader.log()] Unable
to load jnopenssl: java.lang.UnsatisfiedLinkError:
/tmp/jna-105622/jna7560063729800165205.tmp: libcrypto.so.1.0.0: cannot open
shared object file: No such file or directory

Thanks,

/Kaiduan

···

On Thu, May 3, 2018 at 4:15 AM, Olof Källander <olof.kallander@symphony.com> wrote:

We managed to build the jnopenssl lib and it solved lion part of the
performance problem.

The issue we had was this:
When running the JVB on CentOS7 and RedHat linux machines, as required by
customer, about 40% of used CPU went into computing HMAC SHA1 hash of RTP
packets. The reason was that those linux flavours have cryptolib 1.0.2, and
1.0.1 which are not the ones used by jnopenssl in libjitsi artifacts pulled
with maven. There is a warning log that the jnopenssl could not be loaded
due to missing native dependency. However, JVB continues to work by doing
fallback to bouncycastle java implementation of SHA1.

kind regards
/Olof

On Wed, Apr 25, 2018 at 3:13 PM, Kaiduan Xie <kaiduanx@gmail.com> wrote:

Olof,

I am curious to know why you need to build libjnopenssl.so?

Best regards,

/Kaiduan

On Wed, Apr 25, 2018 at 3:41 AM, Olof Källander < >> olof.kallander@symphony.com> wrote:

I need to build native libs like libjnopenssl.so on ubuntu by following
the instruction in libjitsi/build.xml.
Using target rebuild for example. It does build and package but it does
not produce new .so files.

Without this build, it will fail to load the jnopenssl lib on target
machine and performance is seriously degraded.

So my question is, are the instructions still correct and complete?

/Olof

*Disclaimer*

The information contained in this communication from the sender is
confidential. It is intended solely for use by the recipient and others
authorized to receive it. If you are not the recipient, you are hereby
notified that any disclosure, copying, distribution or taking action in
relation of the contents of this information is strictly prohibited and may
be unlawful.

_______________________________________________
dev mailing list
dev@jitsi.org
Unsubscribe instructions and other list options:
http://lists.jitsi.org/mailman/listinfo/dev

--
Founder of Goodstartsoft
https://www.goodstartsoft.com

_______________________________________________
dev mailing list
dev@jitsi.org
Unsubscribe instructions and other list options:
http://lists.jitsi.org/mailman/listinfo/dev

*Disclaimer*

The information contained in this communication from the sender is
confidential. It is intended solely for use by the recipient and others
authorized to receive it. If you are not the recipient, you are hereby
notified that any disclosure, copying, distribution or taking action in
relation of the contents of this information is strictly prohibited and may
be unlawful.

_______________________________________________
dev mailing list
dev@jitsi.org
Unsubscribe instructions and other list options:
http://lists.jitsi.org/mailman/listinfo/dev

--
Founder of Goodstartsoft
https://www.goodstartsoft.com


#5

Olof,

You can use the following steps to build jnopenssl.

rm -rf ~/.m2

mvn dependency:tree

mvn dependency:get -DartifactId=maven-ant-tasks -DgroupId=org.apache.maven
-Dversion=2.1.3

ant -lib ~/.m2/repository/org/apache/maven/maven-ant-tasks/2.1.3 make

export JAVA_HOME=/usr/lib/jvm/java-1.8.0-openjdk/

ant -lib ~/.m2/repository/org/apache/maven/maven-ant-tasks/2.1.3 jnopenssl

After above steps you can build libjitsi that will have the new jnopenssl.

/Kaiduan

···

On Thu, May 3, 2018 at 9:20 AM, Kaiduan Xie <kaiduanx@gmail.com> wrote:

Olof,

Does the error look like below?

JVB [2018-05-03 13:16:03.730] [WARNING]: [145] [org.jitsi.impl.neomedia.
transform.srtp.OpenSSLWrapperLoader.log()] Unable to load jnopenssl:
java.lang.UnsatisfiedLinkError: /tmp/jna-105622/jna7560063729800165205.tmp:
libcrypto.so.1.0.0: cannot open shared object file: No such file or
directory

Thanks,

/Kaiduan

On Thu, May 3, 2018 at 4:15 AM, Olof Källander < > olof.kallander@symphony.com> wrote:

We managed to build the jnopenssl lib and it solved lion part of the
performance problem.

The issue we had was this:
When running the JVB on CentOS7 and RedHat linux machines, as required by
customer, about 40% of used CPU went into computing HMAC SHA1 hash of RTP
packets. The reason was that those linux flavours have cryptolib 1.0.2, and
1.0.1 which are not the ones used by jnopenssl in libjitsi artifacts pulled
with maven. There is a warning log that the jnopenssl could not be loaded
due to missing native dependency. However, JVB continues to work by doing
fallback to bouncycastle java implementation of SHA1.

kind regards
/Olof

On Wed, Apr 25, 2018 at 3:13 PM, Kaiduan Xie <kaiduanx@gmail.com> wrote:

Olof,

I am curious to know why you need to build libjnopenssl.so?

Best regards,

/Kaiduan

On Wed, Apr 25, 2018 at 3:41 AM, Olof Källander < >>> olof.kallander@symphony.com> wrote:

I need to build native libs like libjnopenssl.so on ubuntu by following
the instruction in libjitsi/build.xml.
Using target rebuild for example. It does build and package but it does
not produce new .so files.

Without this build, it will fail to load the jnopenssl lib on target
machine and performance is seriously degraded.

So my question is, are the instructions still correct and complete?

/Olof

*Disclaimer*

The information contained in this communication from the sender is
confidential. It is intended solely for use by the recipient and others
authorized to receive it. If you are not the recipient, you are hereby
notified that any disclosure, copying, distribution or taking action in
relation of the contents of this information is strictly prohibited and may
be unlawful.

_______________________________________________
dev mailing list
dev@jitsi.org
Unsubscribe instructions and other list options:
http://lists.jitsi.org/mailman/listinfo/dev

--
Founder of Goodstartsoft
https://www.goodstartsoft.com

_______________________________________________
dev mailing list
dev@jitsi.org
Unsubscribe instructions and other list options:
http://lists.jitsi.org/mailman/listinfo/dev

*Disclaimer*

The information contained in this communication from the sender is
confidential. It is intended solely for use by the recipient and others
authorized to receive it. If you are not the recipient, you are hereby
notified that any disclosure, copying, distribution or taking action in
relation of the contents of this information is strictly prohibited and may
be unlawful.

_______________________________________________
dev mailing list
dev@jitsi.org
Unsubscribe instructions and other list options:
http://lists.jitsi.org/mailman/listinfo/dev

--
Founder of Goodstartsoft
https://www.goodstartsoft.com

--
Founder of Goodstartsoft
https://www.goodstartsoft.com


#6

Sorry for late reply. Yes that is what the error looks like and we solved
it by rebuilding native jnopenssl as you described. Thanks.

···

On Thu, May 3, 2018 at 3:20 PM, Kaiduan Xie <kaiduanx@gmail.com> wrote:

Olof,

Does the error look like below?

JVB [2018-05-03 13:16:03.730] [WARNING]: [145] [org.jitsi.impl.neomedia.
transform.srtp.OpenSSLWrapperLoader.log()] Unable to load jnopenssl:
java.lang.UnsatisfiedLinkError: /tmp/jna-105622/jna7560063729800165205.tmp:
libcrypto.so.1.0.0: cannot open shared object file: No such file or
directory

Thanks,

/Kaiduan

On Thu, May 3, 2018 at 4:15 AM, Olof Källander < > olof.kallander@symphony.com> wrote:

We managed to build the jnopenssl lib and it solved lion part of the
performance problem.

The issue we had was this:
When running the JVB on CentOS7 and RedHat linux machines, as required by
customer, about 40% of used CPU went into computing HMAC SHA1 hash of RTP
packets. The reason was that those linux flavours have cryptolib 1.0.2, and
1.0.1 which are not the ones used by jnopenssl in libjitsi artifacts pulled
with maven. There is a warning log that the jnopenssl could not be loaded
due to missing native dependency. However, JVB continues to work by doing
fallback to bouncycastle java implementation of SHA1.

kind regards
/Olof

On Wed, Apr 25, 2018 at 3:13 PM, Kaiduan Xie <kaiduanx@gmail.com> wrote:

Olof,

I am curious to know why you need to build libjnopenssl.so?

Best regards,

/Kaiduan

On Wed, Apr 25, 2018 at 3:41 AM, Olof Källander < >>> olof.kallander@symphony.com> wrote:

I need to build native libs like libjnopenssl.so on ubuntu by following
the instruction in libjitsi/build.xml.
Using target rebuild for example. It does build and package but it does
not produce new .so files.

Without this build, it will fail to load the jnopenssl lib on target
machine and performance is seriously degraded.

So my question is, are the instructions still correct and complete?

/Olof

*Disclaimer*

The information contained in this communication from the sender is
confidential. It is intended solely for use by the recipient and others
authorized to receive it. If you are not the recipient, you are hereby
notified that any disclosure, copying, distribution or taking action in
relation of the contents of this information is strictly prohibited and may
be unlawful.

_______________________________________________
dev mailing list
dev@jitsi.org
Unsubscribe instructions and other list options:
http://lists.jitsi.org/mailman/listinfo/dev

--
Founder of Goodstartsoft
https://www.goodstartsoft.com

_______________________________________________
dev mailing list
dev@jitsi.org
Unsubscribe instructions and other list options:
http://lists.jitsi.org/mailman/listinfo/dev

*Disclaimer*

The information contained in this communication from the sender is
confidential. It is intended solely for use by the recipient and others
authorized to receive it. If you are not the recipient, you are hereby
notified that any disclosure, copying, distribution or taking action in
relation of the contents of this information is strictly prohibited and may
be unlawful.

_______________________________________________
dev mailing list
dev@jitsi.org
Unsubscribe instructions and other list options:
http://lists.jitsi.org/mailman/listinfo/dev

--
Founder of Goodstartsoft
https://www.goodstartsoft.com

_______________________________________________
dev mailing list
dev@jitsi.org
Unsubscribe instructions and other list options:
http://lists.jitsi.org/mailman/listinfo/dev

Disclaimer

The information contained in this communication from the sender is confidential. It is intended solely for use by the recipient and others authorized to receive it. If you are not the recipient, you are hereby notified that any disclosure, copying, distribution or taking action in relation of the contents of this information is strictly prohibited and may be unlawful.