def install(self): with xyz.chdir(self.config['build_dir']), xyz.umask(0o22): self.cmd('make', 'install_root={install_dir_abs}', 'install') self.rmtree('{eprefix_dir}', 'bin') self.rmtree('{eprefix_dir}', 'lib', 'gconv') self.rmtree('{eprefix_dir}', 'sbin') self.rmtree('{prefix_dir}', 'share', 'zoneinfo') self.rmtree('{prefix_dir}', 'share', 'i18n') self.rmtree('{prefix_dir}', 'share', 'locale') self.rmtree('{prefix_dir}', 'etc') self.strip_info_dir() for f in ['libc.so', 'libpthread.so']: fixup_so_file(self.j('{eprefix_dir}', 'lib', f))
def install(self): with xyz.chdir(self.config['build_dir']), xyz.umask(0o022): self.cmd('make', 'DESTDIR={install_dir_abs}', 'bininstall', 'inclinstall', 'libainstall', 'libinstall') for root, _, files in os.walk(self.config['install_dir']): for f in files: if not (f.endswith('.pyc') or f.endswith('.pyo')): continue with open(os.path.join(root, f), 'r+b') as outf: outf.seek(4) outf.write(struct.pack('I', xyz.BASE_TIME)) # Remove lib2to3 self.rmtree('{install_dir}', 'noprefix', 'lib', 'python3.3', 'lib2to3') for f in ['2to3', 'idle3', 'pydoc3', 'pyvenv']: bin_fn = self.j('{install_dir}', 'noprefix', '{host}', 'bin', f) os.unlink(bin_fn)