Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 17 Jun 2014 15:55:28 +0000 (UTC)
From:      Brooks Davis <brooks@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r358139 - in head/lang/clang33: . files
Message-ID:  <201406171555.s5HFtSUc053181@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: brooks
Date: Tue Jun 17 15:55:27 2014
New Revision: 358139
URL: http://svnweb.freebsd.org/changeset/ports/358139
QAT: https://qat.redports.org/buildarchive/r358139/

Log:
  Add back support for scan-build.[1]
  
  Change ccc-analyzer's default compiler to clang.[2]
  
  Install unwind.h.[3]
  
  PR:		ports/185733 [1], ports/183802 [2], ports/186173 [3]

Added:
  head/lang/clang33/files/patch-tools_clang_tools_scan-build_ccc-analyzer   (contents, props changed)
Modified:
  head/lang/clang33/Makefile
  head/lang/clang33/files/patch-tools_clang_lib_Headers_Makefile
  head/lang/clang33/pkg-plist

Modified: head/lang/clang33/Makefile
==============================================================================
--- head/lang/clang33/Makefile	Tue Jun 17 15:50:05 2014	(r358138)
+++ head/lang/clang33/Makefile	Tue Jun 17 15:55:27 2014	(r358139)
@@ -52,17 +52,25 @@ CONFIGURE_ARGS+=	--enable-optimized --en
 # Build some docs manually later
 CONFIGURE_ARGS+=	--disable-docs
 
-PLIST_SUB+=		PORTVERSION=${PORTVERSION}
+PLIST_SUB+=		LLVM_SUFFIX=${LLVM_SUFFIX} \
+			PORTVERSION=${PORTVERSION}
 
-COMMANDS=	c-index-test \
+COMMANDS=	c++-analyzer \
+		c-index-test \
+		ccc-analyzer \
 		clang \
 		clang++ \
 		clang-check \
 		clang-cpp \
 		clang-format \
-		clang-tblgen
+		clang-tblgen \
+		scan-build \
+		scan-view
 FIRST_COMMAND=	${COMMANDS:C/^/XXXX/1:MXXXX*:C/^XXXX//}
 
+PORTDATA=	scanview.css \
+		sorttable.js
+
 .include <bsd.port.options.mk>
 
 .if ${PORT_OPTIONS:MASSERTS}
@@ -128,6 +136,15 @@ post-install:
 	    ${STAGEDIR}${LLVM_PREFIX}/bin/clang-cpp
 	${INSTALL_SCRIPT} ${WRKDIR}/llvm-wrapper.sh \
 	    ${STAGEDIR}${PREFIX}/bin/${FIRST_COMMAND}${LLVM_SUFFIX}
+	${INSTALL_SCRIPT} ${WRKSRC}/tools/clang/tools/scan-build/ccc-analyzer \
+	    ${WRKSRC}/tools/clang/tools/scan-build/c++-analyzer \
+	    ${WRKSRC}/tools/clang/tools/scan-build/scan-build \
+	    ${WRKSRC}/tools/clang/tools/scan-view/scan-view \
+	    ${STAGEDIR}${LLVM_PREFIX}/bin/
+	${MKDIR} ${STAGEDIR}${DATADIR}
+	${INSTALL_DATA} ${WRKSRC}/tools/clang/tools/scan-build/scanview.css \
+	    ${WRKSRC}/tools/clang/tools/scan-build/sorttable.js \
+	    ${STAGEDIR}${DATADIR}
 .for command in ${COMMANDS:C/^/XXXX/1:NXXXX*}
 	test -e ${STAGEDIR}${LLVM_PREFIX}/bin/${command}
 	${LN} -f ${STAGEDIR}${PREFIX}/bin/${FIRST_COMMAND}${LLVM_SUFFIX} \
@@ -139,6 +156,8 @@ post-install:
 .endif
 	${INSTALL_MAN} ${WRKSRC}/tools/clang/docs/tools/clang.1 \
 	    ${STAGEDIR}${MANPREFIX}/man/man1/clang${LLVM_SUFFIX}.1
+	${INSTALL_MAN} ${WRKSRC}/tools/clang/tools/scan-build/scan-build.1 \
+	    ${STAGEDIR}${MANPREFIX}/man/man1/scan-build${LLVM_SUFFIX}.1
 
 PLIST_FILE_LIST=	${COMMANDS:S|^|bin/|} \
 			lib/libclang*
@@ -155,6 +174,7 @@ build-plist:
 	    ${FIND} ${PLIST_DIR_LIST:S|^|${STAGEDIR}${LLVM_PREFIX}/|} -type f) \
 	    | ${SED} -e 's|${STAGEDIR}${PREFIX}/||' | ${SORT} >> ${PLIST}
 	echo man/man1/clang${LLVM_SUFFIX}.1.gz >> ${PLIST}
