Skip to content

Commit cb719e2

Browse files
author
Christophe Dumez
committed
Fix freebsd compilation
1 parent ab8e35b commit cb719e2

5 files changed

Lines changed: 16 additions & 3 deletions

File tree

configure

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -346,6 +346,12 @@ public:
346346
if(!conf->getenv("QC_ENABLE_DEBUG").isEmpty()) {
347347
conf->addExtra("CONFIG += debug");
348348
}
349+
#ifdef Q_OS_FREEBSD
350+
conf->addLib("-lexecinfo");
351+
conf->addExtra("MANPREFIX = \$\$PREFIX");
352+
#else
353+
conf->addExtra("MANPREFIX = \$\$PREFIX/share");
354+
#endif
349355
return(QT_VERSION >= 0x040500);
350356
}
351357
};

qcm/qt4.qcm

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,12 @@ public:
2121
if(!conf->getenv("QC_ENABLE_DEBUG").isEmpty()) {
2222
conf->addExtra("CONFIG += debug");
2323
}
24+
#ifdef Q_OS_FREEBSD
25+
conf->addLib("-lexecinfo");
26+
conf->addExtra("MANPREFIX = $$PREFIX");
27+
#else
28+
conf->addExtra("MANPREFIX = $$PREFIX/share");
29+
#endif
2430
return(QT_VERSION >= 0x040500);
2531
}
2632
};

src/filesystemwatcher.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
#include <QSet>
1313
#include <iostream>
1414
#include <errno.h>
15-
#ifdef Q_WS_MAC
15+
#if defined(Q_WS_MAC) || defined(Q_OS_FREEBSD)
1616
#include <sys/param.h>
1717
#include <sys/mount.h>
1818
#include <string.h>

src/misc.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ const int UNLEN = 256;
6060
#endif
6161

6262
#ifndef Q_WS_WIN
63-
#ifdef Q_WS_MAC
63+
#if defined(Q_WS_MAC) || defined(Q_OS_FREEBSD)
6464
#include <sys/param.h>
6565
#include <sys/mount.h>
6666
#else

unixconf.pri

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,8 @@ nox {
1919
} else {
2020
man.files = ../doc/qbittorrent.1
2121
}
22-
man.path = $$PREFIX/share/man/man1/
22+
23+
man.path = $$MANPREFIX/man/man1/
2324
INSTALLS += man
2425

2526
# Menu Icon

0 commit comments

Comments
 (0)