From: lbalders on
9 years later, and this info is still nowhere to be found!

How does one create a Solaris Patch around a sparse package?

The APDG has patching scripts, and some vague information, but the
patch info that surrounds the sparse
patch package is undocumented.

I, as with the previous poster (see below), was able to create a
sparse package, put it in a patch directory 'xxxxxx-xx', add
the .diPatch README and patchinfo files, and modify the sparse
package's pkginfo file to include the SUNW_PATCHID, and the patchadd
fails with that same message:

# patchadd /tmp/012345-01

One or more patch packages included in
012345-01 are not installed on this system.

Patchadd is terminating

# echo $?
8

The error message from /usr/sbin/patchadd
# 8 Attempting to patch a package that is not
installed

# pkginfo XXXXyyyy
application XXXXyyyy Application Package XXXX component yyyy


XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
http://groups.google.com/group/comp.unix.solaris/browse_thread/thread/9226c5e60d5c06e8/a7777d1bc29b0b6b?lnk=gst&q=patch#a7777d1bc29b0b6b

Conor McDonagh View profile
More options May 12 2000, 12:00 am

Newsgroups: comp.unix.solaris
From: Conor McDonagh <co...(a)aersoft.ie>
Date: 2000/05/12
Subject: Creating a patch
Reply to author | Forward | Print | Individual message | Show original
| Report this message | Find messages by this author
I'm trying to create and install a simple patch for a simple pakage.
I
created the patch (correctly, I hope) but then get an error when
installing it using patchadd command: "None of the packages included
in
patch xxxxx are installed on this system". I've followed the
instructions provided in the Answerbook "Application Packaging
Developer's Guide" and also followed closely how Sun's own patches
are
constructed. I created and installed the package itself with no
problems. The pkginfo, pkgparam, pkgchk commands and
/var/sadm/install/contents file all report the package is present. So
then, the package is definitely. I created the patch package,
including
all the scripts. To the best of my knowledge, the patch is exactly
like
a Sun patch. I cannot see the reason for this error report.


I understand that different instances are identified by the three
parameters PKG, NAME, and ARCH. I've made sure they are the same for
the
package and the patch package. In order to make the package and patch
resemble as closely as possible the typical sun versions I included
other parameters PRODNAME, PRODVERS and also named the package
SUNWxxx.


Does anyone have experience of creating packages and, more
specifically,
patches? Maybe I'm doing something wrong in constructing the patch.


(I had another problem with the patch. When I first gave the patch a
name (9 alphanumeric chars), patchadd gave an error to do with its
name
so I changed the name to a similar format to Sun patches, xxxxxx-xx
(where x is digit) and this was accepted. Why won't it accept any
9-alphanumeric-char name?)


Any help on these?


P.S. I'll include here the pkginfo and prototype files for both the
package and patch.
=======================================================================
=======================================================================


pkginfo for package SUNWmyapp
--------------------------------


PRODNAME=SunOS
PRODVERS=5.6/Generic
PKG=SUNWmyapp
NAME=myapp A dummy test package to demonstrate simple package
creation
ARCH=sparc
VERSION=1.00
CATEGORY=application
VENDOR=This Co
EMAIL=an...(a)thisco.com
PSTAMP=aname
BASEDIR=/usr
CLASSES=none


=======================================================================


prototype for package SUNWmyapp
---------------------------------------


i pkginfo=./pkginfo
d none myapp 0755 root bin
d none myapp/bin 0755 root bin
f none myapp/bin/prog 0644 root bin
f none myapp/bin/file1 0644 root bin
f none myapp/bin/file2 0644 root bin
d none myapp/doc 0755 root bin
f none myapp/doc/doc1 0644 root bin
d none myapp/lib 0755 root bin
f none myapp/lib/lib1 0644 root bin
f none myapp/lib/lib2 0644 root bin
d none myapp/man 0755 root bin
f none myapp/man/manpage 0644 root bin
d none /var ? ? ?
d none /var/myapp 0755 root bin
f none /var/myapp/file1=var/myapp/file1 0644 root bin
d none /var/tmp ? ? ?
f none /var/tmp/myappTMPfile1=var/tmp/myappTMPfile1 0644 root bin


