|
|
|
|
@ -14,6 +14,9 @@ PKGNAME = $(MAKEFILE_DIR)
|
|
|
|
|
FILE_VER = source/${PKGNAME}.h
|
|
|
|
|
PKGIDENT=$(subst /,-,${PREFIX})
|
|
|
|
|
|
|
|
|
|
FILE_MO := $(PKGNAME).mo
|
|
|
|
|
LOCALE_DIR := ./locale
|
|
|
|
|
|
|
|
|
|
default_target: all
|
|
|
|
|
|
|
|
|
|
.PHONY: all init depend debug prepare check build uninstall install clean help
|
|
|
|
|
@ -94,7 +97,6 @@ uninstall:
|
|
|
|
|
done
|
|
|
|
|
@$(RM) "${DESTDIR}${PREFIX}/bin/${PKGNAME}"
|
|
|
|
|
@$(RM) "${DESTDIR}${PREFIX}/share/applications/${PKGNAME}.desktop"
|
|
|
|
|
@$(RM) "${DESTDIR}${PREFIX}/share/icons/hicolor/scalable/apps/com.ublinux.${PKGNAME}.svg"
|
|
|
|
|
@$(RM) "${DESTDIR}/usr/share/polkit-1/actions/com.ublinux.${PKGNAME}${PKGIDENT}.policy"
|
|
|
|
|
@if [ -z ${DESTDIR} ]; then \
|
|
|
|
|
[ -d "${DESTDIR}${PREFIX}/share/icons/hicolor/" ] && gtk-update-icon-cache -fiq "${DESTDIR}${PREFIX}/share/icons/hicolor/" &>/dev/null || true; \
|
|
|
|
|
@ -110,53 +112,29 @@ install: check uninstall
|
|
|
|
|
file=$$(find ./locale/ -name '*_'"$$lang"'.po'); \
|
|
|
|
|
msgfmt $$file -v -f -o ${DESTDIR}/usr/share/locale/$$lang/LC_MESSAGES/$(FILE_MO); \
|
|
|
|
|
done
|
|
|
|
|
|
|
|
|
|
@for SIZE in 16 32 48; do \
|
|
|
|
|
install -dm755 "${DESTDIR}${PREFIX}/share/icons/hicolor/$${SIZE}x$${SIZE}/apps"; \
|
|
|
|
|
rsvg-convert -w $${SIZE} -h $${SIZE} -f svg --keep-image-data "com.ublinux.${PKGNAME}.svg" -o "${DESTDIR}${PREFIX}/share/icons/hicolor/$${SIZE}x$${SIZE}/apps/com.ublinux.${PKGNAME}.svg"; \
|
|
|
|
|
done
|
|
|
|
|
@install -Dm644 -t "${DESTDIR}${PREFIX}/share/icons/hicolor/scalable/apps/" "com.ublinux.${PKGNAME}.svg"
|
|
|
|
|
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/apps/" "com.ublinux.${PKGNAME}.svg"
|
|
|
|
|
@cp ./com.ublinux.${PKGNAME}.policy ./compile/com.ublinux.${PKGNAME}${PKGIDENT}.policy
|
|
|
|
|
@sed -e 's+/usr/bin+${PREFIX}/bin+' -e 's+.run+${PKGIDENT}.run+g' ./compile/com.ublinux.${PKGNAME}${PKGIDENT}.policy -i
|
|
|
|
|
@install -Dm755 -t "${DESTDIR}${PREFIX}/bin/" "${CMAKE_BUILD_DIR}/${PKGNAME}"
|
|
|
|
|
@install -Dm644 -t "${DESTDIR}${PREFIX}/share/applications/" "${PKGNAME}.desktop"
|
|
|
|
|
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/status/" "icons/com.ublinux.${PKGNAME}.checked.svg"
|
|
|
|
|
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/status/" "icons/com.ublinux.${PKGNAME}.warning.svg"
|
|
|
|
|
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/actions/" "icons/com.ublinux.${PKGNAME}.view-symbolic.svg"
|
|
|
|
|
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/actions/" "icons/com.ublinux.${PKGNAME}.play-symbolic.svg"
|
|
|
|
|
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/actions/" "icons/com.ublinux.${PKGNAME}.stop-symbolic.svg"
|
|
|
|
|
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/actions/" "icons/com.ublinux.${PKGNAME}.zoom-symbolic.svg"
|
|
|
|
|
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/actions/" "icons/com.ublinux.${PKGNAME}.back-symbolic.svg"
|
|
|
|
|
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/actions/" "icons/com.ublinux.${PKGNAME}.increase-symbolic.svg"
|
|
|
|
|
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/actions/" "icons/com.ublinux.${PKGNAME}.decrease-symbolic.svg"
|
|
|
|
|
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/actions/" "icons/com.ublinux.${PKGNAME}.profile-symbolic.svg"
|
|
|
|
|
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/actions/" "icons/com.ublinux.${PKGNAME}.edit-symbolic.svg"
|
|
|
|
|
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/actions/" "icons/com.ublinux.${PKGNAME}.check-symbolic.svg"
|
|
|
|
|
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/actions/" "icons/com.ublinux.${PKGNAME}.uncheck-symbolic.svg"
|
|
|
|
|
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/actions/" "icons/com.ublinux.${PKGNAME}.settings-symbolic.svg"
|
|
|
|
|
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/actions/" "icons/com.ublinux.${PKGNAME}.trash-symbolic.svg"
|
|
|
|
|
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/actions/" "icons/com.ublinux.${PKGNAME}.sort-symbolic.svg"
|
|
|
|
|
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/actions/" "icons/com.ublinux.${PKGNAME}.sync-symbolic.svg"
|
|
|
|
|
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/actions/" "icons/com.ublinux.${PKGNAME}.funnel-symbolic.svg"
|
|
|
|
|
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/actions/" "icons/com.ublinux.${PKGNAME}.reset-symbolic.svg"
|
|
|
|
|
|
|
|
|
|
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/actions/" "icons/com.ublinux.${PKGNAME}.generic1-symbolic.svg"
|
|
|
|
|
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/actions/" "icons/com.ublinux.${PKGNAME}.generic2-symbolic.svg"
|
|
|
|
|
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/actions/" "icons/com.ublinux.${PKGNAME}.generic3-symbolic.svg"
|
|
|
|
|
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/actions/" "icons/com.ublinux.${PKGNAME}.generic4-symbolic.svg"
|
|
|
|
|
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/actions/" "icons/com.ublinux.${PKGNAME}.generic5-symbolic.svg"
|
|
|
|
|
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/actions/" "icons/com.ublinux.${PKGNAME}.generic6-symbolic.svg"
|
|
|
|
|
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/actions/" "icons/com.ublinux.${PKGNAME}.generic7-symbolic.svg"
|
|
|
|
|
@install -Dm644 -t "${DESTDIR}/usr/share/${PKGNAME}/csv/" "journals_list.csv"
|
|
|
|
|
@install -Dm644 -t "${DESTDIR}/usr/share/${PKGNAME}/csv/" "logging_services.csv"
|
|
|
|
|
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/status/" "com.ublinux.${PKGNAME}.checked.svg"
|
|
|
|
|
@install -Dm644 -t "${DESTDIR}/usr/share/icons/hicolor/scalable/status/" "com.ublinux.${PKGNAME}.warning.svg"
|
|
|
|
|
@install -Dm644 -t "${DESTDIR}/usr/share/polkit-1/actions/" "${CMAKE_BUILD_DIR}/com.ublinux.${PKGNAME}${PKGIDENT}.policy"
|
|
|
|
|
@install -Dm644 -t "${DESTDIR}/usr/share/polkit-1/actions/" "com.ublinux.${PKGNAME}.auth.policy"
|
|
|
|
|
@ldconfig -n /usr/local/lib
|
|
|
|
|
@if [ -z ${DESTDIR} ]; then \
|
|
|
|
|
[ -d "${DESTDIR}/usr/share/icons/hicolor/" ] && gtk-update-icon-cache -fiq "${DESTDIR}/usr/share/icons/hicolor/" &>/dev/null || true; \
|
|
|
|
|
update-desktop-database --quiet &>/dev/null || true; \
|
|
|
|
|
[ -d "${DESTDIR}$/usr/share/applications" ] && touch "${DESTDIR}/usr/share/applications" &>/dev/null || true; \
|
|
|
|
|
[ -d "${DESTDIR}/usr/share/applications" ] && touch "${DESTDIR}/usr/share/applications" &>/dev/null || true; \
|
|
|
|
|
fi
|
|
|
|
|
@echo "Install: OK"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
clean:
|
|
|
|
|
@echo "Clean ..."
|
|
|
|
|
@$(RM) -rd ${CMAKE_BUILD_DIR}
|
|
|
|
|
|