Skip to content

Commit

Permalink
Remove bundled libidn
Browse files Browse the repository at this point in the history
  • Loading branch information
Sergey Il'inykh committed Jul 22, 2013
1 parent 816f628 commit ca4c9bf
Show file tree
Hide file tree
Showing 19 changed files with 60 additions and 17,626 deletions.
3 changes: 3 additions & 0 deletions iris.qc
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@
<dep type='universal'>
<required/>
</dep>
<dep type='idn'>
<required/>
</dep>
<dep type='qca'>
<required/>
</dep>
Expand Down
56 changes: 56 additions & 0 deletions qcm/idn.qcm
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
/*
-----BEGIN QCMOD-----
name: libidn
arg: with-idn-inc=[path],Path to libidn include files
arg: with-idn-lib=[path],Path to libidn library or framework files
-----END QCMOD-----
*/

//----------------------------------------------------------------------------
// qc_idn
//----------------------------------------------------------------------------
class qc_idn : public ConfObj
{
public:
qc_idn(Conf *c) : ConfObj(c) {}
QString name() const { return "LibIDN"; }
QString shortname() const { return "libidn"; }
bool exec()
{
QString idn_incdir, idn_libdir;
idn_incdir = conf->getenv("QC_WITH_IDN_INC");
idn_libdir = conf->getenv("QC_WITH_IDN_LIB");

if (!idn_incdir.isEmpty() || !idn_libdir.isEmpty()) { // prefer this if given
if ((!idn_incdir.isEmpty() && conf->checkHeader(idn_incdir, "stringprep.h")) ||
(idn_incdir.isEmpty() && conf->findHeader("stringprep.h", QStringList(), &idn_incdir))) {
conf->addIncludePath(idn_incdir);
} else {
printf("Headers not found!\n");
return false;
}

if((!idn_libdir.isEmpty() && conf->checkLibrary(idn_libdir, "idn")) ||
(idn_libdir.isEmpty() && conf->findLibrary("idn", &idn_libdir))) {
conf->addLib(idn_libdir.isEmpty()? "-lidn" : QString("-L%1 -lidn").arg(idn_libdir));
} else {
printf("Libraries not found!\n");
return false;
}
return true;
}

QStringList incs;
QString version, libs, other;
if(conf->findPkgConfig("libidn", VersionAny, QString::null, &version, &incs, &libs, &other))
{
for(int n = 0; n < incs.count(); ++n)
conf->addIncludePath(incs[n]);
if(!libs.isEmpty())
conf->addLib(libs);
return true;
}

return false;
}
};
3 changes: 0 additions & 3 deletions src/irisnet/corelib/corelib.pri
Original file line number Diff line number Diff line change
@@ -1,8 +1,5 @@
QT *= network

# libidn
#LIBS += -lidn

include(../../jdns/jdns.pri)
INCLUDEPATH += $$PWD/../../jdns

Expand Down
658 changes: 0 additions & 658 deletions src/libidn/gunicomp.h

This file was deleted.

10,362 changes: 0 additions & 10,362 deletions src/libidn/gunidecomp.h

This file was deleted.

293 changes: 0 additions & 293 deletions src/libidn/idn-int.h

This file was deleted.

Loading

0 comments on commit ca4c9bf

Please sign in to comment.