Jump to content

Recommended Posts

Posted (edited)

I'm not really sure what the correct paths would be for my system.

 

What did you use to install mono?

 

You can use the locate command to find mono(if locate give an error, try updatedb first):

locate -r bin\/mono$

On my system, I get this:

/opt/mono/bin/mono  <-- new version: mono 3.2.7
/usr/bin/mono       <-- installed by fedora
Edited by abeloin
  • Like 1
Posted

I built it from git.

 

locate gives me: 

/opt/mono/mono/runtime/_tmpinst/bin/mono
/usr/bin/mono
/usr/local/bin/mono
Posted

 

I built it from git.

 

locate gives me: 

/opt/mono/mono/runtime/_tmpinst/bin/mono
/usr/bin/mono
/usr/local/bin/mono

 

I would guess /usr/local/bin/mono is the one.

 

To check it:

/usr/local/bin/mono --version

If it's 3.2.7, then the env.sh should be

export PATH=/usr/local/bin:$PATH
export LD_LIBRARY_PATH=/usr/local/lib:$LD_LIBRARY_PATH
export PKG_CONFIG_PATH=/usr/local/lib/pkgconfig:$PKG_CONFIG_PATH
  • Like 1
Posted
export PATH=/usr/local/bin:$PATH
export LD_LIBRARY_PATH=/usr/local/lib:$LD_LIBRARY_PATH
export PKG_CONFIG_PATH=/usr/local/lib/pkgconfig:$PKG_CONFIG_PATH

 

Ok I tried that, but it's still throwing the DLLImport errors.

 

I tried the export command and the paths are definitely there now, but I noticed they have a trailing colon where various other paths don't if that matters.

declare -x PKG_CONFIG_PATH="/usr/local/lib/pkgconfig:"
Posted

 

Ok I tried that, but it's still throwing the DLLImport errors.

 

I tried the export command and the paths are definitely there now, but I noticed they have a trailing colon where various other paths don't if that matters.

declare -x PKG_CONFIG_PATH="/usr/local/lib/pkgconfig:"

That's ok.

 

My bad, I forgot you told me it was x86_64 version, it should be lib64 not lib for the LD and PKG.

 

Check with this:

locate libMonoPosixHelper.so

It should give you:

/usr/local/lib64/libMonoPosixHelper.so
  • Like 1
Posted

It should give you:

/usr/local/lib64/libMonoPosixHelper.so

 

Hmm, nope.  I don't have a lib64 directory.  I just built mono following the link in the first post, should I have used some separate 64bit version instead?

Posted

Hmm, nope.  I don't have a lib64 directory.  I just built mono following the link in the first post, should I have used some separate 64bit version instead?

But do you get any results?

Posted

But do you get any results?

 

Oh yeah sorry, just:

/opt/mono/mono/support/.libs/libMonoPosixHelper.so
/usr/lib/libMonoPosixHelper.so
/usr/local/lib/libMonoPosixHelper.so 
Posted

 

Oh yeah sorry, just:

/opt/mono/mono/support/.libs/libMonoPosixHelper.so
/usr/lib/libMonoPosixHelper.so
/usr/local/lib/libMonoPosixHelper.so 

Ok,

 

Make sure env.sh is like this:

export PATH=/usr/local/bin:$PATH
export LD_LIBRARY_PATH=/usr/local/lib:$LD_LIBRARY_PATH
export PKG_CONFIG_PATH=/usr/local/lib/pkgconfig:$PKG_CONFIG_PATH

Can you try this:

  • Open a new terminal session
  • Go to your mediabrowser installation folder
  • Type at the prompt(without the $ sign)

    $. env.sh

  • Run mediabrowser:

    MONO_LOG_LEVEL="debug" MONO_LOG_MASK="dll" mono MediaBrowser.Server.Mono.exe

And give me the last 50 lines or so.

  • Like 1
Posted (edited)

Mono: DllImport attempting to load: 'libMonoPosixHelper.so'.
Mono: DllImport error loading library '/usr/local/lib/mono/gac/Mono.Posix/4.0.0.0__0738eb9f132ed756/libMonoPosixHelper.so': '/usr/local/lib/mono/gac/Mono.Posix/4.0.0.0__0738eb9f132ed756/libMonoPosixHelper.so: cannot open shared object file: No such file or directory'.
Mono: DllImport error loading library '/usr/local/lib/mono/gac/Mono.Posix/4.0.0.0__0738eb9f132ed756/libMonoPosixHelper.so': '/usr/local/lib/mono/gac/Mono.Posix/4.0.0.0__0738eb9f132ed756/libMonoPosixHelper.so: cannot open shared object file: No such file or directory'.
Mono: DllImport loaded library 'libMonoPosixHelper.so'.
Mono: DllImport searching in: 'libMonoPosixHelper.so' ('libMonoPosixHelper.so').
Mono: Searching for 'Mono_Posix_Syscall_get_at_fdcwd'.
Mono: Probing 'Mono_Posix_Syscall_get_at_fdcwd'.
Mono: Found as 'Mono_Posix_Syscall_get_at_fdcwd'.
Mono: DllImport searching in: 'libMonoPosixHelper.so' ('libMonoPosixHelper.so').
Mono: Searching for 'Mono_Posix_Syscall_L_ctermid'.
Mono: Probing 'Mono_Posix_Syscall_L_ctermid'.
Mono: Found as 'Mono_Posix_Syscall_L_ctermid'.
Mono: DllImport searching in: 'libMonoPosixHelper.so' ('libMonoPosixHelper.so').
Mono: Searching for 'Mono_Posix_Syscall_L_cuserid'.
Mono: Probing 'Mono_Posix_Syscall_L_cuserid'.
Mono: Found as 'Mono_Posix_Syscall_L_cuserid'.
Mono: DllImport searching in: 'libMonoPosixHelper.so' ('libMonoPosixHelper.so').
Mono: Searching for 'Mono_Posix_Syscall_get_utime_now'.
Mono: Probing 'Mono_Posix_Syscall_get_utime_now'.
Mono: Found as 'Mono_Posix_Syscall_get_utime_now'.
Mono: DllImport searching in: 'libMonoPosixHelper.so' ('libMonoPosixHelper.so').
Mono: Searching for 'Mono_Posix_Syscall_get_utime_omit'.
Mono: Probing 'Mono_Posix_Syscall_get_utime_omit'.
Mono: Found as 'Mono_Posix_Syscall_get_utime_omit'.
Info, App, Alchemy Web Socket Server started
Running startup tasks
Info, App, Core startup complete
Mono: DllImport searching in: './sqlite3/linux/lib64/libsqlite3.so.0.8.6' ('./sqlite3/linux/lib64/libsqlite3.so.0.8.6').
Mono: Searching for 'sqlite3_bind_parameter_name'.
Mono: Probing 'sqlite3_bind_parameter_name'.
Mono: Found as 'sqlite3_bind_parameter_name'.
Mono: DllImport searching in: './sqlite3/linux/lib64/libsqlite3.so.0.8.6' ('./sqlite3/linux/lib64/libsqlite3.so.0.8.6').
Mono: Searching for 'sqlite3_bind_blob'.
Mono: Probing 'sqlite3_bind_blob'.
Mono: Found as 'sqlite3_bind_blob'.
Mono: DllImport searching in: './sqlite3/linux/lib64/libsqlite3.so.0.8.6' ('./sqlite3/linux/lib64/libsqlite3.so.0.8.6').
Mono: Searching for 'sqlite3_column_text'.
Mono: Probing 'sqlite3_column_text'.
Mono: Found as 'sqlite3_column_text'.
Mono: DllImport attempting to load: 'libc.so.6'.
Mono: DllImport error loading library '/usr/local/lib/mono/gac/System/4.0.0.0__b77a5c561934e089/libc.so.6': '/usr/local/lib/mono/gac/System/4.0.0.0__b77a5c561934e089/libc.so.6: cannot open shared object file: No such file or directory'.
Mono: DllImport error loading library '/usr/local/lib/mono/gac/System/4.0.0.0__b77a5c561934e089/libc.so.6.so': '/usr/local/lib/mono/gac/System/4.0.0.0__b77a5c561934e089/libc.so.6.so: cannot open shared object file: No such file or directory'.
Mono: DllImport loaded library 'libc.so.6'.
Mono: DllImport searching in: 'libc.so.6' ('libc.so.6').
Mono: Searching for 'uname'.
Mono: Probing 'uname'.
Mono: Found as 'uname'.
Mono: DllImport searching in: 'libc.so.6' ('libc.so.6').
Mono: Searching for 'read'.
Mono: Probing 'read'.
Mono: Found as 'read'.
Edited by spaid
Posted
Info, App, Alchemy Web Socket Server started
Running startup tasks
Info, App, Core startup complete

 

Ok, now it is working. Stop it via Ctrl-C and try without the MONO_LOG

mono MediaBrowser.Server.Mono.exe

Try http://localhost:8096/mediabrowser

 

If you want you can add the ". /pathofthe/env.sh" to your ~/.bashrc, so you don't have to type it every time.

  • Like 1
Posted

Thanks for the help.

Have fun! :)

  • Like 1
Posted (edited)

Any ideas why it keeps saying  "**Error**: You must have `libtool' installed to compile Mono.

Get ftp://ftp.gnu.org/pub/gnu/libtool-1.2d.tar.gz

(or a newer version if it is available)"

 

I already compiled the libtool for mono, but it keeps saying I didn't.  Also, it won't let me complete the last portion of the script:

 

CC='cc -m32' ./autogen.sh --prefix=$PREFIX --disable-nls
make
make install

 

As soon as I try the above code, it gives me the libtool install error above.  That's all I have left, as the rest was successful.

 

If I try to run the Media Browser exe file it tells me it can't execute the binary file.

 

EDIT:  I found this bit of code after running the 2nd "for i in *" statement:

 

libtool: link: rm -fr  libltdl/.libs/libltdl.lax

libtool: link: (cd libltdl/.libs/libltdl.lax/dlopen.a && ar x "/Users/Nathan 1/Build/libtool-2.4.2/libltdl/.libs/dlopen.a")

./libtool: line 1099: cd: libltdl/.libs/libltdl.lax/dlopen.a: No such file or directory

make[2]: *** [libltdl/libltdl.la] Error 1

make[1]: *** [all-recursive] Error 1

make: *** [all] Error 2

 

Is that anything that could be causing problems?

 

Thanks for any help.

Edited by Nate8727
Posted

Should we have two separate threads for Server on OS X and Linux?  I think that might help eliminate confusion when setting up each.

Posted (edited)

Any ideas why it keeps saying  "**Error**: You must have `libtool' installed to compile Mono.

Get ftp://ftp.gnu.org/pub/gnu/libtool-1.2d.tar.gz

(or a newer version if it is available)"

 

I already compiled the libtool for mono, but it keeps saying I didn't.  Also, it won't let me complete the last portion of the script:

 

CC='cc -m32' ./autogen.sh --prefix=$PREFIX --disable-nls

make

make install

Thanks for any help.

 

What version Mac OSX do you have?

 

To see if libtool is installed, look inside /usr/local/bin for libtool:

ls /usr/local/bin | grep libtool

If you are sure that all 3 prerequisites are installed, try this script(it bypass the prerequisites install):

#!/bin/sh -e
PREFIX=/usr/local
 
# Ensure you have write permissions to /usr/local
if [ ! -d "$PREFIX" ]; then
mkdir $PREFIX
fi
sudo chown -R `whoami` $PREFIX

if [ ! -d "$HOME/Build" ]; then
mkdir $HOME/Build
fi
cd $HOME/Build
 
PATH=$PREFIX/bin:$PATH
if [ ! -d "mono" ]; then
git clone https://github.com/mono/mono.git
fi

cd mono

CC='cc -m32' ./autogen --prefix=$PREFIX --disable-nls 
make
make install
 

If not, you can try to build them with this(it will echo commands immediately before execution and stop at the first error):

#!/bin/sh -ex

PREFIX=/usr/local
 
# Ensure you have write permissions to /usr/local
if [ ! -d "$PREFIX" ]; then
  mkdir $PREFIX
fi
sudo chown -R `whoami` $PREFIX
 
# Downlaod and build dependencies
if [ ! -d "$HOME/Build" ]; then
  mkdir $HOME/Build
fi
cd $HOME/Build
curl -O ftp://ftp.gnu.org/gnu/autoconf/autoconf-2.69.tar.gz
curl -O ftp://ftp.gnu.org/gnu/automake/automake-1.14.tar.gz
curl -O ftp://ftp.gnu.org/gnu/libtool/libtool-2.4.2.tar.gz
 
