Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
L
libjitsi
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Analyze
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
ZRTP
libjitsi
Commits
7d708eaa
Commit
7d708eaa
authored
12 years ago
by
Damian Minkov
Browse files
Options
Downloads
Patches
Plain Diff
Adds opus to build native xml.
parent
23f99ab7
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/native/build.xml
+87
-0
87 additions, 0 deletions
src/native/build.xml
with
87 additions
and
0 deletions
src/native/build.xml
+
87
−
0
View file @
7d708eaa
...
@@ -551,6 +551,93 @@
...
@@ -551,6 +551,93 @@
</cc>
</cc>
</target>
</target>
<!-- compile opus
linux binaries are linked to the distribution binary (call ant -Dopus=)
while other os opus is added to shared library, to avoid
additional binaries
macosx and windows currently not tested.
-->
<target
name=
"opus"
description=
"Build opus shared library"
depends=
"init-native"
>
<fail
message=
"opus repository not set!"
unless=
"opus"
/>
<cc
outtype=
"shared"
name=
"gcc"
outfile=
"${native_install_dir}/opus"
objdir=
"${obj}"
>
<!-- common compiler flags -->
<compilerarg
value=
"-shared"
/>
<compilerarg
value=
"-Wall"
/>
<compilerarg
value=
"-fPIC"
/>
<compilerarg
value=
"-O2"
/>
<compilerarg
value=
"-I${opus}/include"
unless=
"is.running.linux"
/>
<compilerarg
value=
"-I/usr/include/opus"
if=
"is.running.linux"
/>
<compilerarg
value=
"-D_JNI_IMPLEMENTATION_"
/>
<linkerarg
value=
"-L${opus}/.libs"
/>
<!-- Linux specific flags -->
<compilerarg
value=
"-m32"
if=
"cross_32"
unless=
"is.running.macos"
/>
<compilerarg
value=
"-m64"
if=
"cross_64"
unless=
"is.running.macos"
/>
<compilerarg
value=
"-I${system.JAVA_HOME}/include"
if=
"is.running.linux"
/>
<compilerarg
value=
"-I${system.JAVA_HOME}/include/linux"
if=
"is.running.linux"
/>
<linkerarg
value=
"-m32"
if=
"cross_32"
unless=
"is.running.macos"
/>
<linkerarg
value=
"-m64"
if=
"cross_64"
unless=
"is.running.macos"
/>
<!-- static libraries MUST be at the end otherwise
they will not be added to shared library
-->
<!--<linkerarg value="-Wl,-Bstatic" location="end" if="is.running.linux" />-->
<linkerarg
value=
"-lopus"
location=
"end"
if=
"is.running.linux"
/>
<!--<linkerarg value="-Wl,-Bdynamic" location="end" if="is.running.linux" />-->
<linkerarg
value=
"-o"
location=
"end"
if=
"is.running.linux"
/>
<linkerarg
value=
"libjnopus.so"
location=
"end"
if=
"is.running.linux"
/>
<!-- Mac OS X specific flags -->
<compilerarg
value=
"-mmacosx-version-min=10.5"
if=
"is.running.macos"
/>
<compilerarg
value=
"-arch"
if=
"is.running.macos"
/>
<compilerarg
value=
"x86_64"
if=
"is.running.macos"
/>
<compilerarg
value=
"-arch"
if=
"is.running.macos"
/>
<compilerarg
value=
"i386"
if=
"is.running.macos"
/>
<compilerarg
value=
"-arch"
if=
"is.running.macos"
/>
<compilerarg
value=
"ppc"
if=
"is.running.macos"
/>
<compilerarg
value=
"-I/System/Library/Frameworks/JavaVM.framework/Headers"
if=
"is.running.macos"
/>
<linkerarg
value=
"-o"
location=
"end"
if=
"is.running.macos"
/>
<linkerarg
value=
"libjnopus.jnilib"
location=
"end"
if=
"is.running.macos"
/>
<linkerarg
value=
"-dynamiclib"
if=
"is.running.macos"
/>
<linkerarg
value=
"-arch"
if=
"is.running.macos"
/>
<linkerarg
value=
"x86_64"
if=
"is.running.macos"
/>
<linkerarg
value=
"-arch"
if=
"is.running.macos"
/>
<linkerarg
value=
"i386"
if=
"is.running.macos"
/>
<linkerarg
value=
"-arch"
if=
"is.running.macos"
/>
<linkerarg
value=
"ppc"
if=
"is.running.macos"
/>
<linkerarg
value=
"-lopus"
location=
"end"
if=
"is.running.macos"
/>
<!-- Windows specific flags -->
<compilerarg
value=
"-I${system.JAVA_HOME}/include"
if=
"is.running.windows"
/>
<compilerarg
value=
"-I${system.JAVA_HOME}/include/win32"
if=
"is.running.windows"
/>
<linkerarg
value=
"-ojnopus.dll"
if=
"is.running.windows"
/>
<linkerarg
value=
"-Wl,--no-undefined"
if=
"is.running.windows"
/>
<linkerarg
value=
"-Wl,--kill-at"
if=
"is.running.windows"
/>
<linkerarg
value=
"-Wl,-Bstatic"
location=
"end"
if=
"is.running.windows"
/>
<linkerarg
value=
"-lopus"
location=
"end"
if=
"is.running.windows"
/>
<fileset
dir=
"${src}/native/opus"
includes=
"*.c"
/>
<!-- opus libraries cannot be built as universal binaries
so you have to setup and compile opus for each architecture separately.
Run this ant script with:
-Darch=32 (rename libjnopus.jnilib to libjnopus.jnilib-32)
-Darch=64 (rename libjnopus.jnilib to libjnopus.jnilib-64)
Finally create the universal binary with:
lipo -create libjnopus.jnilib-* -output libjnopus.jnilib
strip libjnopus.jnilib
-->
</cc>
</target>
<!-- compile jnvideo4linux2 library -->
<!-- compile jnvideo4linux2 library -->
<target
name=
"video4linux2"
description=
"Build jnvideo4linux2 shared library"
if=
"is.running.linux"
<target
name=
"video4linux2"
description=
"Build jnvideo4linux2 shared library"
if=
"is.running.linux"
depends=
"init-native"
>
depends=
"init-native"
>
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment