Can't override libpng15 with newer install - linux

I've downloaded and installed libpng from http://www.libpng.org/pub/png/libpng.html, which is version 1.6.16, following their simple instructions:
./configure
./make check
sudo ./make install
It runs with everything successful, and says it's been installed. However, after doing this I still read:
$ libpng-config --cflags --ldflags
-I~/anaconda/include/libpng15
-L~/anaconda/lib -lpng15
This is breaking other builds and installs, which sometimes detect 15 while requiring 16. How can I fix this?
Fedora Linux 20 x 64

If you want libpng16 to go in your $HOME/ then, in your libpng directory, run
./configure --prefix=$HOME
./make
./make install
This will install png*.h in $HOME/include/, libpng-config in $HOME/bin/,
and the library itself in $HOME/lib/.
If you want to put it in some other directory where you don't have write permission, the final command is
sudo ./make install

Related

./configure error while installing conky

I've downloaded conky from GitHub and when I try to use the ./configure command, I get this following error :
bash: ./configure: No such file or directory
I opened my terminal in the Src folder and tried this command. What am I missing?
This is the screenshot of the terminal and the downloaded conky folder
I see CMakeLists.txt and doubled checked, per the documentation use cmake
1.10 and later versions
Conky 2 will use cmake instead of autotools which means you won't need autoconf and automake anymore but you'll need cmake.
autoconf and automake (and autogen) are what generally drive "configure".
You will need the tolua library (Ref.), which can be installed for Linux with apt-get install libtolua-dev libtolua++5.1-dev. You also need the following development packages if you keep the default cmake configuration: apt-get install libx11-dev libxft-dev libxdamage-dev libncurses5-dev libxinerama-dev.
Then, building conky will work like this:
$ mkdir build
$ cd build
$ ccmake ..
# this will launch a curses-based UI where you can configure
# everything, when you are ready you can build as usual:
$ make # This will compile conky in the `src` subdirectory
$ make install

How do I install protobuf 2.5 on Arch Linux for compiling hadoop 2.6.0 using maven 3.3.1?

Am looking for installing protobuf 2.5.0 on Arch Linux, so that protoc-2.5.0.so is installed on the OS, so that I can go ahead with building hadoop 2.6.0 from source and make my life easy! :)
BTW, protobuf 2.6.0 does not compile when hadoop is built from source I have tried that as well. Ubuntu 14.04 comes with protoc 2.5.0. I DO NOT want to use Ubuntu.
Please check the screenshot first (there is no protobuf 2.5.0), since the problem lies there.. I guess
am getting the following exception, I am aware that protoc is not installed in arch linux currently.
[ERROR] Failed to execute goal
org.apache.hadoop:hadoop-maven-plugins:2.6.0:protoc (compile-protoc)
on project hadoop-common:
org.apache.maven.plugin.MojoExecutionException: 'protoc --version' did
not return a version -> [Help 1]
Please help me out, since, I have spent 4 hours every day from two days, with no luck.
Compiling Google's protobuf is pretty easy.
I originally found out how to do it on this blog post while compiling hadoop myself.
But here is my version:
$ cd /usr/local/src/
$ wget https://github.com/google/protobuf/releases/download/v2.5.0/protobuf-2.5.0.tar.gz
$ tar xvf protobuf-2.5.0.tar.gz
$ cd protobuf-2.5.0
$ ./autogen.sh
$ ./configure --prefix=/usr
$ make
$ make install
$ protoc --version
Install protobuf for java
$ cd java
$ mvn install
$ mvn package
You should be good to go.
To enable you to install different versions of protobuf, install stow
then change ./configure --prefix=/usr to ./configure --prefix=/usr/local/stow/protobuf-2.5.0
Then link protobuf into your system with stow:
$ cd /usr/local/stow
$ stow protobuf-2.5.0
Note: stow uses /usr/local/bin by default. Make sure thats in your $PATH
To unlink that version of protobuf,
$ stow -D protobuf-2.5.0
Hope this helped.
I wonder why the above answer got downvoted,even I had to perform few more steps (in addition to the accepted answer by Rudker) to get protobuf 2.5 installed on Ubuntu Xenial.
Leaving the additional steps here for everyone's benefit:
apt-get install autoconf in response to the error : ./autogen.sh: autoreconf: not found for command : ./autogen.sh
apt-get install libtool in response to the error : autoreconf: libtoolize is needed because this package uses Libtool for command : ./autogen.sh
apt install g++ in response to the error : configure: error: C++ preprocessor "/lib/cpp" fails sanity check for command : ./configure --prefix=/usr
An easier but not future proof solution (for future queries) would be to head over to Arch Linux Archives: http://seblu.net/a/archive/packages/p/protobuf/
Uninstall the newer version of protobuf and install the downloaded package via pacman -U protobuf-2.5.x..
Though whenever you upgrade the Arch Linux packages via pacman you'd need to ensure you are doing: sudo pacman -Syu --ignore protobuf
I currently don't have enough reputation to comment, so I add a answer here to update the top voted answer.
Since protobuf move to different repo, the new wget command should be:
wget https://github.com/protocolbuffers/protobuf/releases/download/v2.5.0/protobuf-2.5.0.tar.gz
And in order to run ./autogen.sh, you may need install these:
sudo yum install libtool automake autoconf
For OSX prerequisites, try SunitaKoppar's answer (I don't know why the down-votes).
Thanks for the steps. Just wanted to add that, to get autogen.sh to work, I had to install the below packages (commands for mac below):
brew install gtk
brew install autoconf
brew install automake

