diff options
Diffstat (limited to 'external/ucpp')
-rw-r--r-- | external/ucpp/Executable_ucpp.mk | 33 | ||||
-rw-r--r-- | external/ucpp/Makefile | 14 | ||||
-rw-r--r-- | external/ucpp/Module_ucpp.mk | 20 | ||||
-rw-r--r-- | external/ucpp/README | 3 | ||||
-rw-r--r-- | external/ucpp/UnpackedTarball_ucpp.mk | 20 | ||||
-rw-r--r-- | external/ucpp/ucpp.patch | 11 |
6 files changed, 101 insertions, 0 deletions
diff --git a/external/ucpp/Executable_ucpp.mk b/external/ucpp/Executable_ucpp.mk new file mode 100644 index 000000000..a4be71c49 --- /dev/null +++ b/external/ucpp/Executable_ucpp.mk @@ -0,0 +1,33 @@ +# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*- +# +# This file is part of the LibreOffice project. +# +# This Source Code Form is subject to the terms of the Mozilla Public +# License, v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. +# + +$(eval $(call gb_Executable_Executable,ucpp)) + +$(eval $(call gb_Executable_set_warnings_disabled,ucpp)) + +$(eval $(call gb_Executable_use_unpacked,ucpp,ucpp)) + +$(eval $(call gb_Executable_add_defs,ucpp,\ + -DNO_UCPP_BUF \ + -DUCPP_CONFIG \ + -DSTAND_ALONE \ +)) + +$(eval $(call gb_Executable_add_generated_cobjects,ucpp,\ + UnpackedTarball/ucpp/assert \ + UnpackedTarball/ucpp/cpp \ + UnpackedTarball/ucpp/eval \ + UnpackedTarball/ucpp/hash \ + UnpackedTarball/ucpp/lexer \ + UnpackedTarball/ucpp/macro \ + UnpackedTarball/ucpp/mem \ + UnpackedTarball/ucpp/nhash \ +)) + +# vim: set noet sw=4 ts=4: diff --git a/external/ucpp/Makefile b/external/ucpp/Makefile new file mode 100644 index 000000000..569ad8a0b --- /dev/null +++ b/external/ucpp/Makefile @@ -0,0 +1,14 @@ +# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*- +# +# This file is part of the LibreOffice project. +# +# This Source Code Form is subject to the terms of the Mozilla Public +# License, v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. +# + +module_directory:=$(dir $(realpath $(firstword $(MAKEFILE_LIST)))) + +include $(module_directory)/../../solenv/gbuild/partial_build.mk + +# vim: set noet sw=4 ts=4: diff --git a/external/ucpp/Module_ucpp.mk b/external/ucpp/Module_ucpp.mk new file mode 100644 index 000000000..dc4c02f53 --- /dev/null +++ b/external/ucpp/Module_ucpp.mk @@ -0,0 +1,20 @@ +# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*- +# +# This file is part of the LibreOffice project. +# +# This Source Code Form is subject to the terms of the Mozilla Public +# License, v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. +# + +$(eval $(call gb_Module_Module,ucpp)) + +# if not cross-compiling or we need ucpp for ODK +ifneq (,$(if $(CROSS_COMPILING),,T)$(filter ODK,$(BUILD_TYPE))) +$(eval $(call gb_Module_add_targets,ucpp,\ + Executable_ucpp \ + UnpackedTarball_ucpp \ +)) +endif + +# vim: set noet sw=4 ts=4: diff --git a/external/ucpp/README b/external/ucpp/README new file mode 100644 index 000000000..9246c701a --- /dev/null +++ b/external/ucpp/README @@ -0,0 +1,3 @@ +ucpp is a C99 preprocessor + +Used to be hosted at https://code.google.com/p/ucpp/ - not sure where it's gone diff --git a/external/ucpp/UnpackedTarball_ucpp.mk b/external/ucpp/UnpackedTarball_ucpp.mk new file mode 100644 index 000000000..04d7113b8 --- /dev/null +++ b/external/ucpp/UnpackedTarball_ucpp.mk @@ -0,0 +1,20 @@ +# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*- +# +# This file is part of the LibreOffice project. +# +# This Source Code Form is subject to the terms of the Mozilla Public +# License, v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. +# + +$(eval $(call gb_UnpackedTarball_UnpackedTarball,ucpp)) + +$(eval $(call gb_UnpackedTarball_set_tarball,ucpp,$(UCPP_TARBALL))) + +$(eval $(call gb_UnpackedTarball_set_patchlevel,ucpp,0)) + +$(eval $(call gb_UnpackedTarball_add_patches,ucpp,\ + external/ucpp/ucpp.patch \ +)) + +# vim: set noet sw=4 ts=4: diff --git a/external/ucpp/ucpp.patch b/external/ucpp/ucpp.patch new file mode 100644 index 000000000..c9c4b92b7 --- /dev/null +++ b/external/ucpp/ucpp.patch @@ -0,0 +1,11 @@ +--- cpp.c ++++ cpp.c +@@ -2464,7 +2464,7 @@ + warning(-1, "unknown option '%s'", argv[i]); + } else { + if (filename != 0) { +- error(-1, "spurious filename '%s'", argv[i]); ++ error(-1, "spurious duplicate filename '%s' - vs. '%s' ", argv[i], filename); + return 2; + } + filename = argv[i]; |