Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

I try to build a universal wheel, but it rolls away

I run:

python3 setup.py bdist_wheel --universal

It says it's making all sorts of stuff, but then the resulting directory (build/bdist.macosx-10.10-x86_64) is empty. Where did my wheel roll away to?t

Edit

I now see that I'm trying to look at the temp output. When I specify -d, sure enough, there's a wheel in the designated location. Does -d have a default? Has my wheel been parked under my nose all along?

running bdist_wheel
running build
running build_py
running egg_info
writing dependency_links to rosapi_launcher.egg-info/dependency_links.txt
writing top-level names to rosapi_launcher.egg-info/top_level.txt
writing rosapi_launcher.egg-info/PKG-INFO
writing requirements to rosapi_launcher.egg-info/requires.txt
reading manifest file 'rosapi_launcher.egg-info/SOURCES.txt'
writing manifest file 'rosapi_launcher.egg-info/SOURCES.txt'
installing to build/bdist.macosx-10.10-x86_64/wheel
running install
running install_lib
creating build/bdist.macosx-10.10-x86_64/wheel
creating build/bdist.macosx-10.10-x86_64/wheel/launcher
copying build/lib/launcher/__init__.py -> build/bdist.macosx-10.10-x86_64/wheel/launcher
copying build/lib/launcher/containers.py -> build/bdist.macosx-10.10-x86_64/wheel/launcher
copying build/lib/launcher/launcher.py -> build/bdist.macosx-10.10-x86_64/wheel/launcher
copying build/lib/launcher/prop_file.py -> build/bdist.macosx-10.10-x86_64/wheel/launcher
copying build/lib/launcher/properties.py -> build/bdist.macosx-10.10-x86_64/wheel/launcher
copying build/lib/launcher/snapshots.py -> build/bdist.macosx-10.10-x86_64/wheel/launcher
copying build/lib/launcher/utils.py -> build/bdist.macosx-10.10-x86_64/wheel/launcher
running install_egg_info
Copying rosapi_launcher.egg-info to build/bdist.macosx-10.10-x86_64/wheel/rosapi_launcher-0.0.1-py3.4.egg-info
running install_scripts
creating build/bdist.macosx-10.10-x86_64/wheel/rosapi_launcher-0.0.1.dist-info/WHEEL

My setup.py is:

from setuptools import setup
import io
import os
import launcher

here = os.path.abspath(os.path.dirname(__file__))

# noinspection PyPackageRequirements
def read(*filenames, **kwargs):
    encoding = kwargs.get('encoding', 'utf-8')
    sep = kwargs.get('sep', '\n')
    buf = []
    for filename in filenames:
        with io.open(filename, encoding=encoding) as f:
            buf.append(f.read())
    return sep.join(buf)

long_description = read('README.txt', 'CHANGES.txt')

setup(
    name='rosapi-launcher',
    version=launcher.__version__,
    install_requires=['pyaml',
                      'boto3'
                      ],
    description='RosAPI launcher',
    long_description=long_description,
    packages=['launcher'],
    include_package_data=True,
    platforms='any',
    classifiers = [
        'Programming Language :: Python',
        'Natural Language :: English'
    ]
)
like image 631
bmargulies Avatar asked Oct 28 '15 13:10

bmargulies


People also ask

What does Setup py bdist_wheel do?

python setup.py bdist_wheel internally runs python setup.py install which in turn runs python setup.py build which compiles/builds the project into a temporary location inside build/ directory and then installs compiled project into another temporary location inside build/ directory.

What is a pure Python wheel?

What Is a Python Wheel? A Python . whl file is essentially a ZIP ( . zip ) archive with a specially crafted filename that tells installers what Python versions and platforms the wheel will support. A wheel is a type of built distribution.

What is a wheel Python package?

A wheel is a built package that can be installed without needing to go through the “build” process. Installing wheels is substantially faster for the end user than installing from a source distribution. If your project is pure Python then you'll be creating a “Pure Python Wheel” (see section below).

What's a wheel file?

A WHL (Wheel) file is a distribution package file saved in Python's wheel format. It is a standard format installation of Python distributions and contains all the files and metadata required for installation. The WHL file also contains information about the Python versions and platforms supported by this wheel file.


1 Answers

The answer I found is this:

python3 setup.py bdist_wheel

doesn't write the results anyplace I can find them.

python3 setup.py bdist_wheel -d .

writes it, well, right here.

like image 97
bmargulies Avatar answered Sep 19 '22 17:09

bmargulies