From nobody@FreeBSD.org  Sun Sep 18 11:47:43 2011
Return-Path: <nobody@FreeBSD.org>
Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34])
	by hub.freebsd.org (Postfix) with ESMTP id 3DB19106564A
	for <freebsd-gnats-submit@FreeBSD.org>; Sun, 18 Sep 2011 11:47:43 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from red.freebsd.org (red.freebsd.org [IPv6:2001:4f8:fff6::22])
	by mx1.freebsd.org (Postfix) with ESMTP id 2BFA78FC08
	for <freebsd-gnats-submit@FreeBSD.org>; Sun, 18 Sep 2011 11:47:43 +0000 (UTC)
Received: from red.freebsd.org (localhost [127.0.0.1])
	by red.freebsd.org (8.14.4/8.14.4) with ESMTP id p8IBlgaW000454
	for <freebsd-gnats-submit@FreeBSD.org>; Sun, 18 Sep 2011 11:47:42 GMT
	(envelope-from nobody@red.freebsd.org)
Received: (from nobody@localhost)
	by red.freebsd.org (8.14.4/8.14.4/Submit) id p8IBlg0G000453;
	Sun, 18 Sep 2011 11:47:42 GMT
	(envelope-from nobody)
Message-Id: <201109181147.p8IBlg0G000453@red.freebsd.org>
Date: Sun, 18 Sep 2011 11:47:42 GMT
From: Oleksii <oleksii.tsai@googlemail.com>
To: freebsd-gnats-submit@FreeBSD.org
Subject: Build devel/libdispatch with blocks support fails due to missing clang
X-Send-Pr-Version: www-3.1
X-GNATS-Notify:

>Number:         160800
>Category:       ports
>Synopsis:       Build devel/libdispatch with blocks support fails due to missing clang
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    stas
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sun Sep 18 11:50:13 UTC 2011
>Closed-Date:    Tue Sep 27 20:40:50 UTC 2011
>Last-Modified:  Tue Sep 27 20:50:08 UTC 2011
>Originator:     Oleksii
>Release:        FreeBSD 8.2
>Organization:
Tsai
>Environment:
FreeBSD zirco.compal.nb 8.2-RELEASE-p2 FreeBSD 8.2-RELEASE-p2 #3: Sat Sep  3 09:44:33 EEST 2011     lyutsai@zirco.compal.nb:/usr/obj/usr/src/sys/COMPAL  i386
>Description:
The build of devel/libdispatch that was configured with blocks support fails because the configure script is unable to find the clang executable.
>How-To-Repeat:
# cd /usr/ports/devel/libdispatch
# make
>Fix:
The configure script looks for /usr/local/clang because the Makefile says so:

CONFIGURE_ENV+=   CC="${LOCALBASE}/clang"

However, LOCALBASE points to /usr/local only and apparently 'bin' is missing.

The attached patch fixes this and in addition to that sets the CPPFLAGS to contain ${LOCALBASE}/include so that Block_private.h and Block.h headers are visible during the build.

Patch attached with submission follows:

*** /usr/ports/devel/libdispatch/Makefile.orig	2011-09-18 13:31:48.000000000 +0300
--- /usr/ports/devel/libdispatch/Makefile	2011-09-18 14:37:11.000000000 +0300
***************
*** 90,96 ****
  RUN_DEPENDS+=	clang:${PORTSDIR}/devel/llvm-devel \
  		${LOCALBASE}/lib/libBlocksRuntime.so:${PORTSDIR}/devel/compiler-rt
  CONFIGURE_ARGS+=	--with-blocks-runtime=${LOCALBASE}/lib
! CONFIGURE_ENV+=	CC="${LOCALBASE}/clang"
  . else
  CONFIGURE_ARGS+=	--with-blocks-runtime=/usr/lib
  CONFIGURE_ENV+=	CC="/usr/bin/clang"
--- 90,96 ----
  RUN_DEPENDS+=	clang:${PORTSDIR}/devel/llvm-devel \
  		${LOCALBASE}/lib/libBlocksRuntime.so:${PORTSDIR}/devel/compiler-rt
  CONFIGURE_ARGS+=	--with-blocks-runtime=${LOCALBASE}/lib
! CONFIGURE_ENV+=	CC="${LOCALBASE}/bin/clang" CPPFLAGS="-I${LOCALBASE}/include"
  . else
  CONFIGURE_ARGS+=	--with-blocks-runtime=/usr/lib
  CONFIGURE_ENV+=	CC="/usr/bin/clang"


>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-ports-bugs->stas 
Responsible-Changed-By: edwin 
Responsible-Changed-When: Sun Sep 18 11:50:29 UTC 2011 
Responsible-Changed-Why:  
Over to maintainer (via the GNATS Auto Assign Tool) 

http://www.freebsd.org/cgi/query-pr.cgi?pr=160800 
State-Changed-From-To: open->closed 
State-Changed-By: pav 
State-Changed-When: Tue Sep 27 20:40:41 UTC 2011 
State-Changed-Why:  
Committed, thanks 

http://www.freebsd.org/cgi/query-pr.cgi?pr=160800 

From: dfilter@FreeBSD.ORG (dfilter service)
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: ports/160800: commit references a PR
Date: Tue, 27 Sep 2011 20:40:44 +0000 (UTC)

 pav         2011-09-27 20:40:35 UTC
 
   FreeBSD ports repository
 
   Modified files:
     devel/libdispatch    Makefile 
   Log:
   - Unbreak, fix depobj, fix configure
   
   PR:             ports/160800 (partially)
   Submitted by:   Oleksii Tsai <oleksii.tsai@googlemail.com>
   
   Revision  Changes    Path
   1.17      +3 -5      ports/devel/libdispatch/Makefile
 _______________________________________________
 cvs-all@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/cvs-all
 To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
 
>Unformatted:
