6549N/A# spec file for package SUNWgnome-foo-bar 6549N/A# includes module(s): gnome-foo, libgnomebar 8108N/A# Copyright 2006 Sun Microsystems, Inc. 6549N/A# This file and all modifications and additions to the pristine 6549N/A# package are under the same license as the package itself. 6549N/A############################################################################ 6549N/A# The example in this template builds 2 GNOME components, gnome-foo and 6549N/A# libgnomebar and packages them together into a Solaris package called 6549N/A# SUNWgnome-foo-bar that is split by file system boundaries [Solaris rule], 8108N/A# so it has a "subpackage" called SUNWgnome-foo-bar-root. 6549N/A############################################################################ 6549N/A# default locations and extra info needed for building Solaris pkgs. 6549N/A# See the file itself for more details, it's located in this directory. 6549N/A# Note that this line should appear before any %use lines so that 6549N/A# Declare that this spec file will use information (tags, scriptlets, etc.) 6549N/A# spec file for future reference. 6549N/A# This is the name (PKG) of the Solaris package. 6549N/A# This will become the one-line description of the Solaris package 8108N/A# This is the version of the Solaris package that has little to do with 6549N/A# the version of the gnome components included, since several gnome 6549N/A# components may be packaged together. 8108N/A# In case of non-GNOME components, however, we prefer to use the 8108N/A# tarball version number of the component. 8108N/A# Note: package version numbers must be numeric. Things like 1.0.5beta 6549N/A# The base directory of the Solaris package (normally /usr, / or 6549N/A# You need to define the basedir for each package and subpackage. 6549N/A# For now, the basedir of "-root" packages should be /, everything 13472N/A# Use the copyright-extractor script to create a copyright file. 6549N/A# Same as with linux specs. Note that in this case this will be 6549N/A# There's a list of packages that all GNOME packages depend on 6549N/A# These are really just the Solaris core, devices, system libs. 6549N/A# We could include them in all spec files but it's nicer and shorter 6549N/A# to %include them from a common file. 6549N/A# These are the additional [to the default ones %include'd above] 6549N/A# dependencies of this package. Please don't use version checks in 6549N/A# Solaris dependencies. They are not usually used and not properly 6549N/A# implemented in the build scripts either. 8108N/A# Try to identify the dependencies of the package the best you can. 8108N/A# Missing dependencies may cause broken installs, but unnecessary deps 8108N/A# These lines define what package need to be installed at build time. 8108N/A# This defines the "-root" subpackage, i.e. SUNWgnome-foo-bar-root. 6549N/A# Solaris packages must be split by usual filesystem boundaries, so 8108N/A# root filesystem (e.g. /etc) files must be separated from the rest of 8108N/A# the package. According to Solaris packaging rules, development and 8108N/A# runtime files must also be separated.. 6549N/A# The naming convention used in GNOME is this: 8108N/A# SUNWgnome-package-name: the main package, binaries, libs, 8108N/A# files in %{_datadir} needed at runtime 6549N/A# SUNWgnome-package-name-root: /etc, /var stuff 8108N/A# SUNWgnome-package-name-devel: header files, pkgconfig files, 8108N/A# binaries only needed for development, 8108N/A# developer docs, man pages, aclocal 6549N/A# SUNWgnome-package-name-devel-root: any root files that are only needed 8108N/A# for development (rarely needed) 6549N/A# start with a clean source directory. 6549N/A# prepare the sources of gnome-foo in the %name-%version subdir. 6549N/A# The same thing again with libgnomebar. 13472N/A# Set any environment variables that may be needed. 6549N/A# Note that the linux spec files usually set CFLAGS to $RPM_OPT_FLAGS 6549N/A# before running configure, so if you want to add something to the 6549N/A# CFLAGS defined in the linux spec file, the above trick will do 6549N/A# (i.e. set RPM_OPT_FLAGS to be the same as the CFLAGS you want) 6549N/A# ((RPM_OPT_FLAGS is normally defined by rpm as %optflags)) 6549N/A# run the %build section of the linux spec files after cd'ing into 8108N/A# This section installs the files in what ON/SFW folks would call a 8108N/A# "proto area", which is a directory where files are staged for packaging 8108N/A# spec file, called $RPM_BUILD_ROOT. 8108N/A# start with a clean proto dir 8108N/A# when not building -l10n packages, remove anything l10n related from 8108N/A# remove the build root dir once packaging succeeds 8108N/A# use these to define a class and associate installation and removal class 8108N/A# action scripts. The script can be inline or in an external file identified 6549N/A# Make sure you define the Solaris default file attributes for system 8108N/A# The files included here should match the ones removed in %install 6549N/A# Although pkgbuild doesn't currently do anything with %changelog, it's 6549N/A# still a good idea to use changelog entries. 6549N/A# To build a Solaris package from this spec file, copy all referenced 6549N/A# and run pkgbuild -ba <this spec file>