def prepare_env(self, env): """ Insert *PREFIX*, *BINDIR* and *LIBDIR* values into ``env`` :type env: :py:class:`waflib.ConfigSet.ConfigSet` :param env: a ConfigSet, usually ``conf.env`` """ if not env.PREFIX: if Options.options.prefix or Utils.is_win32: env.PREFIX = os.path.abspath( os.path.expanduser(Options.options.prefix)) else: env.PREFIX = '' if not env.BINDIR: if Options.options.bindir: env.BINDIR = os.path.abspath( os.path.expanduser(Options.options.bindir)) else: env.BINDIR = Utils.subst_vars('${PREFIX}/bin', env) if not env.LIBDIR: if Options.options.libdir: env.LIBDIR = os.path.abspath( os.path.expanduser(Options.options.libdir)) else: env.LIBDIR = Utils.subst_vars( '${PREFIX}/lib%s' % Utils.lib64(), env)
def prepare_env(self,env): if not env.PREFIX: if Options.options.prefix or Utils.is_win32: env.PREFIX=os.path.abspath(os.path.expanduser(Options.options.prefix)) else: env.PREFIX='' if not env.BINDIR: if Options.options.bindir: env.BINDIR=os.path.abspath(os.path.expanduser(Options.options.bindir)) else: env.BINDIR=Utils.subst_vars('${PREFIX}/bin',env) if not env.LIBDIR: if Options.options.libdir: env.LIBDIR=os.path.abspath(os.path.expanduser(Options.options.libdir)) else: env.LIBDIR=Utils.subst_vars('${PREFIX}/lib%s'%Utils.lib64(),env)
def prepare_env(self,env): if not env.PREFIX: if Options.options.prefix or Utils.is_win32: env.PREFIX=Options.options.prefix else: env.PREFIX='/' if not env.BINDIR: if Options.options.bindir: env.BINDIR=Options.options.bindir else: env.BINDIR=Utils.subst_vars('${PREFIX}/bin',env) if not env.LIBDIR: if Options.options.libdir: env.LIBDIR=Options.options.libdir else: env.LIBDIR=Utils.subst_vars('${PREFIX}/lib%s'%Utils.lib64(),env)
def prepare_env(self, env): """ Insert *PREFIX*, *BINDIR* and *LIBDIR* values into ``env`` :type env: :py:class:`waflib.ConfigSet.ConfigSet` :param env: a ConfigSet, usually ``conf.env`` """ if not env.PREFIX: if Options.options.prefix or Utils.is_win32: env.PREFIX = Utils.sane_path(Options.options.prefix) else: env.PREFIX = '' if not env.BINDIR: if Options.options.bindir: env.BINDIR = Utils.sane_path(Options.options.bindir) else: env.BINDIR = Utils.subst_vars('${PREFIX}/bin', env) if not env.LIBDIR: if Options.options.libdir: env.LIBDIR = Utils.sane_path(Options.options.libdir) else: env.LIBDIR = Utils.subst_vars('${PREFIX}/lib%s' % Utils.lib64(), env)
def prepare_env(self, env): """ Insert *PREFIX*, *BINDIR* and *LIBDIR* values into ``env`` :type env: :py:class:`waflib.ConfigSet.ConfigSet` :param env: a ConfigSet, usually ``conf.env`` """ if not env.PREFIX: if Options.options.prefix or Utils.is_win32: env.PREFIX = Options.options.prefix else: env.PREFIX = "/" if not env.BINDIR: if Options.options.bindir: env.BINDIR = Options.options.bindir else: env.BINDIR = Utils.subst_vars("${PREFIX}/bin", env) if not env.LIBDIR: if Options.options.libdir: env.LIBDIR = Options.options.libdir else: env.LIBDIR = Utils.subst_vars("${PREFIX}/lib%s" % Utils.lib64(), env)
sharedstatedir, architecture-independent variable data, ${PREFIX}/com localstatedir, variable data, ${PREFIX}/var libdir, object code libraries, ${EXEC_PREFIX}/lib%s includedir, header files, ${PREFIX}/include oldincludedir, header files for non-GCC compilers, /usr/include datarootdir, architecture-independent data root, ${PREFIX}/share datadir, architecture-independent data, ${DATAROOTDIR} infodir, GNU "info" documentation, ${DATAROOTDIR}/info localedir, locale-dependent data, ${DATAROOTDIR}/locale mandir, manual pages, ${DATAROOTDIR}/man docdir, documentation root, ${DATAROOTDIR}/doc/${PACKAGE} htmldir, HTML documentation, ${DOCDIR} dvidir, DVI documentation, ${DOCDIR} pdfdir, PDF documentation, ${DOCDIR} psdir, PostScript documentation, ${DOCDIR} ''' % Utils.lib64() _options = [x.split(', ') for x in gnuopts.splitlines() if x] def configure(conf): def get_param(varname, default): return getattr(Options.options, varname, '') or default env = conf.env env.LIBDIR = env.BINDIR = [] env.EXEC_PREFIX = get_param('EXEC_PREFIX', env.PREFIX) env.PACKAGE = getattr(Context.g_module, 'APPNAME', None) or env.PACKAGE complete = False iter = 0 while not complete and iter < len(_options) + 1: iter += 1
sharedstatedir, architecture-independent variable data, ${PREFIX}/com localstatedir, variable data, ${PREFIX}/var libdir, object code libraries, ${EXEC_PREFIX}/lib%s includedir, header files, ${PREFIX}/include oldincludedir, header files for non-GCC compilers, /usr/include datarootdir, architecture-independent data root, ${PREFIX}/share datadir, architecture-independent data, ${DATAROOTDIR} infodir, GNU "info" documentation, ${DATAROOTDIR}/info localedir, locale-dependent data, ${DATAROOTDIR}/locale mandir, manual pages, ${DATAROOTDIR}/man docdir, documentation root, ${DATAROOTDIR}/doc/${PACKAGE} htmldir, HTML documentation, ${DOCDIR} dvidir, DVI documentation, ${DOCDIR} pdfdir, PDF documentation, ${DOCDIR} psdir, PostScript documentation, ${DOCDIR} '''%Utils.lib64() _options=[x.split(', ')for x in gnuopts.splitlines()if x] def configure(conf): def get_param(varname,default): return getattr(Options.options,varname,'')or default env=conf.env env.LIBDIR=env.BINDIR=[] env.EXEC_PREFIX=get_param('EXEC_PREFIX',env.PREFIX) env.PACKAGE=getattr(Context.g_module,'APPNAME',None)or env.PACKAGE complete=False iter=0 while not complete and iter<len(_options)+1: iter+=1 complete=True for name,help,default in _options: name=name.upper()
sharedstatedir, architecture-independent variable data, ${PREFIX}/com localstatedir, variable data, ${PREFIX}/var libdir, object code libraries, ${EXEC_PREFIX}/lib%s includedir, header files, ${PREFIX}/include oldincludedir, header files for non-GCC compilers, /usr/include datarootdir, architecture-independent data root, ${PREFIX}/share datadir, architecture-independent data, ${DATAROOTDIR} infodir, GNU "info" documentation, ${DATAROOTDIR}/info localedir, locale-dependent data, ${DATAROOTDIR}/locale mandir, manual pages, ${DATAROOTDIR}/man docdir, documentation root, ${DATAROOTDIR}/doc/${PACKAGE} htmldir, HTML documentation, ${DOCDIR} dvidir, DVI documentation, ${DOCDIR} pdfdir, PDF documentation, ${DOCDIR} psdir, PostScript documentation, ${DOCDIR} """ % Utils.lib64()) _options = [x.split(", ") for x in gnuopts.splitlines() if x] def configure(conf): """ Reads the command-line options to set lots of variables in *conf.env*. The variables BINDIR and LIBDIR will be overwritten. """ def get_param(varname, default): return getattr(Options.options, varname, "") or default env = conf.env env.LIBDIR = env.BINDIR = [] env.EXEC_PREFIX = get_param("EXEC_PREFIX", env.PREFIX)