Page 1 of 1

Build from source on ubuntu

Posted: Sat Jun 16, 2018 5:27 pm
by sfatula
So, I came from Centos for the last 10 years, and, am new to ubuntu (xubuntu specifically). In the build from source wiki page, it says:

"If you have already installed a pre-built package and you have a need to try out a source code change, it would be preferable to use your distribution's build process to build a version that is compatible with the already installed version. There are differences in the placement of files between the downloaded packages and the code you build yourself."

So, that's me. I'd love to use the "distribution's build process" to build a compatible version with no mismatch on file locations, but, have no idea what that is for ubuntu. Obviously, I don't want stuff in /usr/local, but I simply don't know the process on ubuntu. Is there a set of instructions for building a compatible version on ubuntu?

Is it just a matter of configure --prefix=/usr? Or, are there other options to yield the same install directories as the ppa?

Note, I have 2 different use cases. One is to patch mythtv 29, which is what I want to go to the same location as the ppa, and, one is for playing around with some mods, which I would of course install somewhere else, probably /opt as that is empty at present. The /opt one would use a different db and configuration file, I know how to do that, I have run multiple non conflicting versions before. So, my question is only about the patched version to match ppa directories.

Re: Build from source on ubuntu

Posted: Sun Jun 17, 2018 8:47 am
by paulh
The easiest way is probably to get a copy of the packaging repo and use the instructions in the deb directory to create your own packages. That is the same method the official packages use.

You can easily add your own patches to the build process just place your patches in the patches directory and add them to the series file.

Re: Build from source on ubuntu

Posted: Sun Jun 17, 2018 4:47 pm
by sfatula
Ah, thank you, packaging scripts, perfect! Sorry, always done Centos, didn't realize deb would work for ubuntu, just not familiar with the other dists.