pkg-cmake: fix host-cmake-package type
authorRyan Barnett <ryan.barnett@rockwellcollins.com>
Fri, 23 Jan 2015 20:17:04 +0000 (14:17 -0600)
committerThomas Petazzoni <thomas.petazzoni@free-electrons.com>
Sun, 25 Jan 2015 17:47:30 +0000 (18:47 +0100)
When trying to compile a host-cmake-package type such as host-cdrkit,
an error happens in regards to HOSTCC and HOSTCXX not being found.

  /bin/sh: HOSTCC: command not found
  /bin/sh: HOSTCXX: command not found

This due to the fact that the environment is incorrectly configured by
having the following:

  -DCMAKE_C_COMPILER=""$(HOSTCC)"" -DCMAKE_CXX_COMPILER=""$(HOSTCXX)""

This is due to having too many dollar signs. The fix is to remove the
extra dollar sign.

Also removing the unncessary quotes since the HOSTCC/HOSTCXX will
already contain quotes. This could cause an issue with make as double
quotes are not interpreted by make.

Minor formatting fix too.

Signed-off-by: Ryan Barnett <ryan.barnett@rockwellcollins.com>
Acked-by: Samuel Martin <s.martin49@gmail.com>
Reviewed-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
package/pkg-cmake.mk

index 1037513e97c4923515f2917c453308a590791178..6c9955d2431a26786cc03c681fb03e28615cc835 100644 (file)
 
 # Set compiler variables.
 ifeq ($(BR2_CCACHE),y)
-CMAKE_HOST_C_COMPILER="$(HOST_DIR)/usr/bin/ccache"
-CMAKE_HOST_CXX_COMPILER="$(HOST_DIR)/usr/bin/ccache"
-CMAKE_HOST_C_COMPILER_ARG1="$(HOSTCC_NOCCACHE)"
-CMAKE_HOST_CXX_COMPILER_ARG1="$(HOSTCXX_NOCCACHE)"
+CMAKE_HOST_C_COMPILER = $(HOST_DIR)/usr/bin/ccache
+CMAKE_HOST_CXX_COMPILER = $(HOST_DIR)/usr/bin/ccache
+CMAKE_HOST_C_COMPILER_ARG1 = $(HOSTCC_NOCCACHE)
+CMAKE_HOST_CXX_COMPILER_ARG1 = $(HOSTCXX_NOCCACHE)
 else
-CMAKE_HOST_C_COMPILER="$$(HOSTCC)"
-CMAKE_HOST_CXX_COMPILER="$$(HOSTCXX)"
+CMAKE_HOST_C_COMPILER = $(HOSTCC)
+CMAKE_HOST_CXX_COMPILER = $(HOSTCXX)
 endif
 
 ################################################################################