On Aug 04, 2017: 00:21, Brian Callahan wrote:
Hi Scott --
On 08/03/17 21:07, Heppler, J. Scott wrote:
Sorry, my first reply I forget to change the To: entry - it went to
devio.us.
Thanks Brian,
The current 12.2 port did have @sample entries for
/etc/xdg/tint2/tint2rc. I cannot use the old entries because the newer
code follows Freedesktop specs by generating a default
/etc/xdg/tint2/tint2rc configuration file. My problem is why this does
not show in PLIST.
I'm not totally sure what you're asking. If you're thinking that your
update will somehow use the tint2rc file from before the update,
that's not what's happening. It would use the tint2rc file from the
update. The @sample lines take files from the package that exist in
installable locations (usually /usr/local/share/examples/<package> or
the like) and installs them in places that are otherwise forbidden
from having files directly installed to (such as /etc).
If you're saying that tint2 generates a tint2rc file upon first run,
then maybe we'll need to think of some workaround, perhaps
pre-generating a sane tint2rc that gets installed with the package.
Yes, upstream generates an /etc/xdg/tint2/tint2rc file. It may be just
me, but it seems like an ugly hack to patch out upstreams' installation
of /etc/xdg/tint2/tint2rc and then add it back via @sample. I also
think that removing and adding back will become a common occurrence
given the Freedesktop specs.
I did find a second themes/CMakeLists.txt file that GLOB'd the *tint2rc
files and placed the files in ${CMAKE_INSTALL_DATADIR}/tint2.
I patched it to ${CMAKE_INSTALL_DATADIR}/examples/tint2 and was able to
avoid the post-intall entry.
$OpenBSD$
Index: themes/CMakeLists.txt
--- themes/CMakeLists.txt.orig
+++ themes/CMakeLists.txt
@@ -1,2 +1,2 @@
file( GLOB EXTRATHEMEFILES *.tint2rc )
-install( FILES ${EXTRATHEMEFILES} DESTINATION
${CMAKE_INSTALL_DATADIR}/tint2 )
+install( FILES ${EXTRATHEMEFILES} DESTINATION
${CMAKE_INSTALL_DATADIR}/examples/tint2 )
If the bogus elements are ignored, it actually installs
/etc/xdg/tint2/tint2rc per FreeDesktop Specifications - verified in
pobj/tint2...../fake-amd64/etc/xdg/tint2/tint2rc.
But it won't get installed when you install the package. Try it.
Delete /etc/xdg/tint2/tint2rc and then pkg_add your new package. You
won't get a new /etc/xdg/tint2/tint2rc.
https://standards.freedesktop.org/basedir-spec/basedir-spec-latest.html
"Specifications may reference this specification by specifying the
location of a configuration file as $XDG_CONFIG_DIRS/subdir/filename.
This implies that:
Default configuration files should be installed to
$sysconfdir/xdg/subdir/filename with $sysconfdir defaulting to /etc."
My understanding is the we do need the PLIST entries in the event a port
is updated. I am at a loss why make-plist does not detect
/etc/xdg/tint2/tint2rc per the top-most CMakeLists.txt file.
Because it's forbidden to install things directly to /etc. You should
install it to share/examples/tint2 and then @sample it. This is in
fact exactly what the port currently does.
Will do tomorrow. The evenings political news cycle was both righteous
and exhausting.
I'm thinking I'll patch out the xdg install line in the
upper level CMakeLists.txt. Then use the lower level
themes/CMakeLists.txt to file(GLOB THEMEFILES * to install all in
/usr/local/share/examples/tint2. Then @sample to reconstruct
/etc/xdg/tint2/tint2rc.
I read about FAKE_FLAGS but this is made difficult in that themes has
tint2rc and a fair number of *.tintrc files.
I think my comment from my previous email is all you need. Change that
line I said to change and add back all the @sample lines from the
current PLIST.
~Brian
Thanks
Scott
On Aug 03, 2017: 18:14, Brian Callahan wrote:
Hi Scott --
On 08/03/17 16:32, Heppler, J. Scott wrote:
I ran 'make update-plist' and the following bogus elements showed up
Scanning destdir
Getting old lists
1st pass identifying files
Attaching annotations
Sorting out destdir files
make-plist: Bogus element outside of every prefix: /etc/xdg
make-plist: Bogus element outside of every prefix: /etc/xdg/tint2
make-plist: Bogus element outside of every prefix:
/etc/xdg/tint2/tint2rc
These elements exist in the fake build and are based on a
CMakeLists.txt
entry:
install( TARGETS tint2 DESTINATION bin )
install( FILES tint2.svg DESTINATION
${CMAKE_INSTALL_DATADIR}/icons/hicolor/scalable/apps )
install( FILES tint2.desktop DESTINATION
${CMAKE_INSTALL_DATADIR}/applications )
install( FILES themes/tint2rc DESTINATION /etc/xdg/tint2 )
Make a patch to change this line. Tell CMake to install this file
to share/examples/tint2 (this is where it was previously installed
to before your diff).
Then go back and re-add @sample to all the places you diff removed them.
Also, don't edit the @comment line with the RCS ID.
~Brian
install( FILES default_icon.png DESTINATION
${CMAKE_INSTALL_DATADIR}/tint2 )
/usr/ports/pobj/tint2../fake-amd64/etc/xdg/tint2/tint2rc
The porters handbook/special topics says to add the @sample entry
immediately after the entry, but for some reason the
../xdg/tint2/tint2rc entry is missing ?Stripped? from the PLIST.
So I'm confused about where to add the @sample PLIST entries
--
J. Scott Heppler
Penguin Innovations
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
NOTICE: This e-mail message and any attachments may
contain legally privileged and confidential information intended
solely for the use of the intended recipients. If you are not an
intended recipient, you are hereby notified that you have
received this message in error and any review, dissemination,
distribution, copying, or other unauthorized use of this email
and any attachment is strictly prohibited. If you have received
this email in error, please notify the sender immediately and
delete the message and any attachments from your system.