Update Mono via CentOS - mono

Hello i have CentOS and im trying my damnedest to update Mono i have version 1.2.4 at the moment some how, and im trying to compile something via xbuild and it isn't working im thinking because im using to old a version of mono.
Please BEFORE you link me ANY guide, if it links to the ftp.novell directory it no longer works, that directory is all scrapped. So i dont even know where to get a proper tarball for it now because on their site it only shows opensuse and such? Not CentOS like there used to be.
Can anyone help me with this :\

What version of CentOS are you using? 4?
The instructions below were tested on CentOS 5.9. They will also work fine on the latest CentOS version (6.4 as of this writing) and I imagine they would work with older versions as well.
Head over to /usr/src as root
su
cd /usr/src
Ensure GCC and friends are installed (to build the Mono source code)
yum install gcc gcc-c++ bison
Grab and unpack the Mono source code
wget http://download.mono-project.com/sources/mono/mono-3.0.7.tar.bz2
tar -xvjf mono-3.0.7.tar.bz2
Build and install Mono
cd mono-3.0.7
./configure --prefix=/usr
make && make install
Verify that you have a working Mono installation with mono --version and mcs --version
Build the GDI+ compatibility layer (required for System.Drawing)
yum install glib2-devel libX11-devel pixman-devel fontconfig-devel freetype-devel libexif-devel libjpeg-devel glib2-devel libtif-devel libpng-devel giflib-devel
cd /usr/src
wget http://download.mono-project.com/sources/libgdiplus/libgdiplus-2.10.tar.bz2
tar -xvjf libgdiplus-2.10.tar.bz2

Related

How do I install an older ethtool version on a machine?

I need to test if some firmware is compatible with older ethtool versions.
The machine I am using currently have ethtool version 5.16, but I need to install ethtool version 5.13
I got the compressed file from https://mirrors.edge.kernel.org/pub/software/network/ethtool/ and have used tar -zxvf https... to extract the files. This extracts a directory with the contents shown below:
After reading the INSTALL file, I ran ./configure but it gave me the following error: configure: error: The pkg-config script could not be found or is too old. Make sure it is in your PATH or set the PKG_CONFIG environment variable to the full path to pkg-config
This meant that I could not run make or make install and thus am stuck.
After speaking to colleagues, the solution was found:
apt-get install -y pkg-config. Thereafter the following package was also needed: apt-get install -y libmnl-dev
Simple installed it with ./configure, make and make install and saw the ethtool version was as desired.

Installing janus-gateway error on CentOS7

I want to install janus-gateway on CentOS7.
I read the following document and tried installation.
https://github.com/meetecho/janus-gateway/blob/master/README.md
git clone https://github.com/meetecho/janus-gateway.git
cd janus-gateway
sh autogen.sh
./configure --prefix=/opt/janus
However, configuring janus-gateway will cause an error. The error is as follows.
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... no
checking for pkg-config... /bin/pkg-config
checking pkg-config is at least version 0.9.0... yes
checking for JANUS... no
configure: error: Package requirements (
glib-2.0 >= 2.34
libconfig
nice
jansson >= 2.5
libssl >= 1.0.1
libcrypto
) were not met:
No package 'nice' found
Consider adjusting the PKG_CONFIG_PATH environment variable if you
installed software in a non-standard prefix.
Alternatively, you may set the environment variables JANUS_CFLAGS
and JANUS_LIBS to avoid the need to call pkg-config.
See the pkg-config man page for more details.
I installed libnice(libnice-0.1.3-4.el7.x86_64) in the following way.
yum install libnice
How can I solve it?
Thank you.
try this and rebuild
echo "export PKG_CONFIG_PATH=/usr/lib/pkgconfig" >> ~/.bashrc
source ~/.bashrc
Disclaimer: I am using Ubuntu 18.04 when testing this.
If you are using Ubuntu system and trying to install Janus and running this code
./configure --prefix=/opt/janus
And then getting this error: No package 'nice' found
Make sure you have been installation of the nice from aptitude.
sudo install aptitude
aptitude install libmicrohttpd-dev libjansson-dev \
libssl-dev libsrtp-dev libsofia-sip-ua-dev libglib2.0-dev \
libopus-dev libogg-dev libcurl4-openssl-dev liblua5.3-dev \
libconfig-dev pkg-config gengetopt libtool automake
For some reason installation of nice using the answer from Frank, Ahmet or Zallfire doesn't work in Ubuntu. It has to be installed using aptitude.
You should download libnice source code to install.
https://gitlab.freedesktop.org/libnice/libnice
You need the development libnice.
yum install libnice-devel

installing Mod_Mono and Xsp4 on CentOS 6.3

I've gotten Mono 3.0.1 installed, but I'm running into tons of dependency issues trying to install Mod_Mono and Xsp4, Has anyone gotten this to work? If so what were some of the steps you had to take? Is there a central location for this?
Thank you so much for taking the time to read my question and happy coding!
Enviroment:
Centos 6.3 basic install
Apache/2.2.15
Installation steps:
#Install required software
yum -y install httpd httpd-devel make glib2-devel libpng-devel libjpeg-devel
giflib-devel libtiff-devel libX11-devel gcc* fontconfig-devel bison gettext bzip2
libtool automake autoconf wget unzip
directory we will be installing mono in
mkdir -p /opt/mono
cd /tmp
Download & extract source
wget http://download.mono-project.com/sources/mono/mono-2.10.2.tar.bz2
wget http://download.mono-project.com/sources/xsp/xsp-2.10.2.tar.bz2
wget http://download.mono-project.com/sources/mod_mono/mod_mono-2.10.tar.bz2
wget http://download.mono-project.com/sources/libgdiplus/libgdiplus-2.10.tar.bz2
tar -xjf mono-2.10.2.tar.bz2
tar -xjf xsp-2.10.2.tar.bz2
tar -xjf mod_mono-2.10.tar.bz2
tar -xjf libgdiplus-2.10.tar.bz2
compile and install libgdiplus
cd libgdiplus-2.10
./configure --prefix=/opt/mono
make ; make install
compile and install mono
cd ../mono-2.10.2
./configure --prefix=/opt/mono --with-libgdiplus=/opt/mono
make ; make install
Set enviroment vars(make sure to also modify ~/.bash_profile)
export PATH=$PATH:/opt/mono/bin
export PKG_CONFIG_PATH=/opt/mono/lib/pkgconfig
compile and install xsp
cd ../xsp-2.10.2
./configure --prefix=/opt/mono
make ; make install
compile and install mod_mono
cd ../mod_mono-2.10
./configure --prefix=/opt/mono --with-mono-prefix=/opt/mono
make ; make install
mv /etc/httpd/conf/mod_mono.conf /etc/httpd/conf.d/
Currently working with mono and xsp4:
[root]# cat /etc/redhat-release
CentOS release 6.7 (Final)
[root]# mono --version
Mono JIT compiler version 4.5.0
[root]# xsp4 --version
xsp4.exe 2.10.2.0
Chazt3n solution is ok, except I had to do some changes to make it work:
I changed the mono version from 4.0 to 4.5 in file: /opt/mono/bin/mod-mono-server4
I ran this command: cp /opt/mono/lib/mono/4.0/xsp4.exe /opt/mono/lib/mono/4.5/
Works well now, thanks.

Installing latest mono on Centos 6

