From e69a6c4cb35d9583fff70a3d8752903537b213ee Mon Sep 17 00:00:00 2001 From: rakuco Date: Sun, 29 Jan 2012 00:03:17 +0000 Subject: Add a .desktop file for the port. An upstream version will show up in the 2.1.x series. Based on some initial work done by Denny Lin [1]. PR: 164076 [1] Submitted by: Denny Lin Reviewed by: avilla --- print/lyx/Makefile | 10 ++++++++++ print/lyx/files/lyx.desktop | 14 ++++++++++++++ print/lyx/pkg-plist | 7 +++++++ 3 files changed, 31 insertions(+) create mode 100644 print/lyx/files/lyx.desktop diff --git a/print/lyx/Makefile b/print/lyx/Makefile index 64f9f269dfe5..558a814a84ca 100644 --- a/print/lyx/Makefile +++ b/print/lyx/Makefile @@ -7,6 +7,7 @@ PORTNAME= lyx PORTVERSION= ${MAJOR_VERSION}.${MINOR_VERSION} +PORTREVISION= 1 CATEGORIES= print editors MASTER_SITES= ftp://ftp.lyx.org/pub/lyx/stable/${MAJOR_VERSION}.x/ \ http://www-ftp.lip6.fr/ftp/pub/lyx/stable/${MAJOR_VERSION}.x/ \ @@ -31,6 +32,7 @@ USE_XZ= yes USE_GMAKE= yes USE_QT_VER= 4 QT_COMPONENTS= corelib gui moc_build uic_build rcc_build +USE_GNOME= desktopfileutils USE_PYTHON= yes USE_PERL= yes GNU_CONFIGURE= yes @@ -78,6 +80,14 @@ PLIST_SUB+= NLS="" .endif post-install: +# Manually install the 48x48 icon and .desktop file. +# Will not be needed in the 2.1 series, see LyX tickets 2820 and 7919. + ${MKDIR} ${LOCALBASE}/share/icons/hicolor/48x48/apps + ${MKDIR} ${LOCALBASE}/share/applications + ${INSTALL_DATA} ${WRKSRC}/lib/images/lyx.png ${LOCALBASE}/share/icons/hicolor/48x48/apps + ${INSTALL_DATA} ${FILESDIR}/lyx.desktop ${LOCALBASE}/share/applications + ${LOCALBASE}/bin/update-desktop-database --quiet + @${CAT} ${PKGMESSAGE} .include diff --git a/print/lyx/files/lyx.desktop b/print/lyx/files/lyx.desktop new file mode 100644 index 000000000000..53f3c301d705 --- /dev/null +++ b/print/lyx/files/lyx.desktop @@ -0,0 +1,14 @@ +[Desktop Entry] +Version=1.0 +Type=Application +Name=LyX +GenericName=Document Processor +Comment=High level LaTeX frontend +Exec=lyx %F +TryExec=lyx +Icon=lyx +StartupNotify=false +StartupWMClass=Lyx +Terminal=false +Categories=Office;WordProcessor;Qt; +MimeType=text/x-lyx;application/x-lyx; diff --git a/print/lyx/pkg-plist b/print/lyx/pkg-plist index d9ffa4ea0cf6..0377fa36b2e2 100644 --- a/print/lyx/pkg-plist +++ b/print/lyx/pkg-plist @@ -32,6 +32,8 @@ bin/tex2lyx %%NLS%%share/locale/uk/LC_MESSAGES/lyx.mo %%NLS%%share/locale/zh_CN/LC_MESSAGES/lyx.mo %%NLS%%share/locale/zh_TW/LC_MESSAGES/lyx.mo +share/applications/lyx.desktop +share/icons/hicolor/48x48/apps/lyx.png %%DATADIR%%/autocorrect %%DATADIR%%/CREDITS %%DATADIR%%/bind/aqua.bind @@ -1861,5 +1863,10 @@ bin/tex2lyx @dirrm %%DATADIR%%/bind/de @dirrm %%DATADIR%%/bind @dirrm %%DATADIR%% +@dirrmtry share/icons/hicolor/48x48/apps +@dirrmtry share/icons/hicolor/48x48 +@dirrmtry share/icons/hicolor +@dirrmtry share/icons +@dirrmtry share/applications %%NLS%%@dirrmtry share/locale/ia/LC_MESSAGES/ %%NLS%%@dirrmtry share/locale/ia -- cgit