Blob Blame History Raw
From 7adf1f898cb1890164ec39ff74ea52a5413d6016 Mon Sep 17 00:00:00 2001
From: Jan Zeleny <jzeleny@redhat.com>
Date: Fri, 12 Dec 2014 13:16:16 +0100
Subject: [PATCH] Use vendor in package names if required

---
 macros.scl | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/macros.scl b/macros.scl
index aaa7a809ab33f266f915554275a4566abf3505e3..8a8ffab756f937c0fc1857cab5fccc1428259c7d 100644
--- a/macros.scl
+++ b/macros.scl
@@ -41,10 +41,12 @@ package or when debugging this package.
 %scl_package() %{expand:%{!?_root_prefix:
 %global pkg_name		%1
 %global scl_name		%{scl}
-%global scl_runtime		%{scl}-runtime
 %global scl_basedir		/opt
 %{!?scl_vendor:			%global scl_vendor rh}
 %{!?_scl_prefix:		%global _scl_prefix %{scl_basedir}/%{scl_vendor}}
+%global scl_meta_name		%{?scl_vendor_in_name:%{scl_vendor}-}%{scl}
+%global scl_full_prefix		%{scl_meta_name}-
+%global scl_runtime		%{scl_meta_name}-runtime
 %global _scl_scripts		%{_scl_prefix}/%{scl}
 %global _scl_root		%{_scl_prefix}/%{scl}/root
 %global _root_prefix		%{_prefix}
@@ -81,7 +83,7 @@ package or when debugging this package.
 %global _docdir			%{_datadir}/doc
 %global _defaultdocdir		%{_docdir}
 }
-%global scl_pkg_name		%{scl}-%{pkg_name}
+%global scl_pkg_name		%{scl_full_prefix}%{pkg_name}
 %scl_debug
 %global __os_install_post %{expand:
     /usr/lib/rpm/brp-scl-compress %{_scl_root}
-- 
1.9.3