for i in *.tar.gz; do tar xzvf $i; done

cd autoconf-2.69
./configure --prefix=$PREFIX
make
make install
cd ..

cd automake-1.14
./configure --prefix=$PREFIX
make
make install
cd ..

cd libtool-2.4.2
./configure --prefix=$PREFIX
make
make install
cd ..
Edited by abeloin
Posted (edited)

I have Mavericks

 

It's giving me "Warning: Failed to create the file xxxxx: Permission denied.  The xxxx was for automake, libtool, and autoconf.  That was when I tried the second script you provided.

Edited by Nate8727
Posted (edited)

I have Mavericks

 

It's giving me "Warning: Failed to create the file xxxxx: Permission denied.  The xxxx was for automake, libtool, and autoconf.  That was when I tried the second script you provided.

Ok, I've changed the script from previous post(added sudo in front of make install).

 

Can you try it with the changes?

 

I've reverted the changes, something's wrong in how you execute the script.

 

This command inside the script, gives you ownership to /usr/local.

sudo chown -R `whoami` $PREFIX

So there shouldn't be any permissions issue.

 

This is what I would do to run the one stop shop build script:

  • Copy the script from Mono's Mac page.
  • Open Terminal.
  • At the command prompt, open the vi editor:

    $ vi build.sh

  • Press i, to be able to input text.
  • Right-Click in the Terminal window, select paste.
  • Press esc, to escape input mode.
  • Type :wq  (Save and exit the editor)
  • At the prompt, make build.sh executable:

    $ chmod +x build.sh

  • Execute build.sh:

    $ ./build.sh

  • When asked for a password, type in the user's password.

 

How do you run the script?

Edited by abeloin
Beardyname
Posted

@@abeloin @@Luke As mentioned before i now have a spare machine, What os would you like me to test ?

I'm most at home with ubuntu, but we already know that works well :) (except for the network sharing problem)

Beardyname
Posted

ok, will await his reply :)

Posted

@@abeloin @@Luke As mentioned before i now have a spare machine, What os would you like me to test ?

I'm most at home with ubuntu, but we already know that works well :) (except for the network sharing problem)

 

So far, these are the one I've tested:

  • Fedora 19-20
  • Arch current
  • Mac OSX 10.9

In the previous thread, some users reported problems with:

  • Debian
  • CentOS

So I would recommend you try one of those.

Posted

Abeloin is better to answer on what needs testing

Posted

Ok, I've changed the script from previous post(added sudo in front of make install).

 

Can you try it with the changes?

 

I've reverted the changes, something's wrong in how you execute the script.

 

This command inside the script, gives you ownership to /usr/local.

sudo chown -R `whoami` $PREFIX

So there shouldn't be any permissions issue.

 

This is what I would do to run the one stop shop build script:

  • Copy the script from Mono's Mac page.
  • Open Terminal.
  • At the command prompt, open the vi editor:

    $ vi build.sh

  • Press i, to be able to input text.
  • Right-Click in the Terminal window, select paste.
  • Press esc, to escape input mode.
  • Type :wq  (Save and exit the editor)
  • At the prompt, make build.sh executable:

    $ chmod +x build.sh

  • Execute build.sh:

    $ ./build.sh

  • When asked for a password, type in the user's password.

 

How do you run the script?

When I type $ vi build.sh, I get command not found.

Posted

When I type $ vi build.sh, I get command not found.

 

Are you, by any chance, typing the $ sign with the command? Because the $ sign mean the command prompt, so just type what is after.

Posted (edited)

New build:

 

MediaBrowser.Mono.3.0.5136.18909.tar.gz (Without Mono for Linux and Mac)

 

MediaBrowser.Mono.mkbundlex.X86_64.3.0.5136.18915.tar.gz (Linux x86_64 version with Mono embedded)

 

 

For Linux, mediabrowser can open ISO(Stream detail and web client streaming) via sudo, mount and umount.

 

In order to activate this feature, you need to add these lines via visudo(don't forget to change the username to the one running mediabrowser):

Defaults:jsmith !requiretty
jsmith ALL=(root) NOPASSWD: /bin/mount
jsmith ALL=(root) NOPASSWD: /bin/umount
Edited by abeloin
  • Like 1

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...