diff --git a/CHANGELOG.md b/CHANGELOG.md index abc0694..d4c5e4b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,7 +2,7 @@ ## v0.2.6 - Fixed a bug causing source only packages to fail to install -- Added a bug relating to `manylinux2014_i686` wheels +- Fixed a bug relating to `manylinux2014_i686` wheels ## v0.2.5 - Added support for `manylinux2014` spec diff --git a/README.md b/README.md index 092cad3..d97da67 100644 --- a/README.md +++ b/README.md @@ -32,22 +32,22 @@ and [Pep 518 (pyproject.toml)](https://www.python.org/dev/peps/pep-0518/). ## Installation - **Windows** - Download and run -[this installer](https://github.com/David-OConnor/pyflow/releases/download/0.2.5/pyflow-0.2.5-x86_64.msi). +[this installer](https://github.com/David-OConnor/pyflow/releases/download/0.2.6/pyflow-0.2.6-x86_64.msi). Or, if you have [Scoop](https://scoop.sh) installed, run `scoop install pyflow`. - **Ubuntu, or another Os that uses Snap** - Run `snap install pyflow --classic`. - **Ubuntu or Debian without Snap** - Download and run -[this deb](https://github.com/David-OConnor/pyflow/releases/download/0.2.5/pyflow_0.2.5_amd64.deb). +[this deb](https://github.com/David-OConnor/pyflow/releases/download/0.2.6/pyflow_0.2.6_amd64.deb). - **Fedora, CentOs, RedHat, or older versions of SUSE** - Download and run -[this rpm](https://github.com/David-OConnor/pyflow/releases/download/0.2.5/pyflow-0.2.5.x86_64.rpm). +[this rpm](https://github.com/David-OConnor/pyflow/releases/download/0.2.6/pyflow-0.2.6.x86_64.rpm). - **A different Linux distro** - Download this -[standalone binary](https://github.com/David-OConnor/pyflow/releases/download/0.2.5/pyflow) +[standalone binary](https://github.com/David-OConnor/pyflow/releases/download/0.2.6/pyflow) and place it somewhere accessible by the PATH. For example, `/usr/bin`. -- **Mac** - Download this [zipped Mac binary](https://github.com/David-OConnor/pyflow/releases/download/0.2.4/pyflow_mac_0.2.4.zip) +- **Mac** - Download this [zipped Mac binary](https://github.com/David-OConnor/pyflow/releases/download/0.2.6/pyflow_mac_0.2.6.zip) , ance place the file in it somewhere accessible by the PATH. (Props to @russeldavis for building this) - **With Pip** - Run `pip install pyflow`. The linux install using this method is much larger than @@ -190,7 +190,7 @@ Example contents: [tool.pyflow] py_version = "3.7" name = "runcible" -version = "0.2.5" +version = "0.2.6" authors = ["John Hackworth "] @@ -373,7 +373,7 @@ In order to build and publish your project, additional info is needed in [tool.pyflow] name = "everythingkiller" py_version = "3.6" -version = "0.2.5" +version = "0.2.6" authors = ["Fraa Erasmas "] description = "Small, but packs a punch!" homepage = "https://everything.math" @@ -396,7 +396,7 @@ activate = "jeejah:activate" [tool.pyflow.dependencies] numpy = "^1.16.4" -manimlib = "0.2.5" +manimlib = "0.2.6" ipython = {version = "^7.7.0", extras=["qtconsole"]} diff --git a/snapcraft.yaml b/snapcraft.yaml index f96fc6b..f16c8b2 100644 --- a/snapcraft.yaml +++ b/snapcraft.yaml @@ -1,5 +1,5 @@ name: pyflow -version: 0.2.5 +version: 0.2.6 license: MIT # todo: This appears to cause the `snapcraft` command to fail. summary: A Python installation and dependency manager. description: | diff --git a/src/install.rs b/src/install.rs index 03e271a..8d1a7e6 100644 --- a/src/install.rs +++ b/src/install.rs @@ -335,54 +335,42 @@ pub fn download_and_install_package( // todo moves, only copies. Figure out how to do a normal move, // todo, to speed this up. - let extracted_parent; - let bin_path; - let python; + let extracted_parent = paths.lib.join(folder_name); + + replace_distutils(&extracted_parent.join("setup.py")); #[cfg(target_os = "windows")] - { - let py_name = "python"; - extracted_parent = paths.lib.join(folder_name); - bin_path = &paths.bin; - python = bin_path.join(py_name); - } + Command::new(paths.bin.join("python")) + .current_dir(&extracted_parent) + .args(&["setup.py", "bdist_wheel"]) + .output() + .expect(&format!( + "Problem running setup.py bdist_wheel in folder: {:?}. Py path: {:?}", + &extracted_parent, + paths.bin.join("python") + )); + + // The Linux and Mac builds appear to be unable to build wheels due to + // missing the ctypes library; revert to system python. #[cfg(target_os = "linux")] - { - let py_name = "python3"; - extracted_parent = match fs::canonicalize(paths.lib.join(folder_name)) { - Ok(path) => path, - Err(error) => panic!("Problem converting path to absolute path: {:?}", error), - }; - bin_path = fs::canonicalize(&paths.bin); - python = match bin_path { - Ok(path) => path.join(py_name), - Err(error) => panic!("Problem converting path to absolute path: {:?}", error), - }; - } + Command::new("python3") + .current_dir(&extracted_parent) + .args(&["setup.py", "bdist_wheel"]) + .output() + .expect(&format!( + "Problem running setup.py bdist_wheel in folder: {:?}. Py path: {:?}", + &extracted_parent, + paths.bin.join("python") + )); #[cfg(target_os = "macos")] - { - let py_name = "python3"; - extracted_parent = match fs::canonicalize(paths.lib.join(folder_name)) { - Ok(path) => path, - Err(error) => panic!("Problem converting path to absolute path: {:?}", error), - }; - bin_path = fs::canonicalize(&paths.bin); - python = match bin_path { - Ok(path) => path.join(py_name), - Err(error) => panic!("Problem converting path to absolute path: {:?}", error), - }; - } - - replace_distutils(&extracted_parent.join("setup.py")); - - Command::new(&python) + Command::new("python3") .current_dir(&extracted_parent) .args(&["setup.py", "bdist_wheel"]) .output() - // .expect(&format!("Problem running setup.py bdist_wheel in folder: {:?}. Py path: {:?}", &extracted_parent, paths.bin.join("python"))); .expect(&format!( "Problem running setup.py bdist_wheel in folder: {:?}. Py path: {:?}", - &extracted_parent, &python + &extracted_parent, + paths.bin.join("python") )); let dist_path = &extracted_parent.join("dist");