Skip to content

Commit 4b2233c

Browse files
committed
djview: choose Qt version to use based on macOS version
1 parent cd31822 commit 4b2233c

File tree

1 file changed

+20
-8
lines changed

1 file changed

+20
-8
lines changed

aqua/djview/Portfile

Lines changed: 20 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -32,24 +32,36 @@ depends_lib-append port:djvulibre
3232
universal_variant yes
3333
use_autoreconf yes
3434

35-
if {$subport eq $name} {
35+
if {${os.major} < 17} {
3636
PortGroup qt4 1.0
37-
conflicts djview-qt5
38-
} else {
37+
38+
} elseif {${os.major} < 21} {
3939
PortGroup qt5 1.0
40-
conflicts ${name}
40+
41+
# Location of qmake
42+
configure.env-append QMAKE=${prefix}/libexec/qt6/bin/qmake \
43+
QMAKESPEC=macx-clang
44+
} else {
45+
PortGroup qt6 1.0
46+
47+
qt6.depends_lib qt5compat
48+
49+
# Location of qmake
50+
configure.env-append QMAKE=${prefix}/libexec/qt6/bin/qmake \
51+
QMAKESPEC=macx-clang
4152
}
4253

4354
subport djview-qt5 {
44-
#Location of qmake
45-
configure.env-append QMAKE=${prefix}/libexec/qt5/bin/qmake \
46-
QMAKESPEC=macx-clang
55+
PortGroup obsolete 1.0
56+
57+
replaced_by djview
4758
}
4859

4960
configure.ldflags
5061
configure.args \
5162
--disable-nsdejavu \
52-
--disable-desktopfiles
63+
--disable-desktopfiles \
64+
--enable-mac
5365

5466
build.args-append V=1
5567

0 commit comments

Comments
 (0)