Age | Commit message (Collapse) | Author | Files | Lines |
|
The expected hash value is incorrect resulting in meson failing when
downloading boost 1.81.0. Updates the expcted value to be the actual
hash value.
Tested:
Boost 1.81.0 is downloaded by meson when it does not exist on the
local machine. All tests pass.
Run-time dependency Boost found: NO (tried system)
Downloading boost source from https://boostorg.jfrog.io/artifactory/main/release/1.81.0/source/boost_1_81_0.tar.bz2
Download size: 118797750
Downloading: ..........
Executing subproject boost
Signed-off-by: Carson Labrado <clabrado@google.com>
Change-Id: I36f26ec883bd08922fda3e5dc3a272bc4ef496a6
|
|
The new boost URL now interops properly with std::string_view, which is
great, and cleans up a bunch of mediocre code to convert one to another.
It has also been pulled into boost-proper, so we no longer need a
boost-url dependency that's separate.
Unfortunately, boost url makes these improvements by changing
boost::string_view for boost::urls::const_string, which causes us to
have some compile errors on the missing type.
The bulk of these changes fall into a couple categories, and have to be
executed in one commit.
string() is replaced with buffer() on the url and url_view types
boost::string_view is replaced by std::string_view for many times, in
many cases removing a temporary that we had in the code previously.
Tested: Code compiles with boost 1.81.0 beta.
Redfish service validator passes.
Pretty good unit test coverage for URL-specific use cases.
Signed-off-by: Ed Tanous <edtanous@google.com>
Change-Id: I8d3dc89b53d1cc390887fe53605d4867f75f76fd
|
|
As written, when we pull in the boost and boost-url subprojects, we hit
problems in the meson files.
```
../meson.build:291: WARNING: include_directories sandbox violation!
```
This commit resolves this issue, by adding explicit meson.build files
for both boost and boost-url.
Tested:
meson buildlocal
No longer returns the above error, and shows
Subprojects
boost : YES
boost-url : YES
Whereas previously those two dependencies showed up as NO.
Code compiles.
Signed-off-by: Ed Tanous <edtanous@google.com>
Change-Id: Ib25340723c8cb7d6139e3e51db023e9d90e30aab
|
|
Pretty trivial move. No breaking changes between these two versions.
Tested: Code compiles
Signed-off-by: Ed Tanous <edtanous@google.com>
Change-Id: Icdd0c47cab42f1f6c420856d2dc3f685bce6bd8f
|
|
Update the revision of boost-url to
d740a92d38e3a8f4d5b2153f53b82f1c98e312ab as per
https://github.com/openbmc/openbmc/blob/595f63084d313c9708cb435470e6c6dcbbbbe646/meta-openembedded/meta-oe/recipes-devtools/boost-url/boost-url_git.bb
Update the release version of boost to 1.78.0, as per
https://github.com/openbmc/openbmc/blob/595f63084d313c9708cb435470e6c6dcbbbbe646/poky/meta/recipes-support/boost/boost_1.78.0.bb
and
https://github.com/openbmc/openbmc-build-scripts/blob/ca8c4a8b9728714c9a07f7940a4d31b89c3ecf9f/scripts/build-unit-test-docker#L94
This is neccessary since the current bmcweb HEAD doesn't compile with
the specified boost-url. This failure can be verified by cloning the
repo on an x86 unix desktop without boost-url and let meson clone
subprojects.
Tested:
1. it compiled on an x86 unix desktop without boost-url and boost
2. yocto build also worked with this patch in
Signed-off-by: Nan Zhou <nanzhoumails@gmail.com>
Change-Id: Ib8356667b3fb74ae87c8bf32d21cd834ef061a47
|
|
This is done to match yocto.
Tested:
meson build
cd build
ninja
Compiles properly.
Signed-off-by: Ed Tanous <edtanous@google.com>
Change-Id: Ic0d9ffbb9e6d243dd3f929f880dbeead63114a7a
|
|
Use `meson wrap update tinyxml` to get the latest version (9.0.0)
and simplify the corresponding meson directives.
Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
Change-Id: I7513c2dca11ad9728c530e2f44986916594b2407
|
|
Update to the latest version of boost::uri
The newest version of boost uri makes some breaking changes that we need
to account for. At the same time, we take the opportunity to move to
the error code based parse methods that don't rely on exceptions.
The biggest changes are:
The standalone build is no longer present. A discussion with the
boost::url maintainers shows that our best option is to do a simple
copy of the headers, and compile boost/url/src.hpp in a separate file.
This is intended to allow people to pull the library in "standalone" and
not have to rely on the build machinery in boost-url, which we don't
really need. Interestingly, this file doesn't have a newline at the
end, which clang correctly flags. OpenBMC doesn't really need that
warning, as we rely on clang-format to do that, so we add
-Wno-newline-eof clang to get the code to compile there.
All url parsers are moved to the parse_uri, or parse_relative_uri
equivalents. This slightly tightens the requirements around what URLs
are accepted, but in no ways that should break anything. (Ie,
"/redfish/v1" is no longer accepted for a virtual media endpoint.
boost::urls::url_view::params_type has been renamed to
query_params_type, and the relevant methods have been updated.
Because of the missing standalone mode, we now need to use
boost::string_view which doesn't implicitly construct from
std::string_view. Some discussion on the boost list shows that this is
coming soon, so that cruft can eventually be cleaned up, but for now we
need the construction.
Tested:
Loaded in qemu, and ran some URLs (/redfish/v1 and /redfish/v1/Chassis)
to ensure that the url handler functions as intended.
Signed-off-by: Ed Tanous <edtanous@google.com>
Change-Id: I5843776d4ec01b4d92af2ee3a9cf1ebb1d920ae7
|
|
It's undesirable to try to format or tidy up subprojects for which we
aren't the authority on. Making this change seems to allow one to use
"ninja clang-format" within a repo, and not have it reformat all the
subprojects. More testing needed, but it's unlikely to hurt things.
Tested:
Ran "ninja clang-format" and observed _only_ the files in the repo get
formatted, not the subproject files.
Signed-off-by: Ed Tanous <edtanous@google.com>
Change-Id: Ifda7dd02b114e404f33c51919a14ca1a2bbd2352
|
|
The old URL does not work, so this changes it to a yoctoproject url.
Tested: Clean build after deleting subprojects/boost_1_75_0/
Signed-off-by: John Edward Broadbent <jebr@google.com>
Change-Id: I58e71035af018e9efc7e08f83e61716f561ea455
|
|
The bug mentioned in the comment has been resolved in boost 1.75.
Reenable this to drop our binary size again. As a consequence of this,
this commit also upgrades the subproject dependencies to 1.75 from 1.73.
They technically weren't updated to 1.74, so I'm not sure if anyone
really uses these anymore.
Tested:
Code builds with this enabled.
Signed-off-by: Ed Tanous <edtanous@google.com>
Change-Id: Id86a6358dc5a73a8b5e386661f9317f24cdbe21c
|
|
- This commit enables the support for meson build system for
bmcweb and also remove the cmake support
- The inital thought of migrating to meson build system was based
on [link](https://mesonbuild.com/Simple-comparison.html)
- Other things to praise about meson are its simplicity and userfriendly ness.
It also have native support for modern tools such as precompiled headers,
coverage, Valgrind , unity builds e.t.c
- This commit also support the automatic download and setup of dependencies
if they are not found in usual places using meson wraps that are already
available in [wrap db](https://wrapdb.mesonbuild.com/)
- For few dependencies like boost, boost-url which does not have meson
wrap support yet, i have misused the meson subproject command to download
boost & boot-url and build against them if they are not found in usual
places.
- For boost & boost-url the subproject command will always fail as meson
supports other meson projects as subprojects but it will always download
the source, and since we dont actually build boost/boost-url but just use
the the source headers this should not be a problem.
- Cmake options removed:
- BUILD_STATIC_LIBS has been removed as it is not being used any where as per the
review comments.
- By default the meson wraps are enabled and it downloads the dependencies if they
are not found, and via bitbake this behaviour is disabled by default as download
fallback feature is disabled.
- This commit also adds the README, changes for bmcweb as well.
- The meta-* layer changes are also pushed and marked as WIP under bmcweb_meson_port
topic.
Tested By :
===========
1. Compilation is passed without error or warning in both arm & x86 sdks that
are populated by yocto.
2. The unittests are also passed on both x86 & arm machines.
3. Compilation passed with various build types supported by meson (debug,debugoptimized,
relase)
4. modified the meta-phosphor & meta-ibm to leverage meson build for bmcweb, and loaded
the resulted image on qemu & real machine, checked the bmcweb status and was also able
to pull the web-gui on both.
5. Tested few common commands related to session service & network service manually on a
real machine and also also had run a CT regression bucket, and it looked clean.
The binary sizes when bmcweb is compiled via bitbake(using meta-ibm) are :
cmake: 3100080 bytes approx (3 MB)
meson: 2822596 bytes approx (2.7 MB)
1:1 equivalent hash is not possible due to couple of things:
1. The build types in meson does not have a 1:1 mapping with cmake build types.
2. Meson adds below mentioned compiler & linker flags than cmake as a part of
warning_level & build types
CXXFLAGS :' -O2 -pipe -g -feliminate-unused-debug-types -fdiagnostics-color=always
-D_FILE_OFFSET_BITS=64 -Winvalid-pch -DNDEBUG'
LDFLAGS : ' -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed -Wl,--no-undefined,-Wl,--end-group'
Tried to match the compile commands in both cmake & meson as much as possible and this
is what i could get.I have attached the compile_commands.json for both duing an yocto
full build in the [link](https://gofile.io/d/gM80fw) for reference.
Signed-off-by: Manojkiran Eda <manojkiran.eda@gmail.com>
Change-Id: Ia65689fdacb8c398dd0a019258369b2442fad2f3
|