Jump to: navigation, search

Brief introduction to SVN

30 bytes added, 10:00, 28 October 2012
Option 2: use the build code
==== Option 2: use the build code ====
Here, we use the code build in <code>trunk/build</code> directory to run Gramps. For compiled programs this is the only way, but for Gramps nothing is compiled. It is not bad however to keep your code separated from your execution, as deleting the build directory is easy. After a code change in your source, you then need to run however <code>python</code> again to update the build direcotry. To run Gramps from build, do
cd trunk/build/lib.linux-x86_64$(uname -m)-2.7/
python -c 'from gramps.grampsapp import main; main()'
PYTHONPATH=~/gramps-trunk/build/lib.linux-x86_64$(uname -m)-2.7/ python -c 'from gramps.grampsapp import main; main()'
So, more general:
PYTHONPATH=~/gramps-trunk/build/lib.linux-x86_64$(uname -m)-2.7/:/usr/local/lib/python2.7/site-packages/ LD_LIBRARY_PATH=/usr/local/lib python -c 'from gramps.grampsapp import main; main()'
If the build directory is in your PYTHONPATH, you can also just execute the module. So this will work too:
cd ~/gramps-trunk/build/lib.linux-x86_64$(uname -m)-2.7/gramps PYTHONPATH=~/gramps-trunk/build/lib.linux-x86_64$(uname -m)-2.7/ python
or again more generally
PYTHONPATH=~/gramps-trunk/build/lib.linux-x86_64$(uname -m)-2.7/:/usr/local/lib/python2.7/site-packages/ LD_LIBRARY_PATH=/usr/local/lib python
'''Note''': at At the time of writing, only the last, so using works, as not all imports in Gramps have been converted to relative or absolute imports. This conversion will be finished by end of 2012 however.

Navigation menu