1 # -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
3 # This file is part of the LibreOffice project.
5 # This Source Code Form is subject to the terms of the Mozilla Public
6 # License, v. 2.0. If a copy of the MPL was not distributed with this
7 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
10 include $(SRCDIR
)/sysui
/productlist.mk
12 slack_WORKDIR
:= $(call gb_CustomTarget_get_workdir
,sysui
/slackware
)
13 slack_SRCDIR
:= $(SRCDIR
)/sysui
/desktop
/slackware
15 $(eval
$(call gb_CustomTarget_CustomTarget
,sysui
/slackware
))
17 $(eval
$(call gb_CustomTarget_register_targets
,sysui
/slackware
,\
19 $(foreach product
,$(PRODUCTLIST
),\
20 $(product
)/install/doinst.sh \
21 $(product
)/install/slack-desc \
22 $(product
)$(PRODUCTVERSION
)-slackware-menus-
$(PKGVERSION
)-noarch-
$(LIBO_VERSION_PATCH
).tgz
) \
26 $(slack_WORKDIR
)/empty.
tar:
27 mkdir
$(slack_WORKDIR
)/empty
28 $(GNUTAR
) -C
$(slack_WORKDIR
)/empty
--owner
=root
$(if
$(filter-out MACOSX
,$(OS_FOR_BUILD
)),--group
=root
) --same-owner
-cf
$@ .
30 $(slack_WORKDIR
)/%/install/doinst.sh
: $(slack_SRCDIR
)/update-script
$(call gb_CustomTarget_get_workdir
,sysui
/share
)/%/launcherlist
31 echo
"( cd etc; rm -rf $(UNIXFILENAME.$*) )" > $@
32 echo
"( cd etc; ln -snf /opt/$(UNIXFILENAME.$*) $(UNIXFILENAME.$*) )" >> $@
33 echo
"( cd usr/bin; rm -rf soffice )" >> $@
34 echo
"( cd usr/bin; ln -sf /etc/$(UNIXFILENAME.$*)/program/soffice soffice )" >> $@
35 for i in
`cat $(call gb_CustomTarget_get_workdir,sysui/share)/$*/launcherlist`; do \
36 echo
"(cd usr/share/applications; rm -rf $(UNIXFILENAME.$*)-$$i)" >> $@
; \
37 echo
"(cd usr/share/applications; ln -sf /etc/$(UNIXFILENAME.$*)/share/xdg/$$i $(UNIXFILENAME.$*)-$$i)" >> $@
; \
41 $(slack_WORKDIR
)/%/install/slack-desc
: $(slack_SRCDIR
)/slack-desc
42 sed
-e
"s/PKGNAME/$*-slackware-menus/g" \
43 -e
"s/PKGVERSION/$(PKGVERSION)/g" \
44 -e
"s/LONGPRODUCTNAME/$(PRODUCTNAME.$*) $(PRODUCTVERSION)/g" \
45 -e
"s/PRODUCTNAME/$(PRODUCTNAME.$*)/g" \
46 -e
"s/UNIXFILENAME/$(UNIXFILENAME.$*)/g" \
49 $(slack_WORKDIR
)/%$(PRODUCTVERSION
)-slackware-menus-
$(PKGVERSION
)-noarch-
$(LIBO_VERSION_PATCH
).tgz
: $(slack_WORKDIR
)/empty.
tar $(slack_WORKDIR
)/%/install/doinst.sh
$(slack_WORKDIR
)/%/install/slack-desc
$(call gb_CustomTarget_get_workdir
,sysui
/share
)/%/create_tree.sh
50 cd
$(call gb_CustomTarget_get_workdir
,sysui
/share
)/$* \
51 && DESTDIR
=$(slack_WORKDIR
)/$* \
52 ICON_PREFIX
=$(UNIXFILENAME.
$*) \
56 cp
$(slack_WORKDIR
)/empty.
tar $@.tmp
57 $(GNUTAR
) -C
$(slack_WORKDIR
)/$* --owner
=root
$(if
$(filter-out MACOSX
,$(OS_FOR_BUILD
)),--group
=root
) --same-owner \
58 -rf
$@.tmp
install usr opt
61 # vim: set noet sw=4 ts=4: