source: src-sh/port-files/pkg-install @ 9b2c4e1

9.2-releasereleng/10.0releng/10.0.1
Last change on this file since 9b2c4e1 was 9b2c4e1, checked in by Kris Moore <kris@…>, 6 months ago

Add custom ldconfig to pbi-manager10

  • Property mode set to 100644
File size: 1.2 KB
Line 
1#!/bin/sh
2# Script to install PBI repo on pkg add
3
4PREFIX=${PKG_PREFIX-/usr/local}
5
6if [ "$2" != "POST-INSTALL" ] ; then
7   exit 0
8fi
9
10# If this is during staging, we can skip for now
11echo $PREFIX | grep -q '/stage/'
12if [ $? -eq 0 ] ; then
13   exit 0
14fi
15
16# If this is a new install, add the PC-BSD master repo
17ls /var/db/pbi/keys/* 2>/dev/null >/dev/null
18if [ $? -ne 0 ] ; then
19        ${PREFIX}/sbin/pbi_addrepo ${PREFIX}/share/pbi-manager/pcbsd.rpo
20fi
21
22# Copy over the wrapper files
23if [ `uname -m` = "amd64" ] ; then
24  cp ${PREFIX}/share/pbi-manager/.pbiwrapper-i386 /usr/pbi/.pbiwrapper-i386
25  cp ${PREFIX}/share/pbi-manager/.pbiwrapper-amd64 /usr/pbi/.pbiwrapper-amd64
26else
27  cp ${PREFIX}/share/pbi-manager/.pbiwrapper-i386 /usr/pbi/.pbiwrapper-i386
28fi
29
30# If on FreeBSD > 10, install the PBI mounting files
31if [ -e "${PREFIX}/share/pbi-manager/.pbime" ] ; then
32   install -o root -g wheel -m 4751 ${PREFIX}/share/pbi-manager/.pbime /usr/pbi/.pbime
33   install -o root -g wheel -m 755 ${PREFIX}/share/pbi-manager/.pbimount /usr/pbi/.pbimount
34   install -o root -g wheel -m 755 ${PREFIX}/share/pbi-manager/.ldconfig /usr/pbi/.ldconfig
35   install -o root -g wheel -m 755 ${PREFIX}/share/pbi-manager/.mount_nullfs /usr/pbi/.mount_nullfs
36fi
37
38exit 0
Note: See TracBrowser for help on using the repository browser.