discuss-gnuradio
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Discuss-gnuradio] GRC request


From: Josh Blum
Subject: Re: [Discuss-gnuradio] GRC request
Date: Wed, 27 May 2009 10:50:22 -0700
User-agent: Thunderbird 2.0.0.21 (X11/20090409)

Im not a huge fan of the hard-coded directories, i think it might be kind of nice to have a data_dir_prefix that would default to whatever automake/autoconf says, but also takes queues from an environment variable...so

I know this is possible, but I am a bit confused about why. Woulnt it be easier to modify $(datadir) via ./configure --datadir=xxx, and use the whole automake system for gnuradio? What are you attempting to do, making a distributable package?

-Josh

grc/freedesktop/grc_setup_freedesktop.in
grc/src/platforms/base/Constants.py.in
grc/src/platforms/python/Constants.py.in

I can think of two possible solutions:

1) Put a switch at the top of each of these files along the lines of:

import os
DATA_DIR = os.getenv ("GRC_DATADIR")
if not DATA_DIR:
  DATA_DIR = @datadir@



and because we like one-liners :-)

import os
DATA_DIR = os.environ.get("GRC_DATADIR", @datadir@)




reply via email to

[Prev in Thread] Current Thread [Next in Thread]