Skip to content

Conversation

@Empact
Copy link
Contributor

@Empact Empact commented Aug 1, 2018

This adds the existing c42f/tinyformat@689695c of tinyformat as a subtree, and extracts the modifications that had been made to a utilstrprintf.h wrapper file which is included instead of tinyformat.h directly.

The benefits being that this should be easier to verifiably update and clearer what changes are being introduced, while making it easier to identify tinyformat.h as a dependency rather than a project file, and apply special treatment relative to that fact.

Empact added 3 commits August 1, 2018 01:50
git-subtree-dir: src/tinyformat
git-subtree-split: 689695cf58700e6defe3741829564cd682d5ae57
This includes changes in:
695041e - util: Update tinyformat
1b8fd35 - Make tinyformat errors raise an exception instead of assert()ing
9b6d4c5 - Move strprintf define to tinyformat.h
6e5fd00 - Move `*Version()` functions to version.h/cpp
9eaa0af - tinyformat: force USE_VARIADIC_TEMPLATES
b651270 - util: Throw tinyformat::format_error on formatting error

This does not include changes in:
64fb0ac - Declare single-argument (non-converting) constructors "explicit"
4d9b425 - Fix typos

And drop src/tinyformat.h in favor of the subtree src/tinyformat/

Note I excluded only the tinyformat cpp from the boost checks out of an
abundance of caution - these files are not actually built into bitcoin so are
not at risk of pulling in unwanted dependencies, whereas the header, and other
dependencies might be.
@Empact
Copy link
Contributor Author

Empact commented Aug 1, 2018

@Empact
Copy link
Contributor Author

Empact commented Aug 1, 2018

wip: I have some build issues to sort out, will reopen when I do

@Empact Empact closed this Aug 1, 2018
@maflcko
Copy link
Member

maflcko commented Aug 1, 2018

Seems like a lot of files to pull in just to make it a subtree, no? Imo tinyformat is really meant to be a single file just to be copied into the project.

You can get the local modifications with diff $upstream_file $local_file using the upstream version mentioned in the last bump: 60b98f8

@Empact
Copy link
Contributor Author

Empact commented Aug 1, 2018

I'd be down with other approaches. My main desire is to separate the bitcoin code from the dependency code, and just a sub-folder is sufficient for that.

@Empact
Copy link
Contributor Author

Empact commented Aug 1, 2018

Reopening as the build seems to be sorted. I have pending follow-ups which relate to this that will help to explain the motivation.

@Empact
Copy link
Contributor Author

Empact commented Aug 1, 2018

Huh seems I'm unable to re-open due to the force pushes I made in the interim. Opening a new PR instead.

@bitcoin bitcoin locked as resolved and limited conversation to collaborators Sep 8, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants