From ec527fee02977a0c79328f630b950ab3d90f4db9 Mon Sep 17 00:00:00 2001 From: Michael Greminger Date: Wed, 6 Jan 2021 20:48:04 -0600 Subject: [PATCH] Fix build error for zlib (#1060) --- packages/zlib/meta.yaml | 2 +- pyodide_build/buildpkg.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/zlib/meta.yaml b/packages/zlib/meta.yaml index 8d8a61382..6277b330d 100644 --- a/packages/zlib/meta.yaml +++ b/packages/zlib/meta.yaml @@ -9,5 +9,5 @@ source: build: library: true script: | - CFLAGS="-fPIC" emconfigure ./configure --prefix=`cwd` + CFLAGS="-fPIC" emconfigure ./configure --prefix=$PWD emmake make install -j ${PYODIDE_JOBS:-3} diff --git a/pyodide_build/buildpkg.py b/pyodide_build/buildpkg.py index 4ebb85ccd..8706edcc7 100755 --- a/pyodide_build/buildpkg.py +++ b/pyodide_build/buildpkg.py @@ -173,7 +173,7 @@ def compile(path: Path, srcpath: Path, pkg: Dict[str, Any], args): site_packages_dir = srcpath / "install" / "lib" / "python3.8" / "site-packages" pkgdir = path.parent.resolve() env = {"SITEPACKAGES": str(site_packages_dir), "PKGDIR": str(pkgdir)} - subprocess.run(["bash", "-c", post], env=env, check=True) + subprocess.run(["bash", "-ce", post], env=env, check=True) with open(srcpath / ".built", "wb") as fd: fd.write(b"\n") @@ -222,7 +222,7 @@ def run_script(buildpath: Path, srcpath: Path, pkg: Dict[str, Any]): orig_path = Path.cwd() os.chdir(srcpath) try: - subprocess.run(["bash", "-c", pkg["build"]["script"]], check=True) + subprocess.run(["bash", "-ce", pkg["build"]["script"]], check=True) finally: os.chdir(orig_path)