mirror of
https://github.com/arsenetar/dupeguru.git
synced 2024-10-31 22:05:58 +00:00
Fixed debian packaging
.so files were included in the source package, which messed up builds under archs that weren't the same as the srcpkg creator (namely, i386 builds).
This commit is contained in:
parent
350b2c64e0
commit
97fcf1ffa8
12
package.py
12
package.py
@ -84,12 +84,16 @@ def package_windows(edition, dev):
|
|||||||
if op.exists('installer_tmp.back.aip'):
|
if op.exists('installer_tmp.back.aip'):
|
||||||
os.remove('installer_tmp.back.aip')
|
os.remove('installer_tmp.back.aip')
|
||||||
|
|
||||||
def copy_source_files(destpath, packages):
|
def copy_files_to_package(destpath, packages, with_so):
|
||||||
|
# when with_so is true, we keep .so files in the package, and otherwise, we don't. We need this
|
||||||
|
# flag because when building debian src pkg, we *don't* want .so files (they're compiled later)
|
||||||
|
# and when we're packaging under Arch, we're packaging a binary package, so we want them.
|
||||||
if op.exists(destpath):
|
if op.exists(destpath):
|
||||||
shutil.rmtree(destpath)
|
shutil.rmtree(destpath)
|
||||||
os.makedirs(destpath)
|
os.makedirs(destpath)
|
||||||
shutil.copy('run.py', op.join(destpath, 'run.py'))
|
shutil.copy('run.py', op.join(destpath, 'run.py'))
|
||||||
copy_packages(packages, destpath)
|
extra_ignores = ['*.so'] if not with_so else None
|
||||||
|
copy_packages(packages, destpath, extra_ignores=extra_ignores)
|
||||||
os.remove(op.join(destpath, 'qt', 'run_template.py')) # It doesn't belong in the package.
|
os.remove(op.join(destpath, 'qt', 'run_template.py')) # It doesn't belong in the package.
|
||||||
shutil.copytree(op.join('build', 'help'), op.join(destpath, 'help'))
|
shutil.copytree(op.join('build', 'help'), op.join(destpath, 'help'))
|
||||||
shutil.copytree(op.join('build', 'locale'), op.join(destpath, 'locale'))
|
shutil.copytree(op.join('build', 'locale'), op.join(destpath, 'locale'))
|
||||||
@ -104,7 +108,7 @@ def package_debian_distribution(edition, distribution):
|
|||||||
packages = ['hscommon', 'core', ed('core_{0}'), 'qtlib', 'qt', 'send2trash', 'jobprogress']
|
packages = ['hscommon', 'core', ed('core_{0}'), 'qtlib', 'qt', 'send2trash', 'jobprogress']
|
||||||
if edition == 'me':
|
if edition == 'me':
|
||||||
packages.append('hsaudiotag')
|
packages.append('hsaudiotag')
|
||||||
copy_source_files(srcpath, packages)
|
copy_files_to_package(srcpath, packages, with_so=False)
|
||||||
if edition == 'pe':
|
if edition == 'pe':
|
||||||
os.mkdir(op.join(destpath, 'modules'))
|
os.mkdir(op.join(destpath, 'modules'))
|
||||||
copy_all(op.join('core_pe', 'modules', '*.*'), op.join(destpath, 'modules'))
|
copy_all(op.join('core_pe', 'modules', '*.*'), op.join(destpath, 'modules'))
|
||||||
@ -145,7 +149,7 @@ def package_arch(edition):
|
|||||||
packages = ['hscommon', 'core', ed('core_{0}'), 'qtlib', 'qt', 'send2trash', 'jobprogress']
|
packages = ['hscommon', 'core', ed('core_{0}'), 'qtlib', 'qt', 'send2trash', 'jobprogress']
|
||||||
if edition == 'me':
|
if edition == 'me':
|
||||||
packages.append('hsaudiotag')
|
packages.append('hsaudiotag')
|
||||||
copy_source_files(srcpath, packages)
|
copy_files_to_package(srcpath, packages, with_so=True)
|
||||||
shutil.copy(op.join('images', ed('dg{}_logo_128.png')), srcpath)
|
shutil.copy(op.join('images', ed('dg{}_logo_128.png')), srcpath)
|
||||||
|
|
||||||
def package_source_tgz(edition):
|
def package_source_tgz(edition):
|
||||||
|
Loading…
Reference in New Issue
Block a user