|
1 # |
|
2 # CDDL HEADER START |
|
3 # |
|
4 # The contents of this file are subject to the terms of the |
|
5 # Common Development and Distribution License (the "License"). |
|
6 # You may not use this file except in compliance with the License. |
|
7 # |
|
8 # You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE |
|
9 # or http://www.opensolaris.org/os/licensing. |
|
10 # See the License for the specific language governing permissions |
|
11 # and limitations under the License. |
|
12 # |
|
13 # When distributing Covered Code, include this CDDL HEADER in each |
|
14 # file and include the License file at usr/src/OPENSOLARIS.LICENSE. |
|
15 # If applicable, add the following below this CDDL HEADER, with the |
|
16 # fields enclosed by brackets "[]" replaced with your own identifying |
|
17 # information: Portions Copyright [yyyy] [name of copyright owner] |
|
18 # |
|
19 # CDDL HEADER END |
|
20 # |
|
21 |
|
22 # |
|
23 # Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved. |
|
24 # |
|
25 |
|
26 # This set of transforms helps us take a package that's parameterized on a |
|
27 # platform's versions and emit a package that conditionally depends on those |
|
28 # versioned packages, predicated on the platform version packages being |
|
29 # present. |
|
30 # |
|
31 # For instance, for a package "mako-generic", we want to create a package |
|
32 # "mako", which brings in "mako-26" if "python-26" is present, and "mako-27" if |
|
33 # "python-27" is present. |
|
34 # |
|
35 # We do this by grabbing just the set actions from "mako-generic", and emitting |
|
36 # those conditional depend actions. We require that the parameterized package |
|
37 # name end in "-###" (typically by setting a pkgmogrify variable to "###"), |
|
38 # which we also remove here. This works in conjunction with a set of rules in |
|
39 # make-rules/ips.mk which create and use another transform file that actually |
|
40 # emit the conditional dependencies. |
|
41 |
|
42 <transform file dir link hardlink license user group driver legacy signature -> drop> |
|
43 <transform depend -> default nodrop false> |
|
44 <transform depend nodrop=false -> drop> |
|
45 <transform set name=pkg.fmri value=(?:pkg:/)?(.+)-###@(.*) -> \ |
|
46 edit value -### ""> |
|
47 <transform depend nodrop=true -> delete nodrop true> |