=======================================================================


pkginfo for patch 177001-01/SUNWmyapp
---------------------------------------


PRODNAME=SunOS
PRODVERS=5.6/Generic
PKG=SUNWmyapp
NAME=myapp A dummy test package to demonstrate simple package
creation
ARCH=sparc
VERSION=1.00
CATEGORY=application
VENDOR=This Co
EMAIL=an...(a)thisco.com
PSTAMP=aname
BASEDIR=/usr
CLASSES=none
SUNW_PKGTYPE=usr
SUNW_OBSOLETES=
SUNW_REQUIRES=
SUNW_INCOMPAT=
SUNW_PATCHID=177001-01


=======================================================================


prototype for patch 177001-01/SUNWmyapp
---------------------------------------


i pkginfo=./pkginfo
i copyright
i checkinstall
i preinstall
i i.none
i postinstall
i patch_checkinstall
i patch_postinstall
d none myapp 0755 root bin
d none myapp/bin 0755 root bin
f none myapp/bin/prog 0644 root bin
d none myapp/lib 0755 root bin
f none myapp/lib/lib1 0644 root bin
d none /var ? ? ?
d none /var/myapp 0755 root bin
f none /var/myapp/file1=var/myapp/file1 0644 root bin
d none /var/tmp ? ? ?
f none /var/tmp/myappTMPfile1=var/tmp/myappTMPfile1 0644 root bin


