git: e48f39f4e922 - main - misc/raspberrypi-userland: fix build

From: Dmitri Goutnik <dmgk_at_FreeBSD.org>
Date: Thu, 30 Jun 2022 13:44:16 UTC
The branch main has been updated by dmgk:

URL: https://cgit.FreeBSD.org/ports/commit/?id=e48f39f4e9221483c54c5cc380ca5f6a167e1312

commit e48f39f4e9221483c54c5cc380ca5f6a167e1312
Author:     Robert Clausecker <fuz@fuz.su>
AuthorDate: 2022-06-28 12:07:09 +0000
Commit:     Dmitri Goutnik <dmgk@FreeBSD.org>
CommitDate: 2022-06-30 13:42:39 +0000

    misc/raspberrypi-userland: fix build
    
    - patch out -Werror
    - add <libgen.h> for basename in raspicam and patch
      for const correctness
    
    PR:             264940
---
 misc/raspberrypi-userland/Makefile                 |  2 +-
 ...applications_android_apps_vidtex_CMakeLists.txt | 10 +++++++
 ..._applications_linux_apps_dtmerge_CMakeLists.txt | 11 ++++++++
 ...pplications_linux_apps_dtoverlay_CMakeLists.txt | 13 +++++++--
 ...__applications_linux_apps_gencmd_CMakeLists.txt | 11 ++++++++
 ...lications_linux_apps_hello__pi_Makefile.include |  6 ++---
 ...applications_linux_apps_raspicam_CMakeLists.txt | 11 ++++++++
 ...__applications_linux_apps_raspicam_RaspiStill.c | 31 ++++++++++++++++++++++
 ...pplications_linux_apps_raspicam_RaspiStillYUV.c | 31 ++++++++++++++++++++++
 ...st__applications_linux_apps_raspicam_RaspiVid.c | 31 ++++++++++++++++++++++
 ..._applications_linux_apps_raspicam_RaspiVidYUV.c | 31 ++++++++++++++++++++++
 ...st__applications_linux_apps_smem_CMakeLists.txt | 11 ++++++++
 ...pplications_linux_libs_bcm__host_CMakeLists.txt | 11 ++++++++
 ...host__applications_linux_libs_sm_CMakeLists.txt | 11 ++++++++
 .../files/patch-interface_mmal_CMakeLists.txt      | 11 ++++++++
 .../files/patch-interface_vcos_CMakeLists.txt      | 11 ++++++++
 .../patch-interface_vcos_pthreads_CMakeLists.txt   | 11 ++++++++
 ...terface_vmcs__host_linux_vcfiled_CMakeLists.txt | 11 ++++++--
 .../files/patch-makefiles_cmake_vmcs.cmake         |  4 +--
 19 files changed, 259 insertions(+), 10 deletions(-)

diff --git a/misc/raspberrypi-userland/Makefile b/misc/raspberrypi-userland/Makefile
index 16a3ab38a667..a4440acfcffe 100644
--- a/misc/raspberrypi-userland/Makefile
+++ b/misc/raspberrypi-userland/Makefile
@@ -2,7 +2,7 @@
 
 PORTNAME=	raspberrypi-userland
 PORTVERSION=	20161026
-PORTREVISION=	2
+PORTREVISION=	3
 CATEGORIES=	misc
 
 MAINTAINER=	ports@FreeBSD.org
diff --git a/misc/raspberrypi-userland/files/patch-host__applications_android_apps_vidtex_CMakeLists.txt b/misc/raspberrypi-userland/files/patch-host__applications_android_apps_vidtex_CMakeLists.txt
new file mode 100644
index 000000000000..4268f7696e3a
--- /dev/null
+++ b/misc/raspberrypi-userland/files/patch-host__applications_android_apps_vidtex_CMakeLists.txt
@@ -0,0 +1,10 @@
+--- host_applications/android/apps/vidtex/CMakeLists.txt.orig	2016-10-24 19:59:54 UTC
++++ host_applications/android/apps/vidtex/CMakeLists.txt
+@@ -1,6 +1,6 @@
+ cmake_minimum_required(VERSION 2.8)
+ 
+-SET(COMPILE_DEFINITIONS -Werror -Wall)
++SET(COMPILE_DEFINITIONS -Wall)
+ include_directories(${PROJECT_SOURCE_DIR}/host_applications/linux/libs/bcm_host/include)
+ 
+ set (VIDTEX_SOURCES
diff --git a/misc/raspberrypi-userland/files/patch-host__applications_linux_apps_dtmerge_CMakeLists.txt b/misc/raspberrypi-userland/files/patch-host__applications_linux_apps_dtmerge_CMakeLists.txt
new file mode 100644
index 000000000000..9b08f28a1290
--- /dev/null
+++ b/misc/raspberrypi-userland/files/patch-host__applications_linux_apps_dtmerge_CMakeLists.txt
@@ -0,0 +1,11 @@
+--- host_applications/linux/apps/dtmerge/CMakeLists.txt.orig	2016-10-24 19:59:54 UTC
++++ host_applications/linux/apps/dtmerge/CMakeLists.txt
+@@ -4,7 +4,7 @@ get_filename_component (VIDEOCORE_ROOT ../../../.. ABS
+ include (${VIDEOCORE_ROOT}/makefiles/cmake/global_settings.cmake)
+ 
+ if (NOT WIN32)
+-   add_definitions(-Wall -Werror)
++   add_definitions(-Wall)
+ endif ()
+ 
+ include_directories (
diff --git a/misc/raspberrypi-userland/files/patch-host__applications_linux_apps_dtoverlay_CMakeLists.txt b/misc/raspberrypi-userland/files/patch-host__applications_linux_apps_dtoverlay_CMakeLists.txt
index 36bbbbf8e776..961530447ae0 100644
--- a/misc/raspberrypi-userland/files/patch-host__applications_linux_apps_dtoverlay_CMakeLists.txt
+++ b/misc/raspberrypi-userland/files/patch-host__applications_linux_apps_dtoverlay_CMakeLists.txt
@@ -1,6 +1,15 @@
---- host_applications/linux/apps/dtoverlay/CMakeLists.txt.orig	2016-10-30 UTC
+--- host_applications/linux/apps/dtoverlay/CMakeLists.txt.orig	2016-10-24 19:59:54 UTC
 +++ host_applications/linux/apps/dtoverlay/CMakeLists.txt
-@@ -22,12 +22,4 @@ add_custom_command(TARGET dtoverlay POST
+@@ -4,7 +4,7 @@ get_filename_component (VIDEOCORE_ROOT ../../../.. ABS
+ include (${VIDEOCORE_ROOT}/makefiles/cmake/global_settings.cmake)
+ 
+ if (NOT WIN32)
+-   add_definitions(-Wall -Werror)
++   add_definitions(-Wall)
+ endif ()
+ 
+ include_directories (
+@@ -22,12 +22,4 @@ add_custom_command(TARGET dtoverlay POST_BUILD COMMAND
  install(FILES ${CMAKE_CURRENT_BINARY_DIR}/dtparam DESTINATION bin)
  
  set(DTOVERLAY_SCRIPTS dtoverlay-pre dtoverlay-post)
diff --git a/misc/raspberrypi-userland/files/patch-host__applications_linux_apps_gencmd_CMakeLists.txt b/misc/raspberrypi-userland/files/patch-host__applications_linux_apps_gencmd_CMakeLists.txt
new file mode 100644
index 000000000000..d997d0dbcc00
--- /dev/null
+++ b/misc/raspberrypi-userland/files/patch-host__applications_linux_apps_gencmd_CMakeLists.txt
@@ -0,0 +1,11 @@
+--- host_applications/linux/apps/gencmd/CMakeLists.txt.orig	2016-10-24 19:59:54 UTC
++++ host_applications/linux/apps/gencmd/CMakeLists.txt
+@@ -4,7 +4,7 @@ if (WIN32)
+    set(VCOS_PLATFORM win32)
+ else ()
+    set(VCOS_PLATFORM pthreads)
+-   add_definitions(-Wall -Werror)
++   add_definitions(-Wall)
+ endif ()
+ 
+ include_directories( ../../../.. 
diff --git a/misc/raspberrypi-userland/files/patch-host__applications_linux_apps_hello__pi_Makefile.include b/misc/raspberrypi-userland/files/patch-host__applications_linux_apps_hello__pi_Makefile.include
index add819abf48b..5033877efa07 100644
--- a/misc/raspberrypi-userland/files/patch-host__applications_linux_apps_hello__pi_Makefile.include
+++ b/misc/raspberrypi-userland/files/patch-host__applications_linux_apps_hello__pi_Makefile.include
@@ -1,8 +1,8 @@
---- host_applications/linux/apps/hello_pi/Makefile.include.orig	2015-03-10 14:32:31 UTC
+--- host_applications/linux/apps/hello_pi/Makefile.include.orig	2016-10-24 19:59:54 UTC
 +++ host_applications/linux/apps/hello_pi/Makefile.include
-@@ -3,7 +3,7 @@ CFLAGS+=-DSTANDALONE -D__STDC_CONSTANT_M
+@@ -3,7 +3,7 @@ CFLAGS+=-DSTANDALONE -D__STDC_CONSTANT_MACROS -D__STDC
  
- LDFLAGS+=-L$(SDKSTAGE)/opt/vc/lib/ -lGLESv2 -lEGL -lopenmaxil -lbcm_host -lvcos -lvchiq_arm -lpthread -lrt -lm -L../libs/ilclient -L../libs/vgfont
+ LDFLAGS+=-L$(SDKSTAGE)/opt/vc/lib/ -lbrcmGLESv2 -lbrcmEGL -lopenmaxil -lbcm_host -lvcos -lvchiq_arm -lpthread -lrt -lm -L$(SDKSTAGE)/opt/vc/src/hello_pi/libs/ilclient -L$(SDKSTAGE)/opt/vc/src/hello_pi/libs/vgfont
  
 -INCLUDES+=-I$(SDKSTAGE)/opt/vc/include/ -I$(SDKSTAGE)/opt/vc/include/interface/vcos/pthreads -I$(SDKSTAGE)/opt/vc/include/interface/vmcs_host/linux -I./ -I$(SDKSTAGE)/opt/vc/src/hello_pi/libs/ilclient -I$(SDKSTAGE)/opt/vc/src/hello_pi/libs/vgfont
 +INCLUDES+=-I$(SDKSTAGE)/opt/vc/include/ -I$(SDKSTAGE)/opt/vc/include/interface/vcos/pthreads -I$(SDKSTAGE)/opt/vc/include/interface/vmcs_host/linux -I./ -I$(SDKSTAGE)/opt/vc/src/hello_pi/libs/ilclient -I$(SDKSTAGE)/opt/vc/src/hello_pi/libs/vgfont -ILOCALBASE/include/freetype2
diff --git a/misc/raspberrypi-userland/files/patch-host__applications_linux_apps_raspicam_CMakeLists.txt b/misc/raspberrypi-userland/files/patch-host__applications_linux_apps_raspicam_CMakeLists.txt
new file mode 100644
index 000000000000..88dc0a4fe9d5
--- /dev/null
+++ b/misc/raspberrypi-userland/files/patch-host__applications_linux_apps_raspicam_CMakeLists.txt
@@ -0,0 +1,11 @@
+--- host_applications/linux/apps/raspicam/CMakeLists.txt.orig	2016-10-24 19:59:54 UTC
++++ host_applications/linux/apps/raspicam/CMakeLists.txt
+@@ -1,7 +1,7 @@
+ 
+ # raspistill/raspivid/raspiyuv
+ 
+-SET(COMPILE_DEFINITIONS -Werror)
++SET(COMPILE_DEFINITIONS)
+ 
+ include_directories(${PROJECT_SOURCE_DIR}/host_applications/linux/libs/bcm_host/include)
+ include_directories(${PROJECT_SOURCE_DIR}/host_applications/linux/apps/raspicam/)
diff --git a/misc/raspberrypi-userland/files/patch-host__applications_linux_apps_raspicam_RaspiStill.c b/misc/raspberrypi-userland/files/patch-host__applications_linux_apps_raspicam_RaspiStill.c
new file mode 100644
index 000000000000..9e51d83956f4
--- /dev/null
+++ b/misc/raspberrypi-userland/files/patch-host__applications_linux_apps_raspicam_RaspiStill.c
@@ -0,0 +1,31 @@
+--- host_applications/linux/apps/raspicam/RaspiStill.c.orig	2022-06-28 11:46:30 UTC
++++ host_applications/linux/apps/raspicam/RaspiStill.c
+@@ -46,9 +46,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH D
+  * We use the RaspiCamControl code to handle the specific camera settings.
+  */
+ 
+-// We use some GNU extensions (asprintf, basename)
+-#define _GNU_SOURCE
+-
++#include <libgen.h>
+ #include <stdio.h>
+ #include <stdlib.h>
+ #include <ctype.h>
+@@ -445,7 +443,7 @@ static void dump_status(RASPISTILL_STATE *state)
+  * @param state Pointer to state structure to assign any discovered parameters to
+  * @return non-0 if failed for some reason, 0 otherwise
+  */
+-static int parse_cmdline(int argc, const char **argv, RASPISTILL_STATE *state)
++static int parse_cmdline(int argc, char **argv, RASPISTILL_STATE *state)
+ {
+    // Parse the command line arguments.
+    // We are looking for --<something> or -<abbreviation of something>
+@@ -1756,7 +1754,7 @@ static void rename_file(RASPISTILL_STATE *state, FILE 
+ /**
+  * main
+  */
+-int main(int argc, const char **argv)
++int main(int argc, char **argv)
+ {
+    // Our main data storage vessel..
+    RASPISTILL_STATE state;
diff --git a/misc/raspberrypi-userland/files/patch-host__applications_linux_apps_raspicam_RaspiStillYUV.c b/misc/raspberrypi-userland/files/patch-host__applications_linux_apps_raspicam_RaspiStillYUV.c
new file mode 100644
index 000000000000..9b30a99e171b
--- /dev/null
+++ b/misc/raspberrypi-userland/files/patch-host__applications_linux_apps_raspicam_RaspiStillYUV.c
@@ -0,0 +1,31 @@
+--- host_applications/linux/apps/raspicam/RaspiStillYUV.c.orig	2022-06-28 11:40:06 UTC
++++ host_applications/linux/apps/raspicam/RaspiStillYUV.c
+@@ -46,9 +46,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH D
+  * We use the RaspiPreview code to handle the generic preview
+  */
+ 
+-// We use some GNU extensions (basename)
+-#define _GNU_SOURCE
+-
++#include <libgen.h>
+ #include <stdio.h>
+ #include <stdlib.h>
+ #include <string.h>
+@@ -287,7 +285,7 @@ static void dump_status(RASPISTILLYUV_STATE *state)
+  * @param state Pointer to state structure to assign any discovered parameters to
+  * @return non-0 if failed for some reason, 0 otherwise
+  */
+-static int parse_cmdline(int argc, const char **argv, RASPISTILLYUV_STATE *state)
++static int parse_cmdline(int argc, char **argv, RASPISTILLYUV_STATE *state)
+ {
+    // Parse the command line arguments.
+    // We are looking for --<something> or -<abbreviation of something>
+@@ -1186,7 +1184,7 @@ static void rename_file(RASPISTILLYUV_STATE *state, FI
+ /**
+  * main
+  */
+-int main(int argc, const char **argv)
++int main(int argc, char **argv)
+ {
+    // Our main data storage vessel..
+    RASPISTILLYUV_STATE state;
diff --git a/misc/raspberrypi-userland/files/patch-host__applications_linux_apps_raspicam_RaspiVid.c b/misc/raspberrypi-userland/files/patch-host__applications_linux_apps_raspicam_RaspiVid.c
new file mode 100644
index 000000000000..0314d46ba51b
--- /dev/null
+++ b/misc/raspberrypi-userland/files/patch-host__applications_linux_apps_raspicam_RaspiVid.c
@@ -0,0 +1,31 @@
+--- host_applications/linux/apps/raspicam/RaspiVid.c.orig	2022-06-28 11:41:40 UTC
++++ host_applications/linux/apps/raspicam/RaspiVid.c
+@@ -47,9 +47,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH D
+  * We use the RaspiPreview code to handle the (generic) preview window
+  */
+ 
+-// We use some GNU extensions (basename)
+-#define _GNU_SOURCE
+-
++#include <libgen.h>
+ #include <stdio.h>
+ #include <stdlib.h>
+ #include <string.h>
+@@ -449,7 +447,7 @@ static void dump_status(RASPIVID_STATE *state)
+  * @param state Pointer to state structure to assign any discovered parameters to
+  * @return Non-0 if failed for some reason, 0 otherwise
+  */
+-static int parse_cmdline(int argc, const char **argv, RASPIVID_STATE *state)
++static int parse_cmdline(int argc, char **argv, RASPIVID_STATE *state)
+ {
+    // Parse the command line arguments.
+    // We are looking for --<something> or -<abbreviation of something>
+@@ -2034,7 +2032,7 @@ static int wait_for_next_change(RASPIVID_STATE *state)
+ /**
+  * main
+  */
+-int main(int argc, const char **argv)
++int main(int argc, char **argv)
+ {
+    // Our main data storage vessel..
+    RASPIVID_STATE state;
diff --git a/misc/raspberrypi-userland/files/patch-host__applications_linux_apps_raspicam_RaspiVidYUV.c b/misc/raspberrypi-userland/files/patch-host__applications_linux_apps_raspicam_RaspiVidYUV.c
new file mode 100644
index 000000000000..7610e3544076
--- /dev/null
+++ b/misc/raspberrypi-userland/files/patch-host__applications_linux_apps_raspicam_RaspiVidYUV.c
@@ -0,0 +1,31 @@
+--- host_applications/linux/apps/raspicam/RaspiVidYUV.c.orig	2022-06-28 11:42:24 UTC
++++ host_applications/linux/apps/raspicam/RaspiVidYUV.c
+@@ -49,9 +49,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH D
+  * We use the RaspiPreview code to handle the generic preview
+ */
+ 
+-// We use some GNU extensions (basename)
+-#define _GNU_SOURCE
+-
++#include <libgen.h>
+ #include <stdio.h>
+ #include <stdlib.h>
+ #include <string.h>
+@@ -325,7 +323,7 @@ static void dump_status(RASPIVIDYUV_STATE *state)
+  * @param state Pointer to state structure to assign any discovered parameters to
+  * @return Non-0 if failed for some reason, 0 otherwise
+  */
+-static int parse_cmdline(int argc, const char **argv, RASPIVIDYUV_STATE *state)
++static int parse_cmdline(int argc, char **argv, RASPIVIDYUV_STATE *state)
+ {
+    // Parse the command line arguments.
+    // We are looking for --<something> or -<abbreviation of something>
+@@ -1210,7 +1208,7 @@ static int wait_for_next_change(RASPIVIDYUV_STATE *sta
+ /**
+  * main
+  */
+-int main(int argc, const char **argv)
++int main(int argc, char **argv)
+ {
+    // Our main data storage vessel..
+    RASPIVIDYUV_STATE state;
diff --git a/misc/raspberrypi-userland/files/patch-host__applications_linux_apps_smem_CMakeLists.txt b/misc/raspberrypi-userland/files/patch-host__applications_linux_apps_smem_CMakeLists.txt
new file mode 100644
index 000000000000..a0fa0d05b5ea
--- /dev/null
+++ b/misc/raspberrypi-userland/files/patch-host__applications_linux_apps_smem_CMakeLists.txt
@@ -0,0 +1,11 @@
+--- host_applications/linux/apps/smem/CMakeLists.txt.orig	2016-10-24 19:59:54 UTC
++++ host_applications/linux/apps/smem/CMakeLists.txt
+@@ -4,7 +4,7 @@ get_filename_component (VIDEOCORE_ROOT ../../../.. ABS
+ include (${VIDEOCORE_ROOT}/makefiles/cmake/global_settings.cmake)
+ 
+ if (NOT WIN32)
+-   add_definitions(-Wall -Werror)
++   add_definitions(-Wall)
+ endif ()
+ 
+ include_directories (
diff --git a/misc/raspberrypi-userland/files/patch-host__applications_linux_libs_bcm__host_CMakeLists.txt b/misc/raspberrypi-userland/files/patch-host__applications_linux_libs_bcm__host_CMakeLists.txt
new file mode 100644
index 000000000000..f992aef0d31d
--- /dev/null
+++ b/misc/raspberrypi-userland/files/patch-host__applications_linux_libs_bcm__host_CMakeLists.txt
@@ -0,0 +1,11 @@
+--- host_applications/linux/libs/bcm_host/CMakeLists.txt.orig	2016-10-24 19:59:54 UTC
++++ host_applications/linux/libs/bcm_host/CMakeLists.txt
+@@ -3,7 +3,7 @@ if (WIN32)
+    set(VCOS_PLATFORM win32)
+ else ()
+    set(VCOS_PLATFORM pthreads)
+-   add_definitions(-Wall -Werror)
++   add_definitions(-Wall)
+ endif ()
+ 
+ include_directories( ../../../.. 
diff --git a/misc/raspberrypi-userland/files/patch-host__applications_linux_libs_sm_CMakeLists.txt b/misc/raspberrypi-userland/files/patch-host__applications_linux_libs_sm_CMakeLists.txt
new file mode 100644
index 000000000000..a09b13655d75
--- /dev/null
+++ b/misc/raspberrypi-userland/files/patch-host__applications_linux_libs_sm_CMakeLists.txt
@@ -0,0 +1,11 @@
+--- host_applications/linux/libs/sm/CMakeLists.txt.orig	2016-10-24 19:59:54 UTC
++++ host_applications/linux/libs/sm/CMakeLists.txt
+@@ -3,7 +3,7 @@ if (WIN32)
+    set(VCOS_PLATFORM win32)
+ else ()
+    set(VCOS_PLATFORM pthreads)
+-   add_definitions(-Wall -Werror -Wno-error=parentheses-equality -Wno-error=enum-conversion)
++   add_definitions(-Wall -Wno-error=parentheses-equality -Wno-error=enum-conversion)
+ endif ()
+ 
+ include_directories( ../../../..
diff --git a/misc/raspberrypi-userland/files/patch-interface_mmal_CMakeLists.txt b/misc/raspberrypi-userland/files/patch-interface_mmal_CMakeLists.txt
new file mode 100644
index 000000000000..956166a2cab2
--- /dev/null
+++ b/misc/raspberrypi-userland/files/patch-interface_mmal_CMakeLists.txt
@@ -0,0 +1,11 @@
+--- interface/mmal/CMakeLists.txt.orig	2022-06-28 04:33:47 UTC
++++ interface/mmal/CMakeLists.txt
+@@ -3,7 +3,7 @@ if (NOT DEFINED LIBRARY_TYPE)
+ set(LIBRARY_TYPE SHARED)
+ endif (NOT DEFINED LIBRARY_TYPE)
+ 
+-add_definitions(-Wall -Werror -Wno-error=enum-conversion)
++add_definitions(-Wall)
+ 
+ if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang")
+     message(STATUS "${CMAKE_CXX_COMPILER_VERSION}")
diff --git a/misc/raspberrypi-userland/files/patch-interface_vcos_CMakeLists.txt b/misc/raspberrypi-userland/files/patch-interface_vcos_CMakeLists.txt
new file mode 100644
index 000000000000..edb769a4b28c
--- /dev/null
+++ b/misc/raspberrypi-userland/files/patch-interface_vcos_CMakeLists.txt
@@ -0,0 +1,11 @@
+--- interface/vcos/CMakeLists.txt.orig	2016-10-24 19:59:54 UTC
++++ interface/vcos/CMakeLists.txt
+@@ -43,7 +43,7 @@ foreach (header ${HEADERS})
+ endforeach ()
+ 
+ if (CMAKE_COMPILER_IS_GNUCC)
+-   add_definitions (-ggdb -Werror -Wall)
++   add_definitions (-ggdb -Wall)
+ endif ()
+ 
+ if (CMAKE_COMPILER_2005)
diff --git a/misc/raspberrypi-userland/files/patch-interface_vcos_pthreads_CMakeLists.txt b/misc/raspberrypi-userland/files/patch-interface_vcos_pthreads_CMakeLists.txt
new file mode 100644
index 000000000000..4ec0d52222de
--- /dev/null
+++ b/misc/raspberrypi-userland/files/patch-interface_vcos_pthreads_CMakeLists.txt
@@ -0,0 +1,11 @@
+--- interface/vcos/pthreads/CMakeLists.txt.orig	2016-10-24 19:59:54 UTC
++++ interface/vcos/pthreads/CMakeLists.txt
+@@ -1,7 +1,7 @@
+ # MSVC5 does not fully support C99, enabling declaration-after-statement
+ # warnings allows a common MSVC5 build error to be detected in Linux builds.
+ if (CMAKE_COMPILER_IS_GNUCC)
+-   set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -Werror -Wdeclaration-after-statement")
++   set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -Wdeclaration-after-statement")
+    add_definitions (-D_GNU_SOURCE)
+ endif ()
+ 
diff --git a/misc/raspberrypi-userland/files/patch-interface_vmcs__host_linux_vcfiled_CMakeLists.txt b/misc/raspberrypi-userland/files/patch-interface_vmcs__host_linux_vcfiled_CMakeLists.txt
index 21b55dad29dd..f72540aa381e 100644
--- a/misc/raspberrypi-userland/files/patch-interface_vmcs__host_linux_vcfiled_CMakeLists.txt
+++ b/misc/raspberrypi-userland/files/patch-interface_vmcs__host_linux_vcfiled_CMakeLists.txt
@@ -1,8 +1,15 @@
 Don't install Linux specific init script.
 
---- interface/vmcs_host/linux/vcfiled/CMakeLists.txt.orig	2015-02-13 18:39:19 UTC
+--- interface/vmcs_host/linux/vcfiled/CMakeLists.txt.orig	2016-10-24 19:59:54 UTC
 +++ interface/vmcs_host/linux/vcfiled/CMakeLists.txt
-@@ -20,8 +20,8 @@ install(TARGETS vcfiled 
+@@ -1,6 +1,3 @@
+-
+-add_definitions(-Werror)
+-
+ # vcfiled - serves files to videocore. used for media handlers from
+ # OpenMAX/IL and loading VLLs.
+ add_executable(vcfiled vcfiled.c)
+@@ -20,8 +17,8 @@ install(TARGETS vcfiled 
  configure_file (etc/init.d/vcfiled ${PROJECT_BINARY_DIR}/etc/init.d/vcfiled)
  
  # script to start up vcfiled at start of day
diff --git a/misc/raspberrypi-userland/files/patch-makefiles_cmake_vmcs.cmake b/misc/raspberrypi-userland/files/patch-makefiles_cmake_vmcs.cmake
index 93f2ae05eaf5..7c5da6e1b890 100644
--- a/misc/raspberrypi-userland/files/patch-makefiles_cmake_vmcs.cmake
+++ b/misc/raspberrypi-userland/files/patch-makefiles_cmake_vmcs.cmake
@@ -1,6 +1,6 @@
---- makefiles/cmake/vmcs.cmake.orig	2015-01-05 16:36:28 UTC
+--- makefiles/cmake/vmcs.cmake.orig	2016-10-24 19:59:54 UTC
 +++ makefiles/cmake/vmcs.cmake
-@@ -55,10 +55,6 @@
+@@ -57,10 +57,6 @@ configure_file (
  #        DESTINATION ${VMCS_INSTALL_PREFIX}/sbin
  #        PERMISSIONS OWNER_WRITE WORLD_READ)