pkgsrc-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

.subst_pkglocaledir_done and DESTDIR



Still working on updating the pkgsrc entry for emulators/vice, I come
across the following, regarding DESTDIR support.

In the file vice-2.3/po/Makefile.in.in, there is

    localedir = $(DESTDIR)$(datadir)/locale
    gnulocaledir = $(DESTDIR)$(prefix)/share/locale

Something changes this to

    localedir = /usr/pkg/share/locale
    gnulocaledir = /usr/pkg/share/locale

Note that $(DESTDIR) disappears here. The suspect is whatever program
writes the file .subst_pkglocaledir_done, since it lists the name.

Since there later on in the script there is

          case "$$cat" in \
            *.gmo) destdir=$(gnulocaledir);; \
            *)     destdir=$(localedir);; \
          esac; \

I have to patch it to

          case "$$cat" in \
            *.gmo) destdir=$(DESTDIR)/$(gnulocaledir);; \
            *)     destdir=$(DESTDIR)/$(localedir);; \
          esac; \

to restore DESTDIR support again.  Later on, $destdir is used to name
directories to create and to install stuff into.

Why is pkgsrc here working against itself? How do I tell it to stay away
from those lines, or at least to include $DESTDIR?

(I did try to make a package without the hackish patch, but I get the
expected errors:

    mkdir /home/tmp/emulators/vice/work.x86_64/.destdir/usr/pkg/lib
    install: /usr/pkg/share/locale/de/LC_MESSAGES/vice.mo: open: Permission
denied
    ...
and later
    pkg_create: can't stat 
`/home/tmp/emulators/vice/work.x86_64/.destdir/usr/pkg/share/locale/de/LC_MESSAGES/vice.mo'
    ...
)

-Olaf.
-- 
___ Olaf 'Rhialto' Seibert  -- There's no point being grown-up if you 
\X/ rhialto/at/xs4all.nl    -- can't be childish sometimes. -The 4th Doctor
X5O!P%@AP[4\PZX54(P^)7CC)7}$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!$H+H*


Home | Main Index | Thread Index | Old Index