[petsc] 02/02: streamline alternatives priorities
Drew Parsons
dparsons at moszumanska.debian.org
Fri Oct 9 03:23:42 UTC 2015
This is an automated email from the git hooks/post-receive script.
dparsons pushed a commit to branch master
in repository petsc.
commit 99ec98aea50bcd760a36621da9f0f2d6a5a5d4e9
Author: Drew Parsons <dparsons at debian.org>
Date: Fri Oct 9 10:50:29 2015 +0800
streamline alternatives priorities
Document priorities in Readme.source
The priorities are:
UDC
U is an upstream value and D and C are single digits
i.e.
U = upstream version e.g. 3.6.2
D = stripped (D=7) or debug version (D=3)
C = real (C=7) or complex (C=3)
Digits 7 and 3 are chosen to given local administrators more freedom
to set their own priorities, higher or lower, for custom builds.
---
debian/README.Debian | 1 +
debian/README.source | 53 ++++++++++++++++++++++++++++++
debian/changelog | 2 +-
debian/libpetsc-complex-3.6.2-dbg.postinst | 2 +-
debian/libpetsc-complex-3.6.2-dev.postinst | 2 +-
debian/libpetsc-complex-3.6.postinst | 2 +-
debian/libpetsc3.6.2-dbg.postinst | 2 +-
debian/libpetsc3.6.2-dev.postinst | 2 +-
debian/libpetsc3.6.postinst | 2 +-
9 files changed, 61 insertions(+), 7 deletions(-)
diff --git a/debian/README.Debian b/debian/README.Debian
index 0a4111c..d321a53 100644
--- a/debian/README.Debian
+++ b/debian/README.Debian
@@ -140,6 +140,7 @@ When setting your preference for /usr/lib/petsc via "update-alternatives --confi
it is important for consistency to also update your preference for the
main shared library files provided by libpetsc3.6 or libpetsc-complex-3.6.
These alternative links are controlled by libpetsc.so.3.6:
+
update-alternatives --config libpetsc.so.3.6
To maintain the consistency of the master and slave symlinks, it is very
diff --git a/debian/README.source b/debian/README.source
new file mode 100644
index 0000000..f625406
--- /dev/null
+++ b/debian/README.source
@@ -0,0 +1,53 @@
+SONAME and custom packages
+--------------------------
+
+Depending on the context of the installation and the configuration
+options you select, if you a recompiling for your local system then
+you may find you want to be able to control the soname of your PETSc
+shared library. You can do this with the ./configure option
+
+ --shared-library-extension=<string>
+
+The given string as added to the standard library name and to the soname,
+e.g. changing libpetsc.so.3.6 to libpetsc<string>.so.3.6
+
+The standard Debian build uses
+ --shared-library-extension=_real
+for the default build supporting real numbers, and
+ --shared-library-extension=_complex
+for the build supporting complex numbers.
+
+
+Alternatives Priorities
+-----------------------
+
+The preferred PETSc installation is linked to /usr/lib/petsc:
+
+ update-alternatives --config petsc
+
+and the corresponding preferred shared library is linked in
+/usr/lib/<arch> in a separately managed alternative link:
+
+ update-alternatives --config libpetsc.so.3.6
+
+(e.g. linking to libpetsc_real.so.3.6.2 or libpetsc_complex.so.3.6.2)
+
+The priorities of the alternatives used in automatic alternatives
+configuration are organised to prioritise the stripped over debug
+version and the real over the complex version. The priorities
+therefore are:
+
+ UDC
+
+U is an upstream value and D and C are single digits
+i.e.
+
+ U = upstream version e.g. 3.6.2
+
+ D = stripped (D=7) or debug version (D=3)
+
+ C = real (C=7) or complex (C=3)
+
+Digits 7 and 3 are chosen to given local administrators more freedom
+to set their own priorities, higher or lower, for custom builds.
+
diff --git a/debian/changelog b/debian/changelog
index 3bbf22d..bfe9990 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -20,7 +20,7 @@ petsc (3.6.2.dfsg1-1) UNRELEASED; urgency=medium
* The library and soname are modified for complex support,
libpetsc_complex.so. The standard build with real numbers has a
modified soname to match, libpetc_real.so. The preference for
- libpetsc.so is controlled by alternatives.
+ libpetsc.so is controlled by alternatives (petsc and libpetsc.so.3.6).
-- Drew Parsons <dparsons at debian.org> Thu, 24 Sep 2015 11:55:47 +0800
diff --git a/debian/libpetsc-complex-3.6.2-dbg.postinst b/debian/libpetsc-complex-3.6.2-dbg.postinst
index 8ac2d42..2647693 100644
--- a/debian/libpetsc-complex-3.6.2-dbg.postinst
+++ b/debian/libpetsc-complex-3.6.2-dbg.postinst
@@ -8,7 +8,7 @@ PETSC_DEBUG_ARCH=${PETSC_ARCH}-complex-debug
# Make alternatives links
if [ "$1" = "configure" ]; then
-update-alternatives --install /usr/lib/petsc petsc /usr/lib/petscdir/${PETSC_VERSION}/${PETSC_DEBUG_ARCH} 36200 \
+update-alternatives --install /usr/lib/petsc petsc /usr/lib/petscdir/${PETSC_VERSION}/${PETSC_DEBUG_ARCH} 36233 \
--slave /usr/lib/libpetsc.so libpetsc.so /usr/lib/petscdir/${PETSC_VERSION}/${PETSC_DEBUG_ARCH}/lib/libpetsc_complex.so.${PETSC_VERSION} \
--slave /usr/lib/${DEB_HOST_MULTIARCH}/libpetsc.so libpetsc.so.multiarch /usr/lib/petscdir/${PETSC_VERSION}/${PETSC_DEBUG_ARCH}/lib/libpetsc_complex.so.${PETSC_VERSION} \
--slave /usr/include/petsc petscinclude /usr/lib/petscdir/${PETSC_VERSION}/${PETSC_DEBUG_ARCH}/include \
diff --git a/debian/libpetsc-complex-3.6.2-dev.postinst b/debian/libpetsc-complex-3.6.2-dev.postinst
index 63d1d44..da0d431 100644
--- a/debian/libpetsc-complex-3.6.2-dev.postinst
+++ b/debian/libpetsc-complex-3.6.2-dev.postinst
@@ -8,7 +8,7 @@ PETSC_COMPLEX_ARCH=${PETSC_ARCH}-complex
# Make alternatives links
if [ "$1" = "configure" ]; then
-update-alternatives --install /usr/lib/petsc petsc /usr/lib/petscdir/${PETSC_VERSION}/${PETSC_COMPLEX_ARCH} 3620 \
+update-alternatives --install /usr/lib/petsc petsc /usr/lib/petscdir/${PETSC_VERSION}/${PETSC_COMPLEX_ARCH} 36273 \
--slave /usr/lib/libpetsc.so libpetsc.so /usr/lib/${DEB_HOST_MULTIARCH}/libpetsc_complex.so.${PETSC_VERSION} \
--slave /usr/lib/${DEB_HOST_MULTIARCH}/libpetsc.so libpetsc.so.multiarch /usr/lib/${DEB_HOST_MULTIARCH}/libpetsc_complex.so.${PETSC_VERSION} \
--slave /usr/include/petsc petscinclude /usr/lib/petscdir/${PETSC_VERSION}/${PETSC_COMPLEX_ARCH}/include \
diff --git a/debian/libpetsc-complex-3.6.postinst b/debian/libpetsc-complex-3.6.postinst
index 2ae44e7..8db8f37 100644
--- a/debian/libpetsc-complex-3.6.postinst
+++ b/debian/libpetsc-complex-3.6.postinst
@@ -9,7 +9,7 @@ SONAME=$( echo ${PETSC_VERSION} | awk 'BEGIN { FS="."}; {print $1"."$2 }' )
# Make alternatives links
if [ "$1" = "configure" ]; then
- update-alternatives --install /usr/lib/${DEB_HOST_MULTIARCH}/libpetsc.so.${SONAME} libpetsc.so.${SONAME} /usr/lib/${DEB_HOST_MULTIARCH}/libpetsc_complex.so.${PETSC_VERSION} 3620 \
+ update-alternatives --install /usr/lib/${DEB_HOST_MULTIARCH}/libpetsc.so.${SONAME} libpetsc.so.${SONAME} /usr/lib/${DEB_HOST_MULTIARCH}/libpetsc_complex.so.${PETSC_VERSION} 36273 \
--slave /usr/lib/${DEB_HOST_MULTIARCH}/libpetsc.so.${PETSC_VERSION} libpetsc.so.${PETSC_VERSION} /usr/lib/${DEB_HOST_MULTIARCH}/libpetsc_complex.so.${PETSC_VERSION}
fi
diff --git a/debian/libpetsc3.6.2-dbg.postinst b/debian/libpetsc3.6.2-dbg.postinst
index d761238..e1b662e 100644
--- a/debian/libpetsc3.6.2-dbg.postinst
+++ b/debian/libpetsc3.6.2-dbg.postinst
@@ -8,7 +8,7 @@ PETSC_DEBUG_ARCH=${PETSC_ARCH}-debug
# Make alternatives links
if [ "$1" = "configure" ]; then
-update-alternatives --install /usr/lib/petsc petsc /usr/lib/petscdir/${PETSC_VERSION}/${PETSC_DEBUG_ARCH} 362 \
+update-alternatives --install /usr/lib/petsc petsc /usr/lib/petscdir/${PETSC_VERSION}/${PETSC_DEBUG_ARCH} 36237 \
--slave /usr/lib/libpetsc.so libpetsc.so /usr/lib/petscdir/${PETSC_VERSION}/${PETSC_DEBUG_ARCH}/lib/libpetsc_real.so.${PETSC_VERSION} \
--slave /usr/lib/${DEB_HOST_MULTIARCH}/libpetsc.so libpetsc.so.multiarch /usr/lib/petscdir/${PETSC_VERSION}/${PETSC_DEBUG_ARCH}/lib/libpetsc_real.so.${PETSC_VERSION} \
--slave /usr/include/petsc petscinclude /usr/lib/petscdir/${PETSC_VERSION}/${PETSC_DEBUG_ARCH}/include \
diff --git a/debian/libpetsc3.6.2-dev.postinst b/debian/libpetsc3.6.2-dev.postinst
index 93e50f4..9f3c389 100644
--- a/debian/libpetsc3.6.2-dev.postinst
+++ b/debian/libpetsc3.6.2-dev.postinst
@@ -8,7 +8,7 @@ PETSC_REAL_ARCH=${PETSC_ARCH}-real
# Make alternatives links
if [ "$1" = "configure" ]; then
-update-alternatives --install /usr/lib/petsc petsc /usr/lib/petscdir/${PETSC_VERSION}/${PETSC_REAL_ARCH} 3622 \
+update-alternatives --install /usr/lib/petsc petsc /usr/lib/petscdir/${PETSC_VERSION}/${PETSC_REAL_ARCH} 36277 \
--slave /usr/lib/libpetsc.so libpetsc.so /usr/lib/${DEB_HOST_MULTIARCH}/libpetsc_real.so.${PETSC_VERSION} \
--slave /usr/lib/${DEB_HOST_MULTIARCH}/libpetsc.so libpetsc.so.multiarch /usr/lib/${DEB_HOST_MULTIARCH}/libpetsc_real.so.${PETSC_VERSION} \
--slave /usr/include/petsc petscinclude /usr/lib/petscdir/${PETSC_VERSION}/${PETSC_REAL_ARCH}/include \
diff --git a/debian/libpetsc3.6.postinst b/debian/libpetsc3.6.postinst
index cfb390c..d2ed978 100644
--- a/debian/libpetsc3.6.postinst
+++ b/debian/libpetsc3.6.postinst
@@ -9,7 +9,7 @@ SONAME=$( echo ${PETSC_VERSION} | awk 'BEGIN { FS="."}; {print $1"."$2 }' )
# Make alternatives links
if [ "$1" = "configure" ]; then
- update-alternatives --install /usr/lib/${DEB_HOST_MULTIARCH}/libpetsc.so.${SONAME} libpetsc.so.${SONAME} /usr/lib/${DEB_HOST_MULTIARCH}/libpetsc_real.so.${PETSC_VERSION} 3622 \
+ update-alternatives --install /usr/lib/${DEB_HOST_MULTIARCH}/libpetsc.so.${SONAME} libpetsc.so.${SONAME} /usr/lib/${DEB_HOST_MULTIARCH}/libpetsc_real.so.${PETSC_VERSION} 36277 \
--slave /usr/lib/${DEB_HOST_MULTIARCH}/libpetsc.so.${PETSC_VERSION} libpetsc.so.${PETSC_VERSION} /usr/lib/${DEB_HOST_MULTIARCH}/libpetsc_real.so.${PETSC_VERSION}
fi
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/petsc.git
More information about the debian-science-commits
mailing list