aboutsummaryrefslogtreecommitdiff
path: root/x11-fm
diff options
context:
space:
mode:
authorJose Alonso Cardenas Marquez <acm@FreeBSD.org>2012-04-19 07:11:18 +0000
committerJose Alonso Cardenas Marquez <acm@FreeBSD.org>2012-04-19 07:11:18 +0000
commitd065611637a3e7d1820b4cf0289402b882b6780a (patch)
treefb062b4da03fc904135cff635fe9a3ec32f19561 /x11-fm
parent0a6256b52f1f403a987986cda184b4c5fbb4aab9 (diff)
downloadports-d065611637a3e7d1820b4cf0289402b882b6780a.tar.gz
ports-d065611637a3e7d1820b4cf0289402b882b6780a.zip
Notes
Diffstat (limited to 'x11-fm')
-rw-r--r--x11-fm/Makefile1
-rw-r--r--x11-fm/doublecmd/Makefile114
-rw-r--r--x11-fm/doublecmd/distinfo4
-rw-r--r--x11-fm/doublecmd/files/patch-src-dmhelpmanager.pas16
-rw-r--r--x11-fm/doublecmd/files/patch-src-uGlobsPaths.pas40
-rw-r--r--x11-fm/doublecmd/files/pkg-message.in17
-rw-r--r--x11-fm/doublecmd/pkg-descr4
7 files changed, 196 insertions, 0 deletions
diff --git a/x11-fm/Makefile b/x11-fm/Makefile
index 2574ad05faa1..20a84587cc96 100644
--- a/x11-fm/Makefile
+++ b/x11-fm/Makefile
@@ -8,6 +8,7 @@
SUBDIR += catseye-fm
SUBDIR += dfm
SUBDIR += dolphin
+ SUBDIR += doublecmd
SUBDIR += emelfm2
SUBDIR += etoile-fontmanager
SUBDIR += ezfm
diff --git a/x11-fm/doublecmd/Makefile b/x11-fm/doublecmd/Makefile
new file mode 100644
index 000000000000..cd16b46d149e
--- /dev/null
+++ b/x11-fm/doublecmd/Makefile
@@ -0,0 +1,114 @@
+# New ports collection makefile for: doublecmd
+# Date created: 01 Oct 2011
+# Whom: BeƱat Gonzalez Etxepare <bbtruk@users.sourceforge.net>
+#
+# $FreeBSD$
+#
+
+PORTNAME= doublecmd
+PORTVERSION= 0.5.1
+CATEGORIES= x11-fm
+MASTER_SITES= ${MASTER_SITE_SOURCEFORGE}
+MASTER_SITE_SUBDIR= ${PORTNAME}/Double%20Commander%20Source
+DISTNAME= ${PORTNAME}-${PORTVERSION}-src
+DISTFILES= ${PORTNAME}-${PORTVERSION}-src.tar.gz ${PORTNAME}-help-${PORTVERSION}-src.tar.gz
+
+MAINTAINER= bbtruk@users.sourceforge.net
+COMMENT= A Total Commander like file manager for the X Window System
+
+BUILD_DEPENDS= lazbuild:${PORTSDIR}/editors/lazarus
+
+ONLY_FOR_ARCHS= i386 amd64
+
+USE_DOS2UNIX= yes
+DOS2UNIX_REGEX= .*\.(pas)
+USE_GNOME= desktopfileutils
+PLIST= ${WRKDIR}/pkg-plist
+SUB_FILES= pkg-message
+PROJECT_FILE= src/doublecmd.lpi
+LAZBUILD_CMD= ${LOCALBASE}/bin/lazbuild
+WRKSRC= ${WRKDIR}/${PORTNAME}-${PORTVERSION}
+DOCSRC= ${WRKDIR}/${PORTNAME}-help-${PORTVERSION}
+
+.include <bsd.port.pre.mk>
+
+.if exists(${LOCALBASE}/bin/lazbuild) && exists(${LOCALBASE}/etc/lazbuild.cfg)
+.include "${LOCALBASE}/etc/lazbuild.cfg"
+.endif
+
+post-patch:
+ @${REINPLACE_CMD} -e 's|%%DOCSDIR%%|${DOCSDIR}|g' ${WRKSRC}/src/dmhelpmanager.pas
+ @${REINPLACE_CMD} -e 's|%%PREFIX%%|${PREFIX}|g' -e 's|%%DATADIR%%|${DATADIR}|g' \
+ ${WRKSRC}/src/uGlobsPaths.pas
+ @${REINPLACE_CMD} -e 's|.GetSize|.Size|g' ${WRKSRC}/src/platform/uClipboard.pas
+
+do-build:
+ @cd ${WRKSRC}/components && \
+ ${FIND} * -name *.lpk -exec ${LAZBUILD_CMD} --ws=${LCL_PLATFORM} "{}" \;
+ @cd ${WRKSRC} && \
+ ${LAZBUILD_CMD} --ws=${LCL_PLATFORM} ${PROJECT_FILE}
+
+post-build:
+ @${RM} -rf ${DOCSRC}/*/dev-help
+
+pre-install:
+ @${RM} -f ${PLIST}
+
+.for FILE in %%DATADIR%%/doublecmd.ext.example \
+ %%DATADIR%%/editor.col %%DATADIR%%/twilight.col %%DATADIR%%/pixmaps.txt \
+ %%DATADIR%%/default.bar %%DATADIR%%/multiarc.ini bin/doublecmd \
+ share/applications/doublecmd.desktop
+ @${ECHO_CMD} ${FILE} >> ${PLIST}
+.endfor
+
+ @cd ${WRKSRC}/language && \
+ ${FIND} * -type f | ${SORT} | ${SED} -e 's|^|%%DATADIR%%/language/|' >> ${PLIST} && \
+ ${FIND} * -type d | ${SORT} -r | ${SED} -e 's|^|@dirrm %%DATADIR%%/language/|' >> ${PLIST}
+ @${ECHO_CMD} "@dirrm %%DATADIR%%/language" >> ${PLIST}
+
+ @cd ${WRKSRC}/pixmaps && \
+ ${FIND} * -type f | ${SORT} | ${SED} -e 's|^|%%DATADIR%%/pixmaps/|' >> ${PLIST} && \
+ ${FIND} * -type d | ${SORT} -r | ${SED} -e 's|^|@dirrm %%DATADIR%%/pixmaps/|' >> ${PLIST}
+ @${ECHO_CMD} "@dirrm %%DATADIR%%/pixmaps" >> ${PLIST}
+
+ @cd ${WRKSRC}/sdk && \
+ ${FIND} * -type f | ${SORT} | ${SED} -e 's|^|%%DATADIR%%/sdk/|' >> ${PLIST} && \
+ ${FIND} * -type d | ${SORT} -r | ${SED} -e 's|^|@dirrm %%DATADIR%%/sdk/|' >> ${PLIST}
+ @${ECHO_CMD} "@dirrm %%DATADIR%%/sdk" >> ${PLIST}
+ @${ECHO_CMD} "@dirrm %%DATADIR%%" >> ${PLIST}
+
+.if !defined(NOPORTDOCS)
+ @cd ${DOCSRC} && \
+ ${FIND} * -type f | ${SORT} | ${SED} -e 's|^|%%DOCSDIR%%/|' >> ${PLIST} && \
+ ${FIND} * -type d | ${SORT} -r | ${SED} -e 's|^|@dirrm %%DOCSDIR%%/|' >> ${PLIST}
+ @${ECHO} "@dirrm %%DOCSDIR%%" >> ${PLIST}
+.endif
+
+ @${ECHO_CMD} "@exec %%LOCALBASE%%/bin/update-desktop-database > /dev/null || /usr/bin/true" >> ${PLIST}
+ @${ECHO_CMD} "@unexec %%LOCALBASE%%/bin/update-desktop-database > /dev/null || /usr/bin/true" >> ${PLIST}
+
+do-install:
+.for DIRE in language pixmaps sdk
+ @${MKDIR} ${DATADIR}/${DIRE}
+ @cd ${WRKSRC}/${DIRE} && \
+ ${FIND} * -type d -exec ${MKDIR} "${DATADIR}/${DIRE}/{}" \; && \
+ ${FIND} * -type f -exec ${INSTALL_DATA} "{}" "${DATADIR}/${DIRE}/{}" \;
+.endfor
+
+.if !defined(NOPORTDOCS)
+ @cd ${DOCSRC} && \
+ ${FIND} * -type d -exec ${MKDIR} "${DOCSDIR}/{}" \; && \
+ ${FIND} * -type f -exec ${INSTALL_DATA} "{}" "${DOCSDIR}/{}" \;
+.endif
+
+.for FILE in doublecmd.ext.example editor.col twilight.col pixmaps.txt default.bar multiarc.ini
+ ${INSTALL_DATA} ${WRKSRC}/${FILE} ${DATADIR}
+.endfor
+ ${INSTALL_PROGRAM} ${WRKSRC}/doublecmd ${PREFIX}/bin/${PORTNAME}
+ ${INSTALL_DATA} ${WRKSRC}/install/linux/doublecmd.desktop ${PREFIX}/share/applications/doublecmd.desktop
+
+post-install:
+ -@update-desktop-database
+ @${CAT} ${PKGMESSAGE}
+
+.include <bsd.port.post.mk>
diff --git a/x11-fm/doublecmd/distinfo b/x11-fm/doublecmd/distinfo
new file mode 100644
index 000000000000..42de0def4048
--- /dev/null
+++ b/x11-fm/doublecmd/distinfo
@@ -0,0 +1,4 @@
+SHA256 (doublecmd-0.5.1-src.tar.gz) = 763fcd5e22b471657a812bbfe15a75b6be8c73c1ed39f1e67ff31cbcd502a4e2
+SIZE (doublecmd-0.5.1-src.tar.gz) = 2520143
+SHA256 (doublecmd-help-0.5.1-src.tar.gz) = d9f518e05e089b71aaa31c7d4af8177e77594a02be2c316e85e061e63b4c03e5
+SIZE (doublecmd-help-0.5.1-src.tar.gz) = 10757382
diff --git a/x11-fm/doublecmd/files/patch-src-dmhelpmanager.pas b/x11-fm/doublecmd/files/patch-src-dmhelpmanager.pas
new file mode 100644
index 000000000000..4a2f4cb13fd1
--- /dev/null
+++ b/x11-fm/doublecmd/files/patch-src-dmhelpmanager.pas
@@ -0,0 +1,16 @@
+--- src/dmhelpmanager.pas 2012-03-31 17:53:05.000000000 -0500
++++ src/dmhelpmanager.pas 2012-03-31 17:53:05.000000000 -0500
+@@ -62,11 +62,11 @@
+ else
+ begin
+ gHelpLang:= ExtractDelimited(2, gPOFileName, ['.']);
+- if not mbDirectoryExists(gpExePath + 'doc' + PathDelim + gHelpLang) then
++ if not mbDirectoryExists('/usr/local/share/doc/doublecmd' + PathDelim + gHelpLang) then
+ gHelpLang:= 'en';
+ end;
+
+- HTMLHelpDatabase.BaseURL:= 'file://' + gpExePath + 'doc' + PathDelim + gHelpLang;
++ HTMLHelpDatabase.BaseURL:= 'file:///usr/local/share/doc/doublecmd' + PathDelim + gHelpLang;
+ HTMLHelpDatabase.KeywordPrefix:= '/';
+ end;
+
diff --git a/x11-fm/doublecmd/files/patch-src-uGlobsPaths.pas b/x11-fm/doublecmd/files/patch-src-uGlobsPaths.pas
new file mode 100644
index 000000000000..9ffd9762f8b2
--- /dev/null
+++ b/x11-fm/doublecmd/files/patch-src-uGlobsPaths.pas
@@ -0,0 +1,40 @@
+--- src/uGlobsPaths.pas 2012-03-31 18:38:11.000000000 -0500
++++ src/uGlobsPaths.pas 2012-03-31 18:51:02.000000000 -0500
+@@ -3,7 +3,7 @@
+ interface
+
+ var
+- gpExePath : String = ''; // executable directory
++ gpExePath : String = '%%PREFIX%%/bin'; // executable directory
+ gpCfgDir : String = ''; // directory from which configuration files are used
+ gpGlobalCfgDir : String = ''; // config dir global for all user
+ gpCmdLineCfgDir : String = ''; // config dir passed on the command line
+@@ -26,10 +26,10 @@
+ procedure LoadPaths;
+ begin
+ OnGetApplicationName := @GetAppName;
+- gpExePath := ExtractFilePath(TryReadAllLinks(ParamStrUTF8(0)));
++// gpExePath := ExtractFilePath(TryReadAllLinks(ParamStrUTF8(0)));
+ DCDebug('Executable directory: ', gpExePath);
+
+- gpGlobalCfgDir := gpExePath;
++ gpGlobalCfgDir := '%%DATADIR%%';
+ if gpCmdLineCfgDir <> EmptyStr then
+ begin
+ if GetPathType(gpCmdLineCfgDir) <> ptAbsolute then
+@@ -48,12 +48,12 @@
+ end;
+
+ gpCfgDir := IncludeTrailingPathDelimiter(gpCfgDir);
+- gpLngDir := gpExePath + 'language' + DirectorySeparator;
+- gpPixmapPath := gpExePath + 'pixmaps' + DirectorySeparator;
++ gpLngDir := '%%DATADIR%%/' + 'language' + DirectorySeparator;
++ gpPixmapPath := '%%DATADIR%%/' + 'pixmaps' + DirectorySeparator;
+ gpCacheDir := GetAppCacheDir;
+
+ // set up environment variables
+- mbSetEnvironmentVariable('commander_path', ExcludeTrailingBackslash(gpExePath));
++ mbSetEnvironmentVariable('commander_path', ExcludeTrailingBackslash('%%DATADIR%%/'));
+ end;
+
+ end.
diff --git a/x11-fm/doublecmd/files/pkg-message.in b/x11-fm/doublecmd/files/pkg-message.in
new file mode 100644
index 000000000000..a64e89061461
--- /dev/null
+++ b/x11-fm/doublecmd/files/pkg-message.in
@@ -0,0 +1,17 @@
+###############################################################################
+
+Double Commander was installed
+
+1) This is BETA software, so use it at your own risk
+
+2) You can run it using:
+
+ # doublecmd
+
+3) Plugins are currently not available for FreeBSD. For more information see:
+ http://sourceforge.net/apps/mediawiki/doublecmd/index.php?title=Issues_with_FPC,_Lazarus
+ in "Loading shared libraries on FreeBSD doesn't work" section
+
+4) Enjoy it ;)
+
+###############################################################################
diff --git a/x11-fm/doublecmd/pkg-descr b/x11-fm/doublecmd/pkg-descr
new file mode 100644
index 000000000000..ca5e23c04e2f
--- /dev/null
+++ b/x11-fm/doublecmd/pkg-descr
@@ -0,0 +1,4 @@
+Double Commander is a cross platform open source file manager with two panels
+side by side. It is inspired by Total Commander and features some new ideas.
+
+WWW: http://doublecmd.sourceforge.net/