summaryrefslogtreecommitdiffabout
path: root/kabc
Side-by-side diff
Diffstat (limited to 'kabc') (more/less context) (show whitespace changes)
-rw-r--r--kabc/kabc.pro4
-rw-r--r--kabc/plugins/dir/dir.pro29
-rw-r--r--kabc/plugins/dir/resourcedir.cpp6
-rw-r--r--kabc/plugins/file/file.pro30
-rw-r--r--kabc/plugins/file/resourcefile.cpp6
5 files changed, 69 insertions, 6 deletions
diff --git a/kabc/kabc.pro b/kabc/kabc.pro
index ea4bbb7..4a8d73a 100644
--- a/kabc/kabc.pro
+++ b/kabc/kabc.pro
@@ -43,5 +43,4 @@ distributionlistdialog.h \
distributionlisteditor.h \
vcardformatplugin.h \
-formats/binaryformat.h \
formats/vcardformatplugin2.h \
picture.h \
@@ -135,4 +134,5 @@ vcard/include/generated/TextListValue-generated.h
# plugins/ldap/resourceldap.h \
# plugins/ldap/resourceldapconfig.h \
+#formats/binary/binaryformat.h \
@@ -142,5 +142,4 @@ distributionlistdialog.cpp \
distributionlisteditor.cpp \
vcardformatplugin.cpp \
-formats/binaryformat.cpp \
formats/vcardformatplugin2.cpp \
formatfactory.cpp \
@@ -213,2 +212,3 @@ vcard/TextListValue.cpp
# plugins/ldap/resourceldapconfig.cpp \
+#formats/binary/binaryformat.cpp \
diff --git a/kabc/plugins/dir/dir.pro b/kabc/plugins/dir/dir.pro
new file mode 100644
index 0000000..3db201f
--- a/dev/null
+++ b/kabc/plugins/dir/dir.pro
@@ -0,0 +1,29 @@
+TEMPLATE = lib
+CONFIG += qt warn_on release
+#release debug
+
+TARGET = microkabc_dir
+INCLUDEPATH += ../.. ../../../microkde ../../../microkde/kdecore ../../../microkde/kio/kfile ../../../qtcompat
+DESTDIR = ../../../bin
+#LIBS += -lmicrokde -lmicrokabc
+#LIBS += -L$(QPEDIR)/lib
+
+INTERFACES = \
+
+HEADERS = \
+ resourcedir.h \
+ resourcedirconfig.h
+
+SOURCES = \
+ resourcedir.cpp \
+ resourcedirconfig.cpp
+
+unix : {
+OBJECTS_DIR = obj/unix
+MOC_DIR = moc/unix
+}
+win32: {
+DEFINES += _WIN32_
+OBJECTS_DIR = obj/win
+MOC_DIR = moc/win
+} \ No newline at end of file
diff --git a/kabc/plugins/dir/resourcedir.cpp b/kabc/plugins/dir/resourcedir.cpp
index be19821..6ea2f4b 100644
--- a/kabc/plugins/dir/resourcedir.cpp
+++ b/kabc/plugins/dir/resourcedir.cpp
@@ -261,7 +261,9 @@ bool ResourceDir::lock( const QString &path )
// Create lock file
- int result = ::link( QFile::encodeName( mLockUniqueName ),
+ int result = 0;
+#ifndef _WIN32_
+ result = ::link( QFile::encodeName( mLockUniqueName ),
QFile::encodeName( lockName ) );
-
+#endif
if ( result == 0 ) {
addressBook()->emitAddressBookLocked();
diff --git a/kabc/plugins/file/file.pro b/kabc/plugins/file/file.pro
new file mode 100644
index 0000000..a5ade93
--- a/dev/null
+++ b/kabc/plugins/file/file.pro
@@ -0,0 +1,30 @@
+TEMPLATE = lib
+CONFIG += qt warn_on release
+#release debug
+
+TARGET = microkabc_file
+INCLUDEPATH += ../.. ../../../microkde ../../../microkde/kdecore ../../../microkde/kio/kfile ../../../qtcompat
+
+DESTDIR = ../../../bin
+#LIBS += -lmicrokde -lmicrokabc
+#LIBS += -L$(QPEDIR)/lib
+
+INTERFACES = \
+
+HEADERS = \
+ resourcefile.h \
+ resourcefileconfig.h
+
+SOURCES = \
+ resourcefile.cpp \
+ resourcefileconfig.cpp
+
+unix : {
+OBJECTS_DIR = obj/unix
+MOC_DIR = moc/unix
+}
+win32: {
+DEFINES += _WIN32_
+OBJECTS_DIR = obj/win
+MOC_DIR = moc/win
+} \ No newline at end of file
diff --git a/kabc/plugins/file/resourcefile.cpp b/kabc/plugins/file/resourcefile.cpp
index 3920f69..4b4c935 100644
--- a/kabc/plugins/file/resourcefile.cpp
+++ b/kabc/plugins/file/resourcefile.cpp
@@ -287,7 +287,9 @@ bool ResourceFile::lock( const QString &fileName )
// Create lock file
- int result = ::link( QFile::encodeName( mLockUniqueName ),
+ int result = 0;
+#ifndef _WIN32_
+ result = ::link( QFile::encodeName( mLockUniqueName ),
QFile::encodeName( lockName ) );
-
+#endif
if ( result == 0 ) {
addressBook()->emitAddressBookLocked();