I am new to Linux (literally new- used it a couple of times) and I tried to install mono via yum; but I have gotten an outdated version that don't support .NET 4
How can I install mono 2.10.8?
Well, this is what I came up with and it worked for me:
based on this article:
$yum install bison gettext glib2 freetype fontconfig libpng libpng-devel libX11 libX11-devel glib2-devel libgdi* libexif glibc-devel urw-fonts java unzip gcc gcc-c++ automake autoconf libtool make bzip2 wget
$cd /usr/local/src
$wget http://download.mono-project.com/sources/mono/mono-3.0.1.tar.bz2
$tar jxf mono-3.0.1.tar.bz2
$cd mono-3.0.1
$./configure --prefix=/opt/mono
$make && make install
Then I downloaded the MonoDevelop IDE and compiled my program using Mono framework.
Then in Centos I called my program:
/opt/mono/bin/mono /root/MyFolder/MyProgramDir/myProgram.exe "$#"
Here's a Hello World Console Application on CentOS 6.5, compiled with the Mono "mcs" command and run with the Mono "mono" command. The first section was taken directly from Andrew's answer. +1 for Andrew! I added some additional steps because I am using the command line, not a Linux GUI.
yum install bison gettext glib2 freetype fontconfig libpng libpng-devel libX11 libX11-devel glib2-devel libgdi* libexif glibc-devel urw-fonts java unzip gcc gcc-c++ automake autoconf libtool make bzip2 wget
cd /usr/local/src
wget http://download.mono-project.com/sources/mono/mono-3.0.1.tar.bz2
tar jxf mono-3.0.1.tar.bz2
cd mono-3.0.1
./configure --prefix=/opt/mono
make && make install
Adding mono bin to "PATH" environment variable:
[root#localhost bin]# echo $PATH
/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/root/bin
[root#localhost bin]# export PATH=/opt/mono/bin:$PATH
[root#localhost bin]# echo $PATH
/opt/mono/bin:/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/root/bin
[root#localhost bin]#
Program.cs:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace HelloWorld
{
class Program
{
static void Main(string[] args)
{
Console.WriteLine("Hello Mars!");
}
}
}
Compile and Run:
Elon Musk's retirement party is planned for December 16, 2025!
Compile *.sln file:
Under CentOS 5 it's probably best to compile Mono from source to get a recent version.
It just so happens I have already written a complete set of instructions for doing this here (If you'll pardon me linking to one of my own pages):
http://wiki.phonicuk.com/Installing-Mono-in-CentOS-5-x.ashx
Edit:
The above link is dead, best instructions are now at http://www.mono-project.com/docs/compiling-mono/compiling-from-git/
Mono packaging has always been in need of Love in the Fedora/RedHat world, so go figure if you're using CentOS.
Mono's Download page lists OpenSUSE, Debian and Ubuntu: http://www.go-mono.com/mono-downloads/download.html
I would use one of those options instead if you want to do something serious, otherwise you're on your own.
(Novell used to offer pre-built packages from CentOS here, but all links there seem broken now. Furthermore, these seemed to be the "enterprisey" version, and anyway if you're going CentOS instead of RH you're already avoiding that sub-world I'm guessing...)

Cross compile mono for arm

Has anyone successfully cross-compiled mono for ARM under Linux without scratchbox or qemu?
(maybe with distcc or some cross-compiler toolchain)
I managed to cross compile mono(2.0, 2.4, 2.6, 2.8, 2.10.1) with Scratchbox 2 installed on a Ubuntu machine using CodeSourcery Lite tool chain. I used the article from the Mono project page.
First compile it on the native machine
./configure
$ make
$ make install DESTDIR=path
Then in sb2:
[sbox-ARMEL: ~] > ./configure --disable-mcs-build
[sbox-ARMEL: ~] > make
[sbox-ARMEL: ~] > make install DESTDIR=path
I use this for configuration
./configure --enable-minimal=profiler,debug,logging,soft_debug --with-tls=--with-tls=__thread --with-monotouch=no --without-mcs-docs --disable-mono-debugger CFLAGS=-DARM_FPU_NONE --disable-mcs-build
I tried and tried and tried with scratchbox2 last night.. Ran into some problem.. Ended up just compiling on arm, went fine! took 30 minutes!
CFLAGS=-DARM_FPU_VFP_HARD HardFloat
CFLAGS=-DARM_FPU_VFP_NONE SoftFloat
Compile mono on PC
sudo make install `directory like /tmptree etc`
move all these files from /tmptree over to / etc on your arm device.
./autogen.sh --disable-mcs-build
make CFLAGS=-DARM_FPU_VFP_HARD
sudo make install
sudo ldconfig
Mono Hard Float Patch
Tried doing Hard Float with mono 3.0.3.. it said it didn't support it yet.