From e274861f489192ee8e1f59b495dc11fe91a6708d Mon Sep 17 00:00:00 2001 From: gobo72 Date: Sat, 1 Oct 2011 23:13:56 +0000 Subject: [PATCH] =?utf8?q?R=C3=A9install=C3=A9=20GSL=20car=20il=20est=20re?= =?utf8?q?quis=20pour=20Inkscape.=20Ajout=20script=20pour=20cr=C3=A9=C3=A9?= =?utf8?q?r=20les=20associations=20mimetypes=20pour=20PCManFM.?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- config/dependencies | 4 +-- config/packages-list | 1 + stage5/hv-install-1 | 1 + stage5/misc/pcmanfm-mimelist-setup.sh | 39 +++++++++++++++++++++++++++ stage5/packages-update | 1 + stage5/pkg/pcmanfm | 6 +++++ 6 files changed, 49 insertions(+), 3 deletions(-) create mode 100755 stage5/misc/pcmanfm-mimelist-setup.sh create mode 100644 stage5/pkg/pcmanfm diff --git a/config/dependencies b/config/dependencies index 63252d7..d285b61 100644 --- a/config/dependencies +++ b/config/dependencies @@ -2,13 +2,11 @@ ${INTLTOOL}: ${PERL_MOD_XML_PARSER} ${GTKMM}: ${PANGOMM} -${INKSCAPE}: ${POPPLER} ${BOOST} ${INTLTOOL} ${GTKMM} +${INKSCAPE}: ${POPPLER} ${BOOST} ${INTLTOOL} ${GTKMM} ${GSL} ${PHP}: ${CURL} # Audio utilities ${AUDACITY}: ${LIBID3TAG} wxgtk -# Rhythmbox-0.11.6 needs latest totem -${RHYTHMBOX}: ${LIBID3TAG} # Easytag requiert id3lib pour les MP3 ${EASYTAG}: id3lib OR ${LIBID3TAG} ${AUDACIOUS}: taglib, libmowgli, mcs diff --git a/config/packages-list b/config/packages-list index beeb762..e569f92 100644 --- a/config/packages-list +++ b/config/packages-list @@ -142,6 +142,7 @@ GREP="grep-2.6.3" GRIP="grip-3.4.0" GROFF="groff-1.20.1" GRUB="grub-1.99" +GSL="gsl-1.15" GSTREAMER="gstreamer-0.10.35" GST_PLUGINS_BASE="gst-plugins-base-0.10.35" GST_PLUGINS_GOOD="gst-plugins-good-0.10.30" diff --git a/stage5/hv-install-1 b/stage5/hv-install-1 index ed26f3c..716cc96 100755 --- a/stage5/hv-install-1 +++ b/stage5/hv-install-1 @@ -7,6 +7,7 @@ check_for_root_user init_log_file ipkg ${HELP2MAN} +ipkg ${GSL} ipkg -m acnb ${CUPS} ipkg -m noac ${CUPS_PDF} ipkg -m noac ${SPLIX} diff --git a/stage5/misc/pcmanfm-mimelist-setup.sh b/stage5/misc/pcmanfm-mimelist-setup.sh new file mode 100755 index 0000000..cdf8c17 --- /dev/null +++ b/stage5/misc/pcmanfm-mimelist-setup.sh @@ -0,0 +1,39 @@ +#!/bin/bash + +# Create a list of mimetypes for PCManFM. + +MIMEAPPS_FILE="${HOME}/.local/share/applications/mimeapps.list" + +# Arg 1: Desktop file prefix +function add_mime_association() +{ + if [ ${#} -ne 1 ]; then + echo "Missing application name" + exit 1 + fi + + local APP=${1} + local DESKTOP_FILE=/usr/share/applications/${APP}.desktop + + if [ -f ${DESKTOP_FILE} ]; then + for t in $(cat ${DESKTOP_FILE} | grep MimeType | \ + sed 's!^MimeType=!!' | tr -s ";" "\n"); do + echo "${t}=${APP}.desktop;" >> ${MIMEAPPS_FILE} + done + fi +} + +cat > ${MIMEAPPS_FILE} << EOF +[Added Associations] +application/pdf=evince.desktop; +application/postscript=evince.desktop; +application/x-dvi=evince.desktop; +application/msword=abiword.desktop; +EOF + +add_mime_association "viewnior" +add_mime_association "vlc" +add_mime_association "gnumeric" +add_mime_association "inkscape" +add_mime_association "emacs" +add_mime_association "transmission" diff --git a/stage5/packages-update b/stage5/packages-update index e5f0d02..3dc0a29 100755 --- a/stage5/packages-update +++ b/stage5/packages-update @@ -9,6 +9,7 @@ source ../functions/main update_packages_init ${*} fpkg -m gnu ${HELP2MAN} +fpkg -m gnu ${GSL} fpkg -s "$(get_pkg_ver ${CUPS})" -f "${CUPS}-source" ${CUPS} \ "http://ftp.easysw.com/pub/cups" fpkg -e "tar.gz" -f "$(get_pkg_name ${CUPS_PDF})_$(get_pkg_ver ${CUPS_PDF})" ${CUPS_PDF} \ diff --git a/stage5/pkg/pcmanfm b/stage5/pkg/pcmanfm new file mode 100644 index 0000000..ab9513f --- /dev/null +++ b/stage5/pkg/pcmanfm @@ -0,0 +1,6 @@ +#!/bin/bash + +hvbuild_post() +{ + install -v -m755 ${SCRDIR}/misc/pcmanfm-mimelist-setup.sh /usr/local/bin +} -- 2.20.1