KFloppy is a graphical format utility for 3.5" and 5.25" floppy disks.
Totally untested in production due to lack of hardware in my notebook.
This commit is contained in:
parent
b86fd01149
commit
7824d2ea22
11
x11/kde4/kfloppy/Makefile
Normal file
11
x11/kde4/kfloppy/Makefile
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
# $OpenBSD: Makefile,v 1.1.1.1 2013/04/24 12:00:46 zhuk Exp $
|
||||||
|
|
||||||
|
COMMENT = graphical floppy format utility for KDE
|
||||||
|
DISTNAME = kfloppy-${MODKDE4_VERSION}
|
||||||
|
|
||||||
|
WANTLIB = c m pthread stdc++
|
||||||
|
WANTLIB += lib/qt4/QtDBus lib/qt4/QtGui lib/qt4/QtNetwork lib/qt4/QtSvg
|
||||||
|
WANTLIB += lib/qt4/Qt3Support lib/qt4/QtXml
|
||||||
|
WANTLIB += ${KDE4LIB}/kde3support ${KDE4LIB}/kdeui ${KDE4LIB}/kio
|
||||||
|
|
||||||
|
.include <bsd.port.mk>
|
2
x11/kde4/kfloppy/distinfo
Normal file
2
x11/kde4/kfloppy/distinfo
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
SHA256 (kde/kfloppy-4.10.2.tar.xz) = 5at2q6bl4sl0yeJRo7/VKnRIyiwv7uFFbqzKEZT/fxg=
|
||||||
|
SIZE (kde/kfloppy-4.10.2.tar.xz) = 61452
|
29
x11/kde4/kfloppy/patches/patch-floppy_cpp
Normal file
29
x11/kde4/kfloppy/patches/patch-floppy_cpp
Normal file
@ -0,0 +1,29 @@
|
|||||||
|
$OpenBSD: patch-floppy_cpp,v 1.1.1.1 2013/04/24 12:00:46 zhuk Exp $
|
||||||
|
--- floppy.cpp.orig Fri Jan 20 14:09:20 2012
|
||||||
|
+++ floppy.cpp Fri Jan 20 14:11:56 2012
|
||||||
|
@@ -151,10 +151,10 @@ FloppyData::FloppyData(QWidget * parent)
|
||||||
|
if (Ext2Filesystem::runtimeCheck()) {
|
||||||
|
filesystemComboBox->addItem(i18n("ext2"));
|
||||||
|
++numFileSystems;
|
||||||
|
- userFeedBack += i18n( "Program mke2fs found." );
|
||||||
|
+ userFeedBack += i18n( "Program for ext2 found." ) + " (" + Ext2Filesystem::getNewfs() + ")";
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
- userFeedBack += i18n( "Program mke2fs <b>not found</b>. Ext2 formatting <b>not available</b>" );
|
||||||
|
+ userFeedBack += i18n( "Program for ext2 <b>not found</b>. Ext2 formatting <b>not available</b>" );
|
||||||
|
}
|
||||||
|
userFeedBack += QLatin1String( "<br>" );
|
||||||
|
if (MinixFilesystem::runtimeCheck()) {
|
||||||
|
@@ -189,10 +189,10 @@ FloppyData::FloppyData(QWidget * parent)
|
||||||
|
if (Ext2Filesystem::runtimeCheck()) {
|
||||||
|
filesystemComboBox->addItem(i18n("ext2"));
|
||||||
|
++numFileSystems;
|
||||||
|
- userFeedBack += i18n( "Program mke2fs found." );
|
||||||
|
+ userFeedBack += i18n( "Program for ext2 found." ) + " (" + Ext2Filesystem::getNewfs() + ")";
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
- userFeedBack += i18n( "Program mke2fs <b>not found</b>. Ext2 formatting <b>not available</b>" );
|
||||||
|
+ userFeedBack += i18n( "Program for ext2 <b>not found</b>. Ext2 formatting <b>not available</b>" );
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
53
x11/kde4/kfloppy/patches/patch-format_cpp
Normal file
53
x11/kde4/kfloppy/patches/patch-format_cpp
Normal file
@ -0,0 +1,53 @@
|
|||||||
|
$OpenBSD: patch-format_cpp,v 1.1.1.1 2013/04/24 12:00:46 zhuk Exp $
|
||||||
|
--- format.cpp.orig Mon Aug 22 17:26:09 2011
|
||||||
|
+++ format.cpp Mon Feb 6 20:16:21 2012
|
||||||
|
@@ -799,22 +799,28 @@ void UFSFilesystem::exec()
|
||||||
|
|
||||||
|
|
||||||
|
/* static */ QString Ext2Filesystem::newfs = QString();
|
||||||
|
+/* static */ bool Ext2Filesystem::native_mke2fs = true;
|
||||||
|
|
||||||
|
Ext2Filesystem::Ext2Filesystem(QObject *parent) :
|
||||||
|
FloppyAction(parent)
|
||||||
|
{
|
||||||
|
DEBUGSETUP;
|
||||||
|
runtimeCheck();
|
||||||
|
- theProcessName=QLatin1String( "mke2fs" );
|
||||||
|
+ theProcessName=newfs;
|
||||||
|
setObjectName( QLatin1String("Ext2Filesystem" ));
|
||||||
|
}
|
||||||
|
|
||||||
|
/* static */ bool Ext2Filesystem::runtimeCheck()
|
||||||
|
{
|
||||||
|
DEBUGSETUP;
|
||||||
|
-
|
||||||
|
- newfs = findExecutable(QLatin1String( "mke2fs" ));
|
||||||
|
-
|
||||||
|
+
|
||||||
|
+ newfs = findExecutable( "newfs_ext2fs" );
|
||||||
|
+ if (!newfs.isEmpty()) {
|
||||||
|
+ native_mke2fs = false;
|
||||||
|
+ return true;
|
||||||
|
+ }
|
||||||
|
+ native_mke2fs = true;
|
||||||
|
+ newfs = findExecutable( "mke2fs" );
|
||||||
|
return !newfs.isEmpty();
|
||||||
|
}
|
||||||
|
|
||||||
|
@@ -861,8 +867,14 @@ void Ext2Filesystem::exec()
|
||||||
|
|
||||||
|
*p << newfs;
|
||||||
|
*p << "-q";
|
||||||
|
- if (doVerify) *p << QLatin1String( "-c" ) ;
|
||||||
|
- if (doLabel) *p << QLatin1String( "-L" ) << label ;
|
||||||
|
+ if (native_mke2fs) {
|
||||||
|
+ if (doVerify) *p << QLatin1String( "-c" ) ;
|
||||||
|
+ if (doLabel) *p << QLatin1String( "-L" ) << label ;
|
||||||
|
+ } else {
|
||||||
|
+ // newfs_ext2fs
|
||||||
|
+ if (doVerify) *p << QLatin1String( "-N" ) ;
|
||||||
|
+ if (doLabel) *p << QLatin1String( "-v" ) << label ;
|
||||||
|
+ }
|
||||||
|
|
||||||
|
*p << deviceName ;
|
||||||
|
|
18
x11/kde4/kfloppy/patches/patch-format_h
Normal file
18
x11/kde4/kfloppy/patches/patch-format_h
Normal file
@ -0,0 +1,18 @@
|
|||||||
|
$OpenBSD: patch-format_h,v 1.1.1.1 2013/04/24 12:00:46 zhuk Exp $
|
||||||
|
--- format.h.orig Fri Jan 20 13:58:28 2012
|
||||||
|
+++ format.h Fri Jan 20 14:28:40 2012
|
||||||
|
@@ -357,9 +357,13 @@ class Ext2Filesystem : public FloppyAction (public)
|
||||||
|
|
||||||
|
/// Parse output
|
||||||
|
virtual void processStdOut(K3Process*, char* b, int l);
|
||||||
|
-
|
||||||
|
+
|
||||||
|
+ /// Get found program's name
|
||||||
|
+ static const QString& getNewfs() { return newfs; }
|
||||||
|
+
|
||||||
|
protected:
|
||||||
|
static QString newfs;
|
||||||
|
+ static bool native_mke2fs;
|
||||||
|
|
||||||
|
bool doVerify,doLabel;
|
||||||
|
QString label;
|
1
x11/kde4/kfloppy/pkg/DESCR
Normal file
1
x11/kde4/kfloppy/pkg/DESCR
Normal file
@ -0,0 +1 @@
|
|||||||
|
KFloppy is a graphical format utility for 3.5" and 5.25" floppy disks.
|
15
x11/kde4/kfloppy/pkg/PLIST
Normal file
15
x11/kde4/kfloppy/pkg/PLIST
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
@comment $OpenBSD: PLIST,v 1.1.1.1 2013/04/24 12:00:46 zhuk Exp $
|
||||||
|
@bin bin/kfloppy
|
||||||
|
share/applications/kde4/KFloppy.desktop
|
||||||
|
share/doc/HTML/en/kfloppy/
|
||||||
|
share/doc/HTML/en/kfloppy/common
|
||||||
|
share/doc/HTML/en/kfloppy/index.cache.bz2
|
||||||
|
share/doc/HTML/en/kfloppy/index.docbook
|
||||||
|
share/icons/hicolor/128x128/apps/kfloppy.png
|
||||||
|
share/icons/hicolor/16x16/apps/kfloppy.png
|
||||||
|
share/icons/hicolor/22x22/apps/kfloppy.png
|
||||||
|
share/icons/hicolor/32x32/apps/kfloppy.png
|
||||||
|
share/icons/hicolor/48x48/apps/kfloppy.png
|
||||||
|
share/icons/hicolor/64x64/apps/kfloppy.png
|
||||||
|
@exec %D/bin/gtk-update-icon-cache -q -t %D/share/icons/hicolor
|
||||||
|
@unexec-delete %D/bin/gtk-update-icon-cache -q -t %D/share/icons/hicolor
|
Loading…
Reference in New Issue
Block a user