4
0
mirror of https://github.com/QuasarApp/qca.git synced 2025-05-11 18:29:33 +00:00

build system

svn path=/trunk/kdesupport/qca/; revision=445718
This commit is contained in:
Justin Karneges 2005-08-11 19:07:36 +00:00
parent 8c76a8245b
commit c774979d18
4 changed files with 86 additions and 11 deletions

@ -0,0 +1,28 @@
/*
-----BEGIN QCMOD-----
name: extra
-----END QCMOD-----
*/
class qc_extra : public ConfObj
{
public:
qc_extra(Conf *c) : ConfObj(c) {}
QString name() const { return "extra"; }
QString shortname() const { return "extra"; }
// no output
QString checkString() const { return QString(); }
bool exec()
{
// install into plugins path
QString str;
str += QString(
"target.path=%1/crypto\n"
"INSTALLS += target\n"
).arg(QLibraryInfo::location(QLibraryInfo::PluginsPath));
conf->addExtra(str);
return true;
}
};

@ -1,15 +1,10 @@
TEMPLATE = lib
CONFIG += plugin
QT -= gui
#CONFIG += release
CONFIG += debug
QCA_INC = ../../include/QtCrypto
QCA_LIB = ../..
INCLUDEPATH += $$QCA_INC
LIBS += -L$$QCA_LIB -lqca
TEMPLATE = lib
CONFIG += plugin
QT -= gui
CONFIG += crypto
windows:LIBS += -ladvapi32
@ -24,5 +19,4 @@ SOURCES += \
$$GPG_BASE/gpgop.cpp \
$$GPG_BASE/qca-gnupg.cpp
#include(conf.pri)
#include(extra.pri)
include(conf.pri)

@ -0,0 +1,12 @@
<qconf>
<name>qca-gnupg</name>
<profile>qca-gnupg.pro</profile>
<noprefix/>
<dep type='qca'>
<required/>
</dep>
<dep type='extra'>
<required/>
</dep>
<moddir>.</moddir>
</qconf>

41
plugins/qca-gnupg/qca.qcm Normal file

@ -0,0 +1,41 @@
/*
-----BEGIN QCMOD-----
name: QCA 2.0
-----END QCMOD-----
*/
//----------------------------------------------------------------------------
// qc_qca
//----------------------------------------------------------------------------
class qc_qca : public ConfObj
{
public:
qc_qca(Conf *c) : ConfObj(c) {}
QString name() const { return "QCA 2.0"; }
QString shortname() const { return "qca"; }
bool exec()
{
// test for "crypto" feature and check qca version number
QString proextra =
"CONFIG += qt crypto\n"
"QT -= gui\n";
QString str =
"#include <QtCrypto>\n"
"\n"
"int main()\n"
"{\n"
" unsigned long x = QCA_VERSION;\n"
" if(x >= 0x020000) return 0; else return 1;\n"
"}\n";
int ret;
if(!conf->doCompileAndLink(str, QStringList(), QString(), proextra, &ret))
return false;
if(ret != 0)
return false;
return true;
}
};