[mythtv] [mythtv-users] setting up an env

Roger Siddons dizygotheca at ntlworld.com
Wed Mar 23 22:38:10 UTC 2016


On 23/03/16 04:05, Dan Littlejohn wrote:
>
> Thanks for the suggestion.  I downloaded QT Creator and have it setup,
> but if you have a tip or there is a tutorial somewhere on how to create
> a myth project in it that would be appreciated.  I will likely take a
> guess at it with the "new project" options or to poke around, but I
> thought I would just ask.  Not sure if the qmake file comment was a hint.
>

I don't know of any tutorials.

The projects already exist in git - QtCreator will use the same ones as 
the official build script, which makes things easy.

You'll find that each library and app has a *.pro file alongside its 
sources. The top-level Makefile runs qmake on each one to generate the 
sub-project Makefile, which is then built. QtCreator will do the same 
when you open one of the *.pro files. (Theoretically qmake is run in a 
different environment but I've never had any problems, so I've never 
investigated.)

So:

1. configure, build and install as usual, in order to build FFmpeg etc 
and install themes etc.

2. From QtC open mythfrontend.pro and mythbackend.pro. The first time it 
will 'configure' it. I just use a Debug build with *.o files in the 
source dir (to be compatible with the build script). Use defaults for 
everything else.

3. You should then see the sources and be able to build. QtC should 
automatically detect your compiler, debugger and Qt libs ("kits") but 
the settings allow you to fix/adjust them.

4. Installing conventionally is problematic because QtC needs sudo 
privileges. You could use ssh-askpass in a deployment step or blat your 
permissions. I skip deployment by symbolically linking the relevant 
apps/libs in /usr/local back to the source tree so that I can just 
build, then run.

5. Select each project and run/debug it. It helps to have multiple monitors.

Be wary of project dependencies. Myth project files don't usually 
specify them (the top-level Makefile dictates them). So if you modify 
libmythui code, re-building mythfrontend won't automatically re-link 
against it. If you hunt around the Projects tab, you'll find a 
Dependencies tab where you can set them.



More information about the mythtv-dev mailing list