diff --git a/pymake/pymake.py b/pymake/pymake.py index 22ab447..0c85933 100644 --- a/pymake/pymake.py +++ b/pymake/pymake.py @@ -58,6 +58,7 @@ import shutil import sys import time +from zipfile import ZipFile from .config import __description__ from .pymake_base import main @@ -267,18 +268,32 @@ def compress_targets(self): if self.verbose: print( "Appending files to existing " - + f"zipfile '{zip_pth}'" + + f"zipfile '{pl.Path(zip_pth).resolve()}'" ) + with ZipFile( + zip_pth, + mode="r", + ) as zf: + available_file_paths = zf.namelist() + pop_list = [] + for target in targets: + if target in available_file_paths: + pop_list.append(target) + for target in pop_list: + targets.remove(target) else: if self.verbose: - print(f"Deleting existing zipfile '{zip_pth}'") + print( + "Deleting existing zipfile " + + f"'{pl.Path(zip_pth).resolve()}'" + ) os.remove(zip_pth) # print a message describing the zip process if self.verbose: print( f"Compressing files in '{appdir}' " - + f"directory to zip file '{zip_pth}'" + + f"directory to zip file '{pl.Path(zip_pth).resolve()}'" ) for idx, target in enumerate(targets): print( diff --git a/pymake/utils/_compiler_switches.py b/pymake/utils/_compiler_switches.py index 21c7ad7..975d862 100644 --- a/pymake/utils/_compiler_switches.py +++ b/pymake/utils/_compiler_switches.py @@ -339,9 +339,6 @@ def _get_fortran_flags( "fpe:0", "traceback", "nologo", - "Qdiag-disable:7416", - "Qdiag-disable:7025", - "Qdiag-disable:5268", ] if debug: flags += ["debug:full", "Zi"]