Changeset View
Standalone View
net-p2p/transmission-qt/Makefile
- This file was added.
Property | Old Value | New Value |
---|---|---|
svn:eol-style | null | native \ No newline at end of property |
svn:keywords | null | FreeBSD=%H \ No newline at end of property |
svn:mime-type | null | text/plain \ No newline at end of property |
# $FreeBSD$ | |||||
PKGNAMESUFFIX= -${FLAVOR} | |||||
MAINTAINER= crees@FreeBSD.org | |||||
COMMENT= Fast and lightweight Qt4 BitTorrent client | |||||
LIB_DEPENDS= ${GEN_LIB_DEPENDS} \ | |||||
libfontconfig.so:x11-fonts/fontconfig \ | |||||
libfreetype.so:print/freetype2 | |||||
RUN_DEPENDS= ${GEN_RUN_DEPENDS} | |||||
FLAVORS= qt4 qt5 | |||||
FLAVOR?= ${FLAVORS:[1]} | |||||
USES= gettext-runtime:run desktop-file-utils | |||||
mat: This should happen later. See [[ https://www.freebsd.org/doc/en/books/porters-handbook/porting… | |||||
.if ${FLAVOR} == qt4 | |||||
USE_QT4= moc_build qmake_build uic_build rcc_build \ | |||||
Done Inline Actions^ you should probably set the shared USES lines in the master port, with += and only add the qt-specific here. tcberner: ^ you should probably set the shared USES lines in the master port, with += and only add the qt… | |||||
Done Inline Actions^ you should add tcberner: ^ you should add
CMAKE_OFF+=USE_QT5 for the qt4 one | |||||
corelib gui dbus network xml | |||||
Done Inline ActionsWrong place in the Makefile. See Chapter 15. Order of Variables in Port Makefiles. mat: Wrong place in the Makefile. See [[ https://www.freebsd.org/doc/en/books/porters… | |||||
.endif | |||||
.if ${FLAVOR} == qt5 | |||||
Done Inline ActionsBoth USES lines are the same, extract them from the .if. mat: Both USES lines are the same, extract them from the .if. | |||||
USE_QT5= buildtools_build linguisttools_build qmake_build \ | |||||
core dbus gui network widgets | |||||
.endif | |||||
Done Inline Actionsyou need to add CMAKE_ON= #empty (to not use the default in the masterport) tcberner: you need to add
```
CMAKE_ON= #empty (to not use the default in the masterport)
``` | |||||
Done Inline Actionsmake that CMAKE_ON=ENABLE_QT othwerise you'll get -D:BOOL=TRUE added .... that needs to be fixed in cmake.mk :D tcberner: make that
```
CMAKE_ON=ENABLE_QT
```
othwerise you'll get `-D:BOOL=TRUE` added .... that… | |||||
QT_NONSTANDARD= yes | |||||
EXTRA_CONF_ARGS=--disable-cli \ | |||||
Done Inline ActionsStill wrong. up, up, with the flavors. Could you please read Chapter 15. Order of Variables in Port Makefiles, and apply its content. It would go so much faster than me having to knit pick every lines. mat: Still wrong. up, up, with the flavors.
Could you please read [[ https://www.freebsd. | |||||
--disable-daemon \ | |||||
--without-gtk \ | |||||
Done Inline Actions^typo tcberner: ^typo | |||||
--disable-mac \ | |||||
--disable-nls | |||||
${FLAVOR}_CONFLICTS_INSTALL= transmission-${FLAVORS:N${FLAVOR}} | |||||
matUnsubmitted Done Inline ActionsThat is extremely fragile, and extremely obfuscated, please expand it in the two lines it ends up doing. mat: That is extremely fragile, and extremely obfuscated, please expand it in the two lines it ends… | |||||
Done Inline Actionstcberner: [[https://www.freebsd.org/doc/en/books/porters-handbook/conflicts.html|Conflicts… | |||||
Done Inline Actions^ this still looks wrong. qt4_CONFLICTS_INSTALL= transmission-qt5 qt5_CONFLICTS_INSTALL= transmission-qt4 you could also do it a bit more magically/confusing in one line with something like ${FLAVOR}_CONFLICTS_INSTALL=transmission-${FLAVORS:N${FLAVOR}} :P tcberner: ^ this still looks wrong.
I would probably just set something like
```
qt4_CONFLICTS_INSTALL=… | |||||
Done Inline ActionsAlso, as a side-note: the master port is overriding whatever you set directly as CONFLICTS_INSTALL :) you can check the values you need by doing for example /usr/ports # make -VPKGBASE FLAVOR=qt4 -C net-p2p/transmission-qt transmission-qt4 /usr/ports # make -VPKGBASE FLAVOR=qt5 -C net-p2p/transmission-qt transmission-qt5 In the qt4-flavor you therefore want to conflict with transmission-qt5 and vice versa. tcberner: Also, as a side-note: the master port is overriding whatever you set directly as… | |||||
PLIST_SUB= QT_SUFFIX=${_QT_RELNAME} | |||||
Done Inline ActionsWrong place in the Makefile, they are flavors helpers, they should happen in the flavors block. See Chapter 15. Order of Variables in Port Makefiles. mat: Wrong place in the Makefile, they are flavors helpers, they should happen in the flavors block. | |||||
MASTERDIR= ${.CURDIR}/../transmission-cli | |||||
DESCR= ${.CURDIR}/pkg-descr | |||||
Done Inline ActionsThis is still wrong. mat: This is still wrong. | |||||
PLIST= ${.CURDIR}/pkg-plist | |||||
Done Inline ActionsThis looks bogus. mat: This looks bogus. | |||||
Done Inline Actionsqt[4,5] versions can not be installed together because several files are called 'transmission-qt' and would conflict. rigoletto: qt[4,5] versions can not be installed together because several files are called 'transmission… | |||||
Done Inline ActionsYes, good, I had understood that. The line is still wrong. mat: Yes, good, I had understood that. The line is still wrong. | |||||
SLAVEPORT= qt | |||||
post-patch: general-patch | |||||
Done Inline ActionsThis should happen earlier. mat: This should happen earlier. | |||||
@${REINPLACE_CMD} -e 's|/share/man|/man|g ; /PKGCONFIG/s| openssl||g' \ | |||||
${WRKSRC}/qt/qtr.pro | |||||
@${ECHO_CMD} 'LIBS += -l${PORT_OPTIONS:M*SSL:tl:S/openssl/crypto/}' \ | |||||
>>${WRKSRC}/qt/qtr.pro | |||||
post-build: | |||||
@(cd ${WRKSRC}/qt && ${QMAKE} ${QMAKE_ARGS} qtr.pro && ${MAKE_CMD}) | |||||
do-install: | |||||
@(cd ${WRKSRC}/qt && \ | |||||
${SETENV} INSTALL_ROOT=${STAGEDIR}${PREFIX} ${MAKE_CMD} install) | |||||
post-install: general-install | |||||
@${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/transmission-qt | |||||
@${MKDIR} ${STAGEDIR}${DOCSDIR} | |||||
${INSTALL_DATA} ${WRKSRC}/qt/README.txt \ | |||||
${STAGEDIR}${DOCSDIR}/README-${FLAVOR} | |||||
${INSTALL_DATA} ${WRKSRC}/qt/transmission-qt.desktop \ | |||||
${STAGEDIR}${PREFIX}/share/applications/ | |||||
${INSTALL_DATA} ${WRKSRC}/qt/icons/transmission.png \ | |||||
${STAGEDIR}${PREFIX}/share/pixmaps/transmission-qt.png | |||||
.include "${MASTERDIR}/Makefile" |
This should happen later. See Chapter 15. Order of Variables in Port Makefiles.