This bug fix broke this package, I have this host I install with a debconf frontend non-interactive:
Unpacking ttf-mscorefonts-installer (from .../ttf-mscorefonts-installer_3.2ubuntu0.1_all.deb) ...
mscorefonts-eula license could not be presented
try 'dpkg-reconfigure debconf' to select a frontend other than noninteractive
Good, I did not accept the license, then at postinst step:
in package postinst script, the following code is running:
FONTDIR=/usr/share/fonts/truetype/msttcorefonts
license=mscorefonts-eula
db_get msttcorefonts/accepted-$license
if [ "$RET" != "true" ]; then
echo "user did not accept the $license license" >&2
rm -f $FONTDIR/*.ttf
cat > $FONTDIR/README <<EOF
License refused.
[snip]
EOF
exit 0
else
rm -f $FONTDIR/README
fi
But, on a clean installation, without any trace of ttf-mscorefonts-installer before, there is no folder /usr/share/fonts/truetype/msttcorefonts yet, it's created later in postinst script, if license is approved.
this cause cat to fail :
Setting up ttf-mscorefonts-installer (3.2ubuntu0.1) ...
user did not accept the mscorefonts-eula license
/var/lib/dpkg/info/ttf-mscorefonts-installer.postinst: 36: cannot create /usr/share/fonts/truetype/msttcorefonts/README: Directory nonexistent
dpkg: error processing ttf-mscorefonts-installer (--configure):
subprocess installed post-installation script returned error exit status 2
maybe with something like this:
if [ "$RET" != "true" ]; then
if [ -d $FONTDIR ]; then
rm -f $FONTDIR/*.ttf
cat > $FONTDIR/README <<EOF
or the folder /usr/share/fonts/truetype/msttcorefonts should be in debian/dirs
This bug fix broke this package, I have this host I install with a debconf frontend non-interactive:
Unpacking ttf-mscorefonts -installer (from .../ttf- mscorefonts- installer_ 3.2ubuntu0. 1_all.deb) ...
mscorefonts-eula license could not be presented
try 'dpkg-reconfigure debconf' to select a frontend other than noninteractive
Good, I did not accept the license, then at postinst step:
in package postinst script, the following code is running:
FONTDIR= /usr/share/ fonts/truetype/ msttcorefonts mscorefonts- eula accepted- $license
license=
db_get msttcorefonts/
if [ "$RET" != "true" ]; then
echo "user did not accept the $license license" >&2
rm -f $FONTDIR/*.ttf
cat > $FONTDIR/README <<EOF
License refused.
[snip]
EOF
exit 0
else
rm -f $FONTDIR/README
fi
But, on a clean installation, without any trace of ttf-mscorefonts -installer before, there is no folder /usr/share/ fonts/truetype/ msttcorefonts yet, it's created later in postinst script, if license is approved.
this cause cat to fail :
Setting up ttf-mscorefonts -installer (3.2ubuntu0.1) ... dpkg/info/ ttf-mscorefonts -installer. postinst: 36: cannot create /usr/share/ fonts/truetype/ msttcorefonts/ README: Directory nonexistent -installer (--configure):
user did not accept the mscorefonts-eula license
/var/lib/
dpkg: error processing ttf-mscorefonts
subprocess installed post-installation script returned error exit status 2
maybe with something like this:
if [ "$RET" != "true" ]; then
if [ -d $FONTDIR ]; then
rm -f $FONTDIR/*.ttf
cat > $FONTDIR/README <<EOF
or the folder /usr/share/ fonts/truetype/ msttcorefonts should be in debian/dirs