greg@358: import os,sys greg@358: from distutils.core import setup greg@358: greg@358: greg@358: install_dir=os.path.join("LOLITech","CanFestival-3") greg@358: greg@358: data_files=[] greg@358: os.getcwd() greg@358: os.chdir(os.getcwd()) greg@358: greg@358: def generate(base_dir): greg@358: listfile=[] greg@358: if base_dir == "": greg@358: directory = "." greg@358: else: greg@358: directory = base_dir greg@358: data_files.append((os.path.join(install_dir, base_dir), listfile)) greg@358: greg@358: for element in os.listdir(directory): greg@358: element_path=os.path.join(base_dir, element) greg@358: if os.path.isdir(element_path): greg@358: generate(element_path) greg@358: elif os.path.isfile(element_path): greg@358: ext_element=os.path.splitext(element) greg@358: if ext_element[1] != ".o" and ext_element[1] != ".pyc": greg@358: listfile.append(element_path) greg@358: greg@358: generate("") greg@358: greg@358: greg@358: setup(name='CanFestival-3', # Name of the executable greg@358: version='0.1', # Version greg@358: description='Open-Source CanOpen Stack', #description greg@358: author='Edouard Tisserant, Laurent Bessard', greg@358: author_email='edouard.tisserant.lolitech.fr, laurent.bessard@lolitech.fr', greg@358: url='http://www.canfestival.org', greg@358: license='GPL', greg@358: scripts=['objdictedit_postinst.py'], greg@358: data_files=data_files, # Add files to install greg@358: )