From a99fbe67b91ddcfbb80c16546f9c045619c2234d Mon Sep 17 00:00:00 2001 From: Victor Zverovich Date: Sat, 14 Dec 2019 06:50:53 -0800 Subject: Apply a typo fix retroactively --- support/manage.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'support') diff --git a/support/manage.py b/support/manage.py index e39beff1..517759b3 100755 --- a/support/manage.py +++ b/support/manage.py @@ -137,7 +137,7 @@ def update_site(env): if not os.path.exists(contents): os.rename(os.path.join(target_doc_dir, 'index.rst'), contents) # Fix issues in reference.rst/api.rst. - for filename in ['reference.rst', 'api.rst']: + for filename in ['reference.rst', 'api.rst', 'index.rst']: pattern = re.compile('doxygenfunction.. (bin|oct|hexu|hex)$', re.M) with rewrite(os.path.join(target_doc_dir, filename)) as b: b.data = b.data.replace('std::ostream &', 'std::ostream&') @@ -146,6 +146,7 @@ def update_site(env): b.data = b.data.replace('unsigned int', 'unsigned') b.data = b.data.replace('operator""_', 'operator"" _') b.data = b.data.replace(', size_t', ', std::size_t') + b.data = b.data.replace('aa long', 'a long') # Fix a broken link in index.rst. index = os.path.join(target_doc_dir, 'index.rst') with rewrite(index) as b: -- cgit v1.2.3 From 6c30f41443629ddc647875887768d1af17815409 Mon Sep 17 00:00:00 2001 From: Attila Mark Date: Fri, 24 Jan 2020 19:39:01 -0800 Subject: Configure fmt.pc library name correctly. Simplify getting library name. Add FMT_DEBUG_SUFFIX variable. --- support/cmake/fmt.pc.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'support') diff --git a/support/cmake/fmt.pc.in b/support/cmake/fmt.pc.in index e935dc78..4e030afd 100644 --- a/support/cmake/fmt.pc.in +++ b/support/cmake/fmt.pc.in @@ -6,6 +6,6 @@ includedir=${prefix}/@CMAKE_INSTALL_INCLUDEDIR@ Name: fmt Description: A modern formatting library Version: @FMT_VERSION@ -Libs: -L${libdir} -lfmt +Libs: -L${libdir} -l@FMT_LIB_NAME@ Cflags: -I${includedir} -- cgit v1.2.3 From b1adaa9881a15f9777e4bc725b477eef26bedbf6 Mon Sep 17 00:00:00 2001 From: Victor Zverovich Date: Sat, 7 Mar 2020 14:50:52 -0800 Subject: Remove gcc 4.4 workaround --- support/cmake/cxx14.cmake | 11 ----------- 1 file changed, 11 deletions(-) (limited to 'support') diff --git a/support/cmake/cxx14.cmake b/support/cmake/cxx14.cmake index 032fcb27..16ff5754 100644 --- a/support/cmake/cxx14.cmake +++ b/support/cmake/cxx14.cmake @@ -48,17 +48,6 @@ endif () set(CMAKE_REQUIRED_FLAGS ${CXX_STANDARD_FLAG}) -# Check if variadic templates are working and not affected by GCC bug 39653: -# https://gcc.gnu.org/bugzilla/show_bug.cgi?id=39653 -# Can be removed once gcc 4.4 support is dropped. -check_cxx_source_compiles(" - template - struct S { typedef typename S::type type; }; - int main() {}" SUPPORTS_VARIADIC_TEMPLATES) -if (NOT SUPPORTS_VARIADIC_TEMPLATES) - set (SUPPORTS_VARIADIC_TEMPLATES OFF) -endif () - # Check if user-defined literals are available check_cxx_source_compiles(" void operator\"\" _udl(long double); -- cgit v1.2.3 From 4999796c15b62b9992feec780a3fcf11cfc33afd Mon Sep 17 00:00:00 2001 From: Victor Zverovich Date: Mon, 6 Apr 2020 07:32:15 -0700 Subject: Fix the docs --- support/manage.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'support') diff --git a/support/manage.py b/support/manage.py index 517759b3..58fbcddb 100755 --- a/support/manage.py +++ b/support/manage.py @@ -144,9 +144,15 @@ def update_site(env): b.data = re.sub(pattern, r'doxygenfunction:: \1(int)', b.data) b.data = b.data.replace('std::FILE*', 'std::FILE *') b.data = b.data.replace('unsigned int', 'unsigned') - b.data = b.data.replace('operator""_', 'operator"" _') + #b.data = b.data.replace('operator""_', 'operator"" _') b.data = b.data.replace(', size_t', ', std::size_t') b.data = b.data.replace('aa long', 'a long') + if version == '6.2.0': + b.data = b.data.replace( + 'vformat(const S&, basic_format_args<' + + 'buffer_context>)', + 'vformat(const S&, basic_format_args<' + + 'buffer_context>>)') # Fix a broken link in index.rst. index = os.path.join(target_doc_dir, 'index.rst') with rewrite(index) as b: -- cgit v1.2.3 From 78f041ab5b40a1145ba686aeb8013e8788b08cd2 Mon Sep 17 00:00:00 2001 From: Jan Tojnar Date: Thu, 30 Apr 2020 22:23:38 +0200 Subject: build: Fix installation paths It is not generally true that `CMAKE_INSTALL_` variables are relative paths: https://github.com/jtojnar/cmake-snips#concatenating-paths-when-building-pkg-config-files --- support/cmake/JoinPaths.cmake | 26 ++++++++++++++++++++++++++ support/cmake/fmt.pc.in | 4 ++-- 2 files changed, 28 insertions(+), 2 deletions(-) create mode 100644 support/cmake/JoinPaths.cmake (limited to 'support') diff --git a/support/cmake/JoinPaths.cmake b/support/cmake/JoinPaths.cmake new file mode 100644 index 00000000..32d6d668 --- /dev/null +++ b/support/cmake/JoinPaths.cmake @@ -0,0 +1,26 @@ +# This module provides function for joining paths +# known from from most languages +# +# Original license: +# SPDX-License-Identifier: (MIT OR CC0-1.0) +# Explicit permission given to distribute this module under +# the terms of the project as described in /LICENSE.rst. +# Copyright 2020 Jan Tojnar +# https://github.com/jtojnar/cmake-snips +# +# Modelled after Python’s os.path.join +# https://docs.python.org/3.7/library/os.path.html#os.path.join +# Windows not supported +function(join_paths joined_path first_path_segment) + set(temp_path "${first_path_segment}") + foreach(current_segment IN LISTS ARGN) + if(NOT ("${current_segment}" STREQUAL "")) + if(IS_ABSOLUTE "${current_segment}") + set(temp_path "${current_segment}") + else() + set(temp_path "${temp_path}/${current_segment}") + endif() + endif() + endforeach() + set(${joined_path} "${temp_path}" PARENT_SCOPE) +endfunction() diff --git a/support/cmake/fmt.pc.in b/support/cmake/fmt.pc.in index 4e030afd..29976a8a 100644 --- a/support/cmake/fmt.pc.in +++ b/support/cmake/fmt.pc.in @@ -1,7 +1,7 @@ prefix=@CMAKE_INSTALL_PREFIX@ exec_prefix=@CMAKE_INSTALL_PREFIX@ -libdir=${exec_prefix}/@CMAKE_INSTALL_LIBDIR@ -includedir=${prefix}/@CMAKE_INSTALL_INCLUDEDIR@ +libdir=@libdir_for_pc_file@ +includedir=@includedir_for_pc_file@ Name: fmt Description: A modern formatting library -- cgit v1.2.3 From ba25baeb9757b228a4d5ecfad0fc9a45ac2a6f9d Mon Sep 17 00:00:00 2001 From: Victor Zverovich Date: Thu, 14 May 2020 19:11:40 -0700 Subject: Apply doc patch to 6.2.1 --- support/manage.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'support') diff --git a/support/manage.py b/support/manage.py index 58fbcddb..acb0d3c5 100755 --- a/support/manage.py +++ b/support/manage.py @@ -147,7 +147,7 @@ def update_site(env): #b.data = b.data.replace('operator""_', 'operator"" _') b.data = b.data.replace(', size_t', ', std::size_t') b.data = b.data.replace('aa long', 'a long') - if version == '6.2.0': + if version.startswith('6.2.'): b.data = b.data.replace( 'vformat(const S&, basic_format_args<' + 'buffer_context>)', -- cgit v1.2.3 From 57fc44907f514e377f15ceda62c920179e5e093e Mon Sep 17 00:00:00 2001 From: Victor Zverovich Date: Sat, 30 May 2020 11:25:40 -0700 Subject: Increase VM disk size --- support/Vagrantfile | 1 + 1 file changed, 1 insertion(+) (limited to 'support') diff --git a/support/Vagrantfile b/support/Vagrantfile index 24f166a1..f6b5f936 100644 --- a/support/Vagrantfile +++ b/support/Vagrantfile @@ -4,6 +4,7 @@ # A vagrant config for testing against gcc-4.8. Vagrant.configure("2") do |config| config.vm.box = "ubuntu/xenial64" + config.disksize.size = '15GB' config.vm.provider "virtualbox" do |vb| vb.memory = "4096" -- cgit v1.2.3 From c9c5b90da7e0c20d0ca4a29b012ddfda58ee174a Mon Sep 17 00:00:00 2001 From: Victor Zverovich Date: Thu, 2 Jul 2020 15:09:34 -0700 Subject: Fix a typo. Thanks Tracy Chapman from TripleChecker --- support/manage.py | 1 + 1 file changed, 1 insertion(+) (limited to 'support') diff --git a/support/manage.py b/support/manage.py index acb0d3c5..2f6a776d 100755 --- a/support/manage.py +++ b/support/manage.py @@ -147,6 +147,7 @@ def update_site(env): #b.data = b.data.replace('operator""_', 'operator"" _') b.data = b.data.replace(', size_t', ', std::size_t') b.data = b.data.replace('aa long', 'a long') + b.data = b.data.replace('serveral', 'several') if version.startswith('6.2.'): b.data = b.data.replace( 'vformat(const S&, basic_format_args<' + -- cgit v1.2.3 From 86b2f99f8c8a8944ccc3ec014caecae5b3ca71c3 Mon Sep 17 00:00:00 2001 From: Victor Zverovich Date: Mon, 6 Jul 2020 07:15:39 -0700 Subject: Fix the docs --- support/manage.py | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'support') diff --git a/support/manage.py b/support/manage.py index 2f6a776d..f88e984d 100755 --- a/support/manage.py +++ b/support/manage.py @@ -145,7 +145,14 @@ def update_site(env): b.data = b.data.replace('std::FILE*', 'std::FILE *') b.data = b.data.replace('unsigned int', 'unsigned') #b.data = b.data.replace('operator""_', 'operator"" _') - b.data = b.data.replace(', size_t', ', std::size_t') + if version.startswith('6.'): + b.data = b.data.replace(', size_t', ', std::size_t') + elif version.startswith('7.'): + b.data = b.data.replace(', std::size_t', ', size_t') + b.data = b.data.replace('join(It, It', 'join(It, Sentinel') + b.data = b.data.replace( + 'format_to_n(OutputIt, size_t, string_view, Args&&', + 'format_to_n(OutputIt, size_t, const S&, const Args&') b.data = b.data.replace('aa long', 'a long') b.data = b.data.replace('serveral', 'several') if version.startswith('6.2.'): -- cgit v1.2.3 From a29a01d304328fc56baa5aa450458c4cd945c966 Mon Sep 17 00:00:00 2001 From: Victor Zverovich Date: Mon, 6 Jul 2020 09:50:24 -0700 Subject: Fix docs --- support/manage.py | 20 +++++++++++++++----- 1 file changed, 15 insertions(+), 5 deletions(-) (limited to 'support') diff --git a/support/manage.py b/support/manage.py index f88e984d..9f270669 100755 --- a/support/manage.py +++ b/support/manage.py @@ -145,14 +145,24 @@ def update_site(env): b.data = b.data.replace('std::FILE*', 'std::FILE *') b.data = b.data.replace('unsigned int', 'unsigned') #b.data = b.data.replace('operator""_', 'operator"" _') - if version.startswith('6.'): + b.data = b.data.replace( + 'format_to_n(OutputIt, size_t, string_view, Args&&', + 'format_to_n(OutputIt, size_t, const S&, const Args&') + b.data = b.data.replace( + 'format_to_n(OutputIt, std::size_t, string_view, Args&&', + 'format_to_n(OutputIt, std::size_t, const S&, const Args&') + if version == ('3.0.2'): + b.data = b.data.replace( + 'fprintf(std::ostream&', 'fprintf(std::ostream &') + if version == ('5.3.0'): + b.data = b.data.replace( + 'format_to(OutputIt, const S&, const Args&...)', + 'format_to(OutputIt, const S &, const Args &...)') + if version.startswith('5.') or version.startswith('6.'): b.data = b.data.replace(', size_t', ', std::size_t') - elif version.startswith('7.'): + if version.startswith('7.'): b.data = b.data.replace(', std::size_t', ', size_t') b.data = b.data.replace('join(It, It', 'join(It, Sentinel') - b.data = b.data.replace( - 'format_to_n(OutputIt, size_t, string_view, Args&&', - 'format_to_n(OutputIt, size_t, const S&, const Args&') b.data = b.data.replace('aa long', 'a long') b.data = b.data.replace('serveral', 'several') if version.startswith('6.2.'): -- cgit v1.2.3 From aa41dc02b1485d77aec4fd27d83cbb8783d93bb0 Mon Sep 17 00:00:00 2001 From: Victor Zverovich Date: Sun, 25 Oct 2020 09:00:25 -0700 Subject: Remove unused script --- support/update-coverity-branch.py | 30 ------------------------------ 1 file changed, 30 deletions(-) delete mode 100755 support/update-coverity-branch.py (limited to 'support') diff --git a/support/update-coverity-branch.py b/support/update-coverity-branch.py deleted file mode 100755 index 519f5d00..00000000 --- a/support/update-coverity-branch.py +++ /dev/null @@ -1,30 +0,0 @@ -#!/usr/bin/env python -# Update the coverity branch from the master branch. -# It is not done automatically because Coverity Scan limits -# the number of submissions per day. - -from __future__ import print_function -import shutil, tempfile -from subprocess import check_output, STDOUT - -class Git: - def __init__(self, dir): - self.dir = dir - - def __call__(self, *args): - output = check_output(['git'] + list(args), cwd=self.dir, stderr=STDOUT) - print(output) - return output - -dir = tempfile.mkdtemp() -try: - git = Git(dir) - git('clone', '-b', 'coverity', 'git@github.com:fmtlib/fmt.git', dir) - output = git('merge', '-X', 'theirs', '--no-commit', 'origin/master') - if 'Fast-forward' not in output: - git('reset', 'HEAD', '.travis.yml') - git('checkout', '--', '.travis.yml') - git('commit', '-m', 'Update coverity branch') - git('push') -finally: - shutil.rmtree(dir) -- cgit v1.2.3 From 4af178bdfe893399de23a59dd0433232f8f08aca Mon Sep 17 00:00:00 2001 From: Victor Zverovich Date: Sun, 25 Oct 2020 09:01:44 -0700 Subject: Remove outdated build config --- support/fmt.pro | 27 --------------------------- 1 file changed, 27 deletions(-) delete mode 100644 support/fmt.pro (limited to 'support') diff --git a/support/fmt.pro b/support/fmt.pro deleted file mode 100644 index c555d0b4..00000000 --- a/support/fmt.pro +++ /dev/null @@ -1,27 +0,0 @@ -# Staticlib configuration for qmake builds -# For some reason qmake 3.1 fails to identify source dependencies and excludes format.cc and printf.cc -# from compilation so it _MUST_ be called as qmake -nodepend -# A workaround is implemented below: a custom compiler is defined which does not track dependencies - -TEMPLATE = lib - -TARGET = fmt - -QMAKE_EXT_CPP = .cc - -CONFIG = staticlib warn_on c++11 - -FMT_SOURCES = \ - ../src/format.cc \ - ../src/posix.cc - -fmt.name = libfmt -fmt.input = FMT_SOURCES -fmt.output = ${QMAKE_FILE_BASE}$$QMAKE_EXT_OBJ -fmt.clean = ${QMAKE_FILE_BASE}$$QMAKE_EXT_OBJ -fmt.depends = ${QMAKE_FILE_IN} -# QMAKE_RUN_CXX will not be expanded -fmt.commands = $$QMAKE_CXX -c $$QMAKE_CXXFLAGS $$QMAKE_CXXFLAGS_WARN_ON $$QMAKE_CXXFLAGS_RELEASE_WITH_DEBUGINFO $$QMAKE_CXXFLAGS_CXX11 ${QMAKE_FILE_IN} -fmt.variable_out = OBJECTS -fmt.CONFIG = no_dependencies no_link -QMAKE_EXTRA_COMPILERS += fmt -- cgit v1.2.3 From e0995b1c14ffe826b4ffa97c53b039eab2e92334 Mon Sep 17 00:00:00 2001 From: Victor Zverovich Date: Sun, 25 Oct 2020 09:04:39 -0700 Subject: Update readme --- support/README | 2 -- 1 file changed, 2 deletions(-) (limited to 'support') diff --git a/support/README b/support/README index e7fbacc7..468f5485 100644 --- a/support/README +++ b/support/README @@ -2,5 +2,3 @@ This directory contains build support files such as * CMake modules * Build scripts -* qmake (static build with dynamic libc only) - -- cgit v1.2.3