Re: [PATCH] Fix QT4 moc, cflags libs detection on dual QT3/Qt4 systems

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, 10 Sep 2010 19:01:14 +0200 Alexander Stein wrote:

> On system with QT3 and QT4 qmake in PATH may be from QT3. So we use
> pkg-config for proper QT4 detection.
> By reqesting cflags and libs for either QtCore, QtGui and QtSupport include
> dirs and libs get listed several times, but so we won't mis anything
> 
> CC: Michal Marek <mmarek@xxxxxxx>
> Signed-off-by: Alexander Stein <alexander.stein@xxxxxxxxxxxxxxxxxxxxxxxxx>

That works.  Thanks.

Acked-by: Randy Dunlap <rdunlap@xxxxxxxxxxxx>


> ---
>  scripts/kconfig/Makefile |   10 ++++------
>  1 files changed, 4 insertions(+), 6 deletions(-)
> 
> diff --git a/scripts/kconfig/Makefile b/scripts/kconfig/Makefile
> index cef3f75..996059e 100644
> --- a/scripts/kconfig/Makefile
> +++ b/scripts/kconfig/Makefile
> @@ -273,12 +273,10 @@ $(obj)/.tmp_qtcheck:
>  	      moc="/usr/bin/moc"; \
>  	    fi; \
>  	else \
> -	  headerpath="\$$(shell qmake -query QT_INSTALL_HEADERS)"; \
> -	  libpath="\$$(shell qmake -query QT_INSTALL_LIBS)"; \
> -	  binpath="\$$(shell qmake -query QT_INSTALL_BINS)"; \
> -	  cflags="-I$$headerpath -I$$headerpath/QtCore -I$$headerpath/QtGui -I$$headerpath/Qt3Support -DQT3_SUPPORT"; \
> -	  libs="-L$$libpath -Wl,-rpath,$$libpath -lQtCore -lQtGui -lQt3Support"; \
> -	  moc="$$binpath/moc"; \
> +	  cflags="\$$(shell pkg-config QtCore --cflags) \$$(shell pkg-config QtGui --cflags) \$$(shell pkg-config Qt3Support --cflags)"; \
> +	  libs="\$$(shell pkg-config QtCore --libs) \$$(shell pkg-config QtGui --libs) \$$(shell pkg-config Qt3Support --libs)"; \
> +	  binpath="\$$(shell pkg-config QtCore --variable=prefix)"; \
> +	  moc="$$binpath/bin/moc"; \
>  	fi; \
>  	echo "KC_QT_CFLAGS=$$cflags" > $@; \
>  	echo "KC_QT_LIBS=$$libs" >> $@; \
> -- 
> 1.7.2.2
> 


---
~Randy
*** Remember to use Documentation/SubmitChecklist when testing your code ***
--
To unsubscribe from this list: send the line "unsubscribe linux-kbuild" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux&nblp;USB Development]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite Secrets]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux