install GLFW3 on openSuse linux through YaST - linux

I am in the process of moving my programming from mac to the linux distrubution OpenSuse Leap.
therefor i want to install the c++ libraries which i used on my mac on my new machine, this is done through YaST (yet another setup tool)'s software manager, through which i have succesfully been able to install multiple libraries.
I am having problems installing GLFW3, i would prefer to install the latest version (3.2), but at the very least the version must be greater than 3
under YaST's software manager i can however only find something named GLFW2 - however it claims to be version 2.7.6-3.2-x86_64 and to have the build time Fri 11 Sep 2015, and i am not sure if i should regard the fact that it is quite recently build and that the current version (3.2) is in the supposed version of this as a proof that it is indeed GLFW version 3.2 - with some backward compatibillity, or if i should regard the fact that the library is named GLFW2 as a proof that is is not GLFW3.
I have attempted to make and compile dummy programs (which are totally empty programs which tries to include GLFW3) but they fail to compile, claiming that library GLFW3 doesn't exist, but i can not know wether or not they fail because GLFW3 is not installed, or because it is installed but I don't know how to include it.
My question is therefor: if i install the library named GLFW2 through YaST, can i then safely assume that i have GLFW 3.2 installed and that i therefor only need learn to include and compile the library; if no, does that mean i can't install a version of GLFW higher than 3

I have just the same problem today using OpenSUSE, and ended up installing GLFW3.2 from source. In order to get the glfw compiled from sources on OpenSUSE, I also needed to install the following dependencies (using zypper install package_name_to_install):
1) libXrandr-devel
2) libXinerama-devel
3) libXcursor-devel
After the dependencies are installed, I just followed standard cmake flow:
1) git clone git#github.com:glfw/glfw.git
2) cd glfw && mkdir build && cd build && cmake ..
3) make
4) sudo make install

Related

Is it possible to run a newer version of cloc (or any package) onto an older version of ubuntu?

I have to work with ubuntu 14.04, but I need to use cloc 1.92. The highest cloc version via package update for Ubuntu is 1.6.
https://packages.ubuntu.com/search?keywords=cloc
I did a wget https://github.com/AlDanial/cloc/releases/download/v1.92/cloc-1.92.tar.gz to download this package to my machine, but it's not showing up in the package list when I do dpkg --list. I'm not sure how to make the cloc 1.92 folder run the same way that 1.6 does on my VM, or if it's even possible to do so.
The git page for cloc explains all related aspects, and skimming over it, in the Why use cloc? section says that the "program is self-contained, only download and run it". This program is developed in Perl 5, present in all Ubuntu distros. You can check that with the command perl --version.
Simply extract the file cloc from the tar.gz and copy it in an appropiate directory, for example /usr/local/bin, and confirm it has the proper executable rights with the command chmod a+rx /usr/local/bin/cloc.
Caveat: cloc claims to use only standard Perl modules. If your installed Perl doesn't have all needed, you will have to install them using CPAN.
Edit: See the comments by Knud Larsen for manual installing as Ubuntu mantainers do.
In this case, as the program is run by an interpreter, it wasn't needed to compile it, but in general programs/libraries in source form could to be compiled and installed independently from the apt/dkpg package management, but could need other libraries/programs to operate. The mantainer of the distro ensures this dependencies are installed together with the desired package. If we want to compile/install manually, then also we have to compile/install all requirements of the program if they aren't there already.
In other cases, the additional required software for the package could be already installed in some older versions, but it is used by other installed programs that could fail if we install new versions. That is the main problem when updating software in older distros: We need to investigate and resolve any conflicts manually.
So, the second answer is: Yes, we can update software in older versions of Ubuntu, but could be impractical to do so.

Plone Unified Installer missing Python

I'm trying to install plone 4.3.4 on a SLES 11 SP3 64bit server via the Unified Installer. I've fullfilled all the dependencies listed in the readme.txt, but when I try to get the installer running with the command sudo ./install.sh --password=******* standalone I get the error message: which: no python2.7 in (/usr/bin:/bin:/usr/sbin:/sbin) Unable to find python2.7 on system exec path.
I find that rather strange as in the description of the unified installer it is said "The new Zope/Plone install will use its own copy of Python, and the Python installed by the Unified Installer will not replace your system's copy of Python. You may optionally use your system (or some other) Python, and the Unified Installer will use it without modifying it or your site libraries." on the Plone-Website.
So - what am I doing wrong???
I've just tried adding the parameter --build-python but had to find out that the libxml2-devel and libxslt-devel libraries that are available for SLES-11-SP-3 are sadly not up-to-date enough 2.7.6 instead of 2.7.8 and 1.1.24 instead of 1.1.26 respectively. So no joy there either. :-(
Is there any way to install the current version of plone on SLES 11 SP3 64bit?
Kate
The installer command:
./install.sh standalone --build-python --static-lxml=yes
worked perfectly for me. The installer downloaded and built the Python and libxml2/libxslt components necessary to remedy the terribly out-of-date (and vulnerable) versions included with sles11sp3.
System packages needed for the build were:
gcc-c++
make
readline-devel
libjpeg-devel
zlib-devel
patch
libopenssl-devel
libexpat-devel
man
All installed via zypper.
I'd advise not using sudo for the install. If you want to, you'll need to create the plone_daemon and plone_buildout users and the plone_group group in advance due to oddities in SUSE's adduser implementation.

how to compile apache,mysql and php in linux

I have never used Linux OS. Want to know how we can start compiling Apache,Mysql and php in Linux and is it necessary to configure it.
I tried doing it by using cd/user/scr/httpd_2.0.09
Do we need to downloads the set up from google
Do yourself a favour and don't try to compile your own webserver etc. ;)
Aside from the fact that it's a lot of work to set up the tools for compiling, resolve dependencies, and debug possible errors, you will have to do the same procedure with every tiny update – instead of simply getting a new version via your package manager.
If you use a common distribution, install the packages required for the so-called LAMP stack, and configure them properly. That will be hard enough for starters.
If you're using Ubuntu, have a look here: https://help.ubuntu.com/community/ApacheMySQLPHP
Actually installing binaries from repositories is less painful than compiling, but if you really want so, you may install Gentoo or other source-based distributive. I've simply described compilation of MySQL 5.5 in my blog.
To compile packages on Debian based systems you need to install build-essential and cmake package (and maybe some other *-dev packages, which appears to be missing during source configure).
For example to compile MySQL 5.5 it is enough to run:
cmake . #yep, with dot. Will prepare your source according to your system
make
make install #will install compiled binaries to system

Cassandra cpp driver on Windows/RHEL

I am trying to build cassandra cpp driver on rhel 6.4.So the requirement is to make this work on windows/RHEL with Visual Studio/gcc compiler.So what it takes to make this driver work on RHEL/windows without any additional packaging being required?
CentOS 6.4 (minimal)
1. Get the dependencies
sudo yum install gcc-c++ glibc glibc-devel boost boost-devel openssl openssl-devel libssh2 libssh2-devel zlib zlib-devel make cmake git
2. Clone the C++ driver for Cassandra from its repository
git clone https://github.com/datastax/cpp-driver.git
3. Build
cd cpp-driver
cmake -G "Unix Makefiles"
make
That's it. Most likely, the driver will be packaged sooner or later and building it will not be necessary (unless you want to hack with the dev version).
Windows
1. Get the dependencies
Install Zlib, OpenSSL, libSSH2, Boost and CMake (in this order). LibSSH2 and Boost must be compiled with Visual Studio (these processes are beyond the scope of this answer, but usually go off smoothly). Remeber the directories where you put them.
2. Download the C++ driver for Cassandra
You can clone the repository (if you have Git client at hand) or download the zipped source.
3. Configure and build
Run CMake GUI, select your toolchain, and point to the cpp-driver directory ('Where is the source code'). Hit 'Configure'. You will see some red entries that need to be set manually. Most likely these are locations of the freshly installed libraries. Set them and 'Configure' until no more red fields are present. Then hit 'Generate' and you will get an MSVS solution ready to be imported and built.
Caveats
At the time of this writing the C++ driver for Cassandra undergoes intense development. Therefore, the process described above may require appropriate tuning.
Another thing worth remembering is that (at the time of this writing) the C++ driver has only C++ interface. To preserve ABI compatibility it is advised to stick to one toolchain when building and using the driver.

