1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38
|
import os
import Params
import Common
def build(bld):
env = bld.env()
if env['xmms_icon']:
obj = bld.create_obj('cc', 'objects')
obj.target = 'xmms_icon'
obj.source = 'xmms2.rc'
obj.install_var = 0
images = """
xmms2-16.png
xmms2-32.png
xmms2-48.png
xmms2-128.png
xmms2.svg
xmms2-black-on-white.svg
xmms2-white-on-black.svg
""".split()
for image in images:
Common.install_files("PIXMAP_DIR", "", image)
def configure(conf):
if Params.g_options.pixmapdir is not None:
conf.env["PIXMAP_DIR"] = Params.g_options.pixmapdir
else:
conf.env["PIXMAP_DIR"] = os.path.join(conf.env["PREFIX"], "share", "pixmaps")
if not conf.env["PIXMAP_DIR"]:
return False
return True
def set_options(opt):
opt.add_option("--with-pixmap-dir", type="string", dest="pixmapdir")
|