Skip to content

Commit 2c0e57e

Browse files
committed
WL14669: Commercial wheel packages
1 parent 3665c6e commit 2c0e57e

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

cpydist/bdist_wheel.py

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Copyright (c) 2020, Oracle and/or its affiliates.
1+
# Copyright (c) 2020, 2021, Oracle and/or its affiliates.
22
#
33
# This program is free software; you can redistribute it and/or modify
44
# it under the terms of the GNU General Public License, version 2.0, as
@@ -36,7 +36,10 @@
3636
class DistWheel(bdist_wheel, BaseCommand):
3737
"""Create a Wheel distribution."""
3838

39-
user_options = bdist_wheel.user_options + BaseCommand.user_options
39+
user_options = bdist_wheel.user_options + BaseCommand.user_options + [
40+
("metadata-license=", None, "metadata license text"),
41+
]
42+
metadata_license = ""
4043

4144
def initialize_options(self):
4245
"""Initialize the options."""
@@ -52,5 +55,7 @@ def finalize_options(self):
5255

5356
def run(self):
5457
"""Run the command."""
58+
if self.metadata_license:
59+
self.distribution.metadata.license = self.metadata_license
5560
bdist_wheel.run(self)
5661
self.remove_temp()

0 commit comments

Comments
 (0)