=======================================================================
From: lbalders on
On Oct 20, 3:00 pm, lbalders <lbald...(a)gte.net> wrote:
> 9 years later, and this info is still nowhere to be found!
>
> How does one create a Solaris Patch around a sparse package?
>
> The APDG has patching scripts, and some vague information, but the
> patch info that surrounds the sparse
> patch package is undocumented.
>
> I, as with the previous poster (see below), was able to create a
> sparse package, put it in a patch directory 'xxxxxx-xx', add
> the .diPatch README and patchinfo files, and modify the sparse
> package's pkginfo file to include the SUNW_PATCHID, and the patchadd
> fails with that same message:
>
> # patchadd /tmp/012345-01
>
> One or more patch packages included in
> 012345-01 are not installed on this system.
>
> Patchadd is terminating
>
> # echo $?
> 8
>
> The error message from /usr/sbin/patchadd
> #                8        Attempting to patch a  package that is not
> installed
>
> # pkginfo XXXXyyyy
> application XXXXyyyy       Application Package XXXX component yyyy
>
> XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX­XXXXXXXXXXXhttp://groups.google.com/group/comp.unix.solaris/browse_thread/thread...
>
> Conor McDonagh    View profile
>   More options May 12 2000, 12:00 am
>
> Newsgroups: comp.unix.solaris
> From: Conor McDonagh <co...(a)aersoft.ie>
> Date: 2000/05/12
> Subject: Creating a patch
> Reply to author | Forward | Print | Individual message | Show original
> | Report this message | Find messages by this author
> I'm trying to create and install a simple patch for a simple pakage.
> I
> created the patch (correctly, I hope) but then get an error when
> installing it using patchadd command: "None of the packages included
> in
> patch xxxxx are installed on this system". I've followed the
> instructions provided in the Answerbook "Application Packaging
> Developer's Guide" and also followed closely how Sun's own patches
> are
> constructed. I created and installed the package itself with no
> problems. The pkginfo, pkgparam, pkgchk commands and
> /var/sadm/install/contents file all report the package is present. So
> then, the package is definitely. I created the patch package,
> including
> all the scripts. To the best of my knowledge, the patch is exactly
> like
> a Sun patch. I cannot see the reason for this error report.
>
> I understand that different instances are identified by the three
> parameters PKG, NAME, and ARCH. I've made sure they are the same for
> the
> package and the patch package. In order to make the package and patch
> resemble as closely as possible the typical sun versions I included
> other parameters PRODNAME, PRODVERS and also named the package
> SUNWxxx.
>
> Does anyone have experience of creating packages and, more
> specifically,
> patches? Maybe I'm doing something wrong in constructing the patch.
>
> (I had another problem with the patch. When I first gave the patch a
> name (9 alphanumeric chars), patchadd gave an error to do with its
> name
> so I changed the name to a similar format to Sun patches, xxxxxx-xx
> (where x is digit) and this was accepted. Why won't it accept any
> 9-alphanumeric-char name?)
>
> Any help on these?
>
> P.S. I'll include here the pkginfo and prototype files for both the
> package and patch.
> =======================================================================
> =======================================================================
>
> pkginfo for package SUNWmyapp
> --------------------------------
>
> PRODNAME=SunOS
> PRODVERS=5.6/Generic
> PKG=SUNWmyapp
> NAME=myapp  A dummy test package to demonstrate simple package
> creation
> ARCH=sparc
> VERSION=1.00
> CATEGORY=application
> VENDOR=This Co
> EMAIL=an...(a)thisco.com
> PSTAMP=aname
> BASEDIR=/usr
> CLASSES=none
>
> =======================================================================
>
> prototype for package SUNWmyapp
> ---------------------------------------
>
> i pkginfo=./pkginfo
> d none myapp 0755 root bin
> d none myapp/bin 0755 root bin
> f none myapp/bin/prog 0644 root bin
> f none myapp/bin/file1 0644 root bin
> f none myapp/bin/file2 0644 root bin
> d none myapp/doc 0755 root bin
> f none myapp/doc/doc1 0644 root bin
> d none myapp/lib 0755 root bin
> f none myapp/lib/lib1 0644 root bin
> f none myapp/lib/lib2 0644 root bin
> d none myapp/man 0755 root bin
> f none myapp/man/manpage 0644 root bin
> d none /var ? ? ?
> d none /var/myapp 0755 root bin
> f none /var/myapp/file1=var/myapp/file1 0644 root bin
> d none /var/tmp ? ? ?
> f none /var/tmp/myappTMPfile1=var/tmp/myappTMPfile1 0644 root bin
>
> =======================================================================
>
> pkginfo for patch 177001-01/SUNWmyapp
> ---------------------------------------
>
> PRODNAME=SunOS
> PRODVERS=5.6/Generic
> PKG=SUNWmyapp
> NAME=myapp  A dummy test package to demonstrate simple package
> creation
> ARCH=sparc
> VERSION=1.00
> CATEGORY=application
> VENDOR=This Co
> EMAIL=an...(a)thisco.com
> PSTAMP=aname
> BASEDIR=/usr
> CLASSES=none
> SUNW_PKGTYPE=usr
> SUNW_OBSOLETES=
> SUNW_REQUIRES=
> SUNW_INCOMPAT=
> SUNW_PATCHID=177001-01
>
> =======================================================================
>
> prototype for patch 177001-01/SUNWmyapp
> ---------------------------------------
>
> i pkginfo=./pkginfo
> i copyright
> i checkinstall
> i preinstall
> i i.none
> i postinstall
> i patch_checkinstall
> i patch_postinstall
> d none myapp 0755 root bin
> d none myapp/bin 0755 root bin
> f none myapp/bin/prog 0644 root bin
> d none myapp/lib 0755 root bin
> f none myapp/lib/lib1 0644 root bin
> d none /var ? ? ?
> d none /var/myapp 0755 root bin
> f none /var/myapp/file1=var/myapp/file1 0644 root bin
> d none /var/tmp ? ? ?
> f none /var/tmp/myappTMPfile1=var/tmp/myappTMPfile1 0644 root bin
>
> =======================================================================



Here is why no info is available. Sun advises:

"We cannot make patch building utility publicly available
irrespective of the customer having support contract. We suggest you
to provide an updated package instead of patches to your customer and
tell them to remove the old version and add the new version of the
package."