+	echo man/man1/scan-build%%LLVM_SUFFIX%%.1.gz >> ${PLIST}
 	${FIND} ${STAGEDIR}${DOCSDIR} -type f | \
 	    ${SED} -e 's|${STAGEDIR}${DOCSDIR}|%%PORTDOCS%%%%DOCSDIR%%|' | \
 	    ${SORT} >> ${PLIST}

Modified: head/lang/clang33/files/patch-tools_clang_lib_Headers_Makefile
==============================================================================
--- head/lang/clang33/files/patch-tools_clang_lib_Headers_Makefile	Tue Jun 17 15:50:05 2014	(r358138)
+++ head/lang/clang33/files/patch-tools_clang_lib_Headers_Makefile	Tue Jun 17 15:55:27 2014	(r358139)
@@ -8,7 +8,7 @@ $FreeBSD$
  HeaderDir := $(PROJ_OBJ_ROOT)/$(BuildMode)/lib/clang/$(CLANG_VERSION)/include
  
 -HEADERS := $(notdir $(wildcard $(PROJ_SRC_DIR)/*.h))
-+HEADERS := $(notdir $(wildcard $(PROJ_SRC_DIR)/*intrin*.h) altivec.h cpuid.h mm3dnow.h mm_malloc.h)
++HEADERS := $(notdir $(wildcard $(PROJ_SRC_DIR)/*intrin*.h) altivec.h cpuid.h mm3dnow.h mm_malloc.h unwind.h)
  
  OBJHEADERS := $(addprefix $(HeaderDir)/, $(HEADERS))
  

Added: head/lang/clang33/files/patch-tools_clang_tools_scan-build_ccc-analyzer
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/lang/clang33/files/patch-tools_clang_tools_scan-build_ccc-analyzer	Tue Jun 17 15:55:27 2014	(r358139)
@@ -0,0 +1,14 @@
+
+$FreeBSD: head/lang/clang34/files/patch-tools_clang_tools_scan-build_ccc-analyzer 341489 2014-01-28 00:04:46Z brooks $
+
+--- tools/clang/tools/scan-build/ccc-analyzer.orig
++++ tools/clang/tools/scan-build/ccc-analyzer
+@@ -30,7 +30,7 @@
+ my $DefaultCCompiler;
+ my $DefaultCXXCompiler;
+ 
+-if (`uname -a` =~ m/Darwin/) { 
++if (`uname -a` =~ m/(Darwin|FreeBSD)/) { 
+   $DefaultCCompiler = 'clang';
+   $DefaultCXXCompiler = 'clang++';
+ } else {

Modified: head/lang/clang33/pkg-plist
==============================================================================
--- head/lang/clang33/pkg-plist	Tue Jun 17 15:50:05 2014	(r358138)
+++ head/lang/clang33/pkg-plist	Tue Jun 17 15:55:27 2014	(r358139)
@@ -1,17 +1,25 @@
+bin/c++-analyzer33
 bin/c-index-test33
+bin/ccc-analyzer33
 bin/clang33
 bin/clang++33
 bin/clang-check33
 bin/clang-cpp33
 bin/clang-format33
 bin/clang-tblgen33
+bin/scan-build33
+bin/scan-view33
+llvm33/bin/c++-analyzer
 llvm33/bin/c-index-test
+llvm33/bin/ccc-analyzer
 llvm33/bin/clang
 llvm33/bin/clang++
 llvm33/bin/clang-check
 llvm33/bin/clang-cpp
 llvm33/bin/clang-format
 llvm33/bin/clang-tblgen
+llvm33/bin/scan-build
+llvm33/bin/scan-view
 llvm33/include/clang-c/CXCompilationDatabase.h
 llvm33/include/clang-c/CXString.h
 llvm33/include/clang-c/Index.h
@@ -438,6 +446,7 @@ llvm33/lib/clang/3.3/include/rdseedintri
 llvm33/lib/clang/3.3/include/rtmintrin.h
 llvm33/lib/clang/3.3/include/smmintrin.h
 llvm33/lib/clang/3.3/include/tmmintrin.h
+llvm33/lib/clang/3.3/include/unwind.h
 llvm33/lib/clang/3.3/include/wmmintrin.h
 llvm33/lib/clang/3.3/include/x86intrin.h
 llvm33/lib/clang/3.3/include/xmmintrin.h
@@ -466,6 +475,7 @@ llvm33/lib/libclangStaticAnalyzerCore.a
 llvm33/lib/libclangStaticAnalyzerFrontend.a
 llvm33/lib/libclangTooling.a
 man/man1/clang33.1.gz
+man/man1/scan-build%%LLVM_SUFFIX%%.1.gz
 %%PORTDOCS%%%%DOCSDIR%%/html/clang/clang.html
 %%PORTDOCS%%%%DOCSDIR%%/html/clang/manpage.css
 %%PORTDOCS%%%%DOCSDIR%%/ps/clang.ps



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201406171555.s5HFtSUc053181>