Building Node.js gives error: Node.js configure error: No acceptable C compiler found

While trying to use a Ubuntu 14.04 system to cross compile Node.js v0.10.30 for ARM (Raspberry Pi B), I'm experiencing an error message:
Node.js configure error: No acceptable C compiler found!
Please make sure you have a C compiler installed on your system and/or
consider adjusting the CC environment variable if you installed
it in a non-standard prefix.
How should I fix this problem and compile node.js successfully?
Commands used on a fresh Ubuntu 14.04 x64 installation:
sudo apt-get install gcc g++ git
git clone git://github.com/joyent/node.git
cd node
git checkout v0.10.30-release
export AR=arm-unknown-linux-gnueabi-ar
export CC=arm-unknown-linux-gnueabi-gcc
export CXX=arm-unknown-linux-gnueabi-g++
export LINK=arm-unknown-linux-gnueabi-g++
./configure --without-snapshot --dest-cpu=arm --dest-os=linux
I ran into this error as well after trying to run ./configure in my node directory. Here are the commands I ran to get node working for me on an ubuntu server:
cd .. (back to directory where node directory was created)
sudo apt-get install build-essential
cd node/
./configure
make (For relative newbies, like me, this step took awhile to complete, so don't freak out too much if that happens for you)
sudo make install
Then try running your node file from it's directory. As a small aside, I also got the following error when doing that:
Error: ENOENT, stat '/home/ubuntu/local'
at Error (native)
To fix that, I just ran: sudo npm install -g npm
I was required to use: sudo apt-get install npm -g -y in my WSL, VSCode Windows terminal.

How can I (is it possible to) install mysql workbench locally?

I want to install a mysql workbench binary locally on my linux machine because I don't have sudo rights. I did this when I installed python using --prefix. Can this also be done with mysql workbench?
Yes, you can, provided that you are willing to compile Workbench from sources. You are advised however that you'll need sudo rights to install its compilation dependencies. Here are the steps:
Download Workbench's sources from the official download site. You should download the version tagged "Generic Linux (Architecture Independent), Compressed TAR Archive".
Uncompress the downloaded source file. From the linux terminal:
$ tar -zxvf mysql-workbench-whatever.tar.gz
Move to the directory with Workbench's source code:
cd mysql-workbench-whatever
Read the INSTALL file located in this directory to find out the required packages that you would need to install in order to compile Workbench. For Ubuntu here's the command to install them:
$ sudo apt-get install build-essential autoconf automake libtool libzip-dev libxml2-dev libsigc++-2.0-dev libglade2-dev libgtkmm-2.4-dev libglu1-mesa-dev libgl1-mesa-glx mesa-common-dev libmysqlclient15-dev uuid-dev liblua5.1-dev libpixman-1-dev libpcre3-dev libgnome2-dev libgtk2.0-dev libpango1.0-dev libcairo2-dev python-dev libboost-dev
Run autogen.sh with the path to where you want Workbench installed:
$ ./autogen.sh --prefix=~/bin/wb52
(The above command will get your Workbench's binaries in the directory bin/wb52 within your home directory once compiled). Just change the destination dir to whatever you like.
Compile and install MySQL Workbench:
$ make install
This will take some time (maybe half an hour depending on your system). If you have more than one CPU core available you should use, for instance:
$ make -j3 install
and this will use three cores for compilation (adjust the number of cores to whatever you find reasonable for your system).
Once compiled you can run Workbench's executable that will be located inside a bin directory within the path you set in step 5.
Have a lot of fun!

Need a 64 bit binary for JZMQ, or bulding instructions for a non MSVC environment (cygwin/mingw)?

I'm looking for a binary source for jzmq. Although I've been able to use mingw to build the zmq basic libraries and dlls, I can't use the same technique to compile jzmq myself.
I found this page:
http://www.mail-archive.com/zeromq-dev#lists.zeromq.org/msg06477.html
But it starts with the words: Run ./autogen.sh on linux (to avoid autotools on mingw32)
All I really need is a 64 bit binary for now, but can follow instructions that don't requirem me to track down a completely different computer/operating system to get started...
This worked for me on 64-bit ubuntu 11.04.
1) Configure the environment
sudo apt-get install git
sudo apt-get install libtool
sudo apt-get install autoconf
sudo apt-get install automake
2) Set JAVA_HOME to location of JDK
Add "JAVA_HOME=/usr/lib/jvm/java-6-openjdk" and "export JAVA_HOME" to /etc/bash.bashrc
Add ":/usr/lib/jvm/java-6-openjdk/bin/jre/bin" at the end of the PATH setting in /etc/environment
3) Build the jar
cd $HOME
git clone https://github.com/zeromq/jzmq.git
cd jzmq
sudo ./autogen.sh
make
sudo make install
4) You should now have zmq.jar in $HOME/jzmq/src
Note: that this build process and the use of zmq.jar relies on having the zmq core already installed, so its probably worthwhile checking that have a whole bunch of libzmq files in /usr/local/lib.

Resources