Upgrading a package whose newest version is not still in the distribution repository [closed]

Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 9 years ago.
Improve this question
I need to upgrade libpng from version 1.2 to 1.5. I need to do so because of this: libpng warning: Application built with libpng-1.2.26 but running with 1.5.2. I am using Lubuntu 11.10 and in the Canonical repositories libnpg 1.5 is not still released although at Debian ones there are testing packages (http://packages.debian.org/search?keywords=libpng) that at first they would fit to me. I added the Debian repositories to Synaptec and I was able to install libpng15, but those packages do not replace libpng12, son when it comes to compile some source code the IDE uses libpng12 instead of libpng15.
To try to solve this I downloaded the libpng15 deb package, uncompressed it and changed the Replaces, Conflicts and Provides tags of the control file with the libpng15 text. Then, I executed the modified deb, but what I only got was a GDebi error and a general system failure because (I think) libpng12 was uninstalled with no replacement and Lubuntu heavily depends on it, which forced me to reinstall Lubuntu because the computer did not boot again in Linux. Yes, this solution is not the neatest way I think.
So, is there any way to upgrade a package and replace the old version whose newer version exists but it is not still in the distribution repository? I found ubuntu repository for libpng and How to upgrade a package in linux that was built from source?. Although not very determinant so far.
I have not found out how to upgrade and replace a package whose newer version is not still in the distribution repository. But I have realized that if some library X relies on a given version of other library Y, there is no way to change the version of that dependence unless you make some change onto the source code of X, that is it, the library X is recompiled to point to the desired version (usually with the help of some configuration tag). Even though some trick could be done as by modifying the symlink of the library Y to point to the newer version. Then, the compiler will complain and ask for the old version.
Maybe this looks obvious now. But if the software that has to be recompiled requires many hours, has unresolved dependences or gives built errors you will try to avoid the compilation no matter if you are violating thermodynamics laws.
So in my case I had to recompile Qt and by using the -system-libpng configuration tag Qt understood it had to use system libpng libraries, not in-built ones. And after 8 hours of compiling I got a successfully built which solved this libpng problem.
Thanks everyone for the comments and suggests.
For all of the trouble you're going through, it might be easier to simply compile from source, and install to /usr/local (instead of /usr, as debs do). I've done this for several library dependencies for programs I've compiled (with make build systems) without any trouble. However, it sounds like the program(s) you're compiling are having trouble choosing the right version of the package. In my opinion, that is the real issue. Having multiple versions of a library installed simultaneously is supported, but perhaps not by apt in the case of mixing Debian and Ubuntu repos.
When you compile your program, use gcc -lpng15 instead of -lpng. According to the gcc info manual, an option of -lname causes the linker to look for libname.a in the lib folders. On my system (Ubuntu 10.04), libpng.a is a symlink to libpng12.a. This is why your program is choosing the wrong lib.
Try adding this ppa: https://launchpad.net/~linaro-maintainers/+archive/overlay. It contains libpng1.5 for Oneiric.
You can install it by running
sudo add-apt-repository ppa:linaro-maintainers/overlay
sudo apt-get update
sudo apt-get install libpng1.5
To properly link against libpng15, you will also need to install libpng15-dev.

Resources