Now I’ll start by saying that what I’m trying to do may not be possible on Windows, so this isn’t a Windows v Linux rant. It is however a rant about how dysfunctional this thing we simplistically call ‘Linux’ is.
A couple of days ago I found something that I thought would be interesting. Doesn’t matter what, but the person who had it on their site included a ‘recipe’ for how to do it…in Linux. They didn’t state what flavour or version they had used, but I thought, I’m sure it will work. Two days later and probably 10-12 hours invested in it I’m not so sure. So what’s the problem…well it’s that each version of Linux has it’s own, often incompatible, ways of doing things. Plus there are many different development languages/techniques used that further complicate matters.
For example, there’s yum (Red Hat/Fedora/Centos) and apt-get (Ubuntu). Similar but not the same. RH/F/C call development libraries ‘-devel’ and Ubuntu calls them '-dev’. Then there’s Python’s PIP, GIT, Perl’s CPAN and there’s autogen.sh, bootstrap.sh, ./configure, make, cmake, etc. Each step you take brings a different way of doing things.
I started the quest out by trying the recipe on a Centos 6 box. A bit old, but it would be a last job for it before it was destined for decommissioning. I need to install dozen ‘apps’ to get this recipe working. Of course, if you want to install app ‘A’ you find it’s got dependencies of X, Y and Z. Then Z has it’s own dependencies, P, Q and R. If you’re lucky these are all available as RPMs. I’m not lucky, so it’s find the source, plus all the associate libraries in source form, plus the relevant development tools and install all of those, with their own dependencies. Part way through I hit a screeching halt. A ‘make’ run has complained that things are missing and says I need to upgrade the gcc/g++ compilers. Now I’ve been there before and completely screwed up a server by messing with the compilers and, more importantly, the C libraries. Once bitten, twice shy. I’m not going there.
So start again. Flatten the server. Rebuild with the latest Centos 7 build. That should be better. Repeat all the stuff above…but at least this time some of the stuff is familiar so I know where to look. Different OS version so different errors and some different things to find. Did I also forget to mention the hours spent watching huge long compilations scroll by waiting so I can do the next step. This time I hit a similar problem to the one above. Not C/C++ this time, but Python related. It needs a newer version of it and a lot of the underlying Centos utilities are based on Python so an upgrade past the official version is likely to break things I need, e.g. yum.
So start again. Flatten the server. Rebuild with the latest version of Ubuntu. This should be better. Repeat everything, but it’s getting far more familiar now. I’m not sure if it will work this time. I’m still waiting for compilations to finish and I’ve not yet reached the steps that failed in the previous tries. I’m also less familiar with Ubuntu so I may mess things up by replacing something that it uses internally.
Linux…Grrrrrrrrrrrr!!!