Skip to contentSkip to conversation

setuptools: Make options for setup.py more flexible

PATCH New Gary Thomas 1 participant 1 message Apr 13, 2011

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 setuptools: Make options for setup.py more flexible

The setuptools class uses hard-wired options for 'setup.py' during the install step. In particular, not all versions of setup.py support the "--single-version-externally-managed" option. This patch allows for a recipe to easily override these options, while leaving the majority (important) setup options intact.

Signature · 4 lines
------------------------------------------------------------
Gary Thomas                 |  Consulting for the
MLB Associates              |    Embedded world
------------------------------------------------------------

From 0afbe6b9477c207e37009c8ef5aa47b3438640a9 Mon Sep 17 00:00:00 2001
From: Gary Thomas <[email protected]>
Date: Wed, 13 Apr 2011 15:12:57 -0600
Subject: [PATCH] setuptools: Make options for setup.py more flexible

---
 meta/classes/setuptools.bbclass |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)
meta/classes/setuptools.bbclass +2 -1
index ced9509..cf1c224 100644
@@ -2,7 +2,8 @@ inherit distutils
 
 DEPENDS += "python-setuptools-native"
 
+DISTUTILS_INSTALL_OPTS ?= "--single-version-externally-managed "
 DISTUTILS_INSTALL_ARGS = "--root=${D} \
-    --single-version-externally-managed \
+    ${DISTUTILS_INSTALL_OPTS} \
     --prefix=${prefix} \
     --install-data=${datadir}"
Signature · 1 line
1.7.3.4