From 0449c7bcb0404151f8790b4c8f6bb4e4923d217c Mon Sep 17 00:00:00 2001 From: Max Brazhnikov Date: Tue, 19 Mar 2013 16:43:51 +0000 Subject: [PATCH] audio/aften and comms/usrp: - Cleanup cmake usage games/deng: - Convert to USE_CMAKE - Convert to new options framework and remove autodetection for openal option - Trip header Approved by: portmgr (bapt) --- audio/aften/Makefile | 10 +--------- comms/usrp/Makefile | 7 +------ games/deng/Makefile | 30 +++++++++++------------------- 3 files changed, 13 insertions(+), 34 deletions(-) diff --git a/audio/aften/Makefile b/audio/aften/Makefile index bcae5fca98db..b3caa95e8e50 100644 --- a/audio/aften/Makefile +++ b/audio/aften/Makefile @@ -11,12 +11,8 @@ COMMENT= ATSC A/52 audio encoder USE_BZIP2= yes -BUILDDIR= ${WRKSRC}/portbuild -BUILD_WRKSRC= ${BUILDDIR} -INSTALL_WRKSRC= ${BUILDDIR} - USE_CMAKE= yes -CMAKE_ARGS+= -DCMAKE_INSTALL_PREFIX:STRING="${PREFIX}" +CMAKE_OUTSOURCE= yes OPTIONS_DEFINE= SHARED_LIB CXX_BINDINGS DOUBLE OPTIONS_DEFAULT= @@ -50,8 +46,4 @@ PLIST_SUB+= LIBS="@comment " CMAKE_ARGS+= -DDOUBLE:BOOL=ON .endif -do-configure: - @${MKDIR} ${BUILDDIR} - @cd ${BUILDDIR}; ${SETENV} ${CMAKE_ENV} ${CMAKE_BIN} ${CMAKE_ARGS} .. - .include diff --git a/comms/usrp/Makefile b/comms/usrp/Makefile index f478870197e1..ccba33718b7f 100644 --- a/comms/usrp/Makefile +++ b/comms/usrp/Makefile @@ -23,6 +23,7 @@ USE_CMAKE= yes USE_GMAKE= yes USE_LDCONFIG= yes CMAKE_OUTSOURCE= yes +CMAKE_SOURCE_PATH= ${WRKSRC}/host # for excruciating debug use this -db CMAKE_ARGS= --debug-output --trace @@ -63,12 +64,6 @@ PLIST_SUB+= PUSRP2="" PLIST_SUB+= PUSRP2="@comment " .endif -do-configure: -# Configure the cmake portion of the host build - ${MKDIR} ${CONFIGURE_WRKSRC} - cd ${CONFIGURE_WRKSRC}; ${SETENV} ${CMAKE_ENV} \ - ${CMAKE_BIN} ${CMAKE_ARGS} ${WRKSRC}/host - do-build: # build host component (export PATH=${LOCALBASE}/zpu/bin:${PATH};cd ${CONFIGURE_WRKSRC}&&${GMAKE}) diff --git a/games/deng/Makefile b/games/deng/Makefile index 7f14b25235e8..fa06a02058d9 100644 --- a/games/deng/Makefile +++ b/games/deng/Makefile @@ -1,9 +1,5 @@ -# New ports collection makefile for: deng -# Date created: 25 Aug 2004 -# Whom: Igor Pokrovsky -# +# Created by: Igor Pokrovsky # $FreeBSD$ -# PORTNAME= deng PORTVERSION= 1.9.0b6.9 @@ -25,26 +21,26 @@ USE_LDCONFIG= yes USE_SDL= sdl mixer net USE_XORG= x11 USE_PYTHON= yes - -BUILDDIR= ${WRKSRC}/doomsday/portbuild -BUILD_WRKSRC= ${BUILDDIR} -INSTALL_WRKSRC= ${BUILDDIR} - USE_CMAKE= yes +CMAKE_OUTSOURCE= yes +CMAKE_SOURCE_PATH= ${WRKSRC}/doomsday CFLAGS+= -I${LOCALBASE}/include/libpng15 CMAKE_ARGS+= -DCMAKE_EXE_LINKER_FLAGS:STRING="-Wl,--export-dynamic" MAN6= doomsday.6 -OPTIONS= OPENAL "Build OpenAL sound plugin" off +OPTIONS_DEFINE= OPENAL DOCS +OPTIONS_DEFAULT= DOCS +OPENAL_DESC= Build OpenAL sound plugin -.include +.include -.if defined(WITH_OPENAL) || exists(${LOCALBASE}/lib/libopenal.so) +.if ${PORT_OPTIONS:MOPENAL} USE_OPENAL= al CMAKE_ARGS+= -DBUILDOPENAL:BOOL=ON PLIST_SUB= OPENAL="" .else +CMAKE_ARGS+= -DBUILDOPENAL:BOOL=OFF PLIST_SUB= OPENAL="@comment " .endif @@ -54,18 +50,14 @@ post-patch: -e '/TARGET_LINK_LIBRARIES/s/dl//' \ ${WRKSRC}/doomsday/CMakeLists.txt -do-configure: - @${MKDIR} ${BUILDDIR} - @cd ${BUILDDIR}; ${SETENV} ${CMAKE_ENV} ${CMAKE_BIN} ${CMAKE_ARGS} .. - post-install: @${LN} -s ${PREFIX}/bin/doomsday ${PREFIX}/bin/deng ${INSTALL_MAN} ${WRKSRC}/doomsday/engine/doc/doomsday.6 ${MANPREFIX}/man/man6/ -.ifndef (NOPORTDOCS) +.if ${PORT_OPTIONS:MDOCS} @${MKDIR} ${DOCSDIR} .for i in LICENSE changelog.txt cnsname.txt cvars.txt deddoc.txt dhistory.txt naming.txt network.txt ${INSTALL_DATA} ${WRKSRC}/doomsday/engine/doc/${i} ${DOCSDIR}/ .endfor .endif -.include +.include