maharmstone / btrfs-efi Goto Github PK
View Code? Open in Web Editor NEWBtrfs EFI driver
License: GNU Lesser General Public License v2.1
Btrfs EFI driver
License: GNU Lesser General Public License v2.1
I'm trying to build this on Fedora Linux and getting the following errors:
[ 42%] Building C object CMakeFiles/btrfs.dir/src/zlib/trees.c.o
/usr/bin/gcc -I/usr/include/efi -I/usr/include/efi/x64 -O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer -fno-stack-check -fno-stack-protector -mno-stack-arg-probe -ffreestanding -Werror-implicit-function-declaration -MD -MT CMakeFiles/btrfs.dir/src/zlib/trees.c.o -MF CMakeFiles/btrfs.dir/src/zlib/trees.c.o.d -o CMakeFiles/btrfs.dir/src/zlib/trees.c.o -c /builddir/build/BUILD/btrfs-efi-3f5c0ca7c4e9a75e6e384df2fd6dbc8ca9d66368/src/zlib/trees.c
/builddir/build/BUILD/btrfs-efi-3f5c0ca7c4e9a75e6e384df2fd6dbc8ca9d66368/src/btrfs.c: In function ‘normalize_path’:
/builddir/build/BUILD/btrfs-efi-3f5c0ca7c4e9a75e6e384df2fd6dbc8ca9d66368/src/btrfs.c:998:18: error: implicit declaration of function ‘wcslen’ [-Werror=implicit-function-declaration]
998 | size_t len = wcslen(path);
| ^~~~~~
/builddir/build/BUILD/btrfs-efi-3f5c0ca7c4e9a75e6e384df2fd6dbc8ca9d66368/src/btrfs.c: In function ‘file_open’:
/builddir/build/BUILD/btrfs-efi-3f5c0ca7c4e9a75e6e384df2fd6dbc8ca9d66368/src/btrfs.c:1132:17: warning: initialization of ‘WCHAR *’ {aka ‘int *’} from incompatible pointer type ‘CHAR16 *’ {aka ‘short unsigned int *’} [-Wincompatible-pointer-types]
1132 | WCHAR* fn = FileName;
| ^~~~~~~~
/builddir/build/BUILD/btrfs-efi-3f5c0ca7c4e9a75e6e384df2fd6dbc8ca9d66368/src/btrfs.c: In function ‘read_dir’:
/builddir/build/BUILD/btrfs-efi-3f5c0ca7c4e9a75e6e384df2fd6dbc8ca9d66368/src/btrfs.c:1375:32: warning: passing argument 1 of ‘utf8_to_utf16’ from incompatible pointer type [-Wincompatible-pointer-types]
1375 | Status = utf8_to_utf16(info->FileName, fnlen, &fnlen, di->name, di->n);
| ~~~~^~~~~~~~~~
| |
| CHAR16 * {aka short unsigned int *}
In file included from /builddir/build/BUILD/btrfs-efi-3f5c0ca7c4e9a75e6e384df2fd6dbc8ca9d66368/src/btrfs.c:23:
/builddir/build/BUILD/btrfs-efi-3f5c0ca7c4e9a75e6e384df2fd6dbc8ca9d66368/src/misc.h:32:35: note: expected ‘wchar_t *’ {aka ‘int *’} but argument is of type ‘CHAR16 *’ {aka ‘short unsigned int *’}
32 | EFI_STATUS utf8_to_utf16(wchar_t* dest, unsigned int dest_max, unsigned int* dest_len, const char* src, unsigned int src_len);
| ~~~~~~~~~^~~~
/builddir/build/BUILD/btrfs-efi-3f5c0ca7c4e9a75e6e384df2fd6dbc8ca9d66368/src/btrfs.c: In function ‘file_get_info’:
/builddir/build/BUILD/btrfs-efi-3f5c0ca7c4e9a75e6e384df2fd6dbc8ca9d66368/src/btrfs.c:2008:13: error: declaration of non-variable ‘wcslen’ in ‘for’ loop initial declaration
2008 | for (int i = wcslen(ino->name); i >= 0; i--) {
| ^~~
/builddir/build/BUILD/btrfs-efi-3f5c0ca7c4e9a75e6e384df2fd6dbc8ca9d66368/src/btrfs.c: In function ‘get_driver_name’:
/builddir/build/BUILD/btrfs-efi-3f5c0ca7c4e9a75e6e384df2fd6dbc8ca9d66368/src/btrfs.c:2467:34: error: cannot initialize array of ‘short unsigned int’ from a string literal with type array of ‘int’
2467 | static const CHAR16 name[] = L"btrfs";
| ^~~~~~~~
cc1: some warnings being treated as errors
gmake[2]: *** [CMakeFiles/btrfs.dir/build.make:79: CMakeFiles/btrfs.dir/src/btrfs.c.o] Error 1
Full build log: da028ff6.txt
Build environment: Fedora Linux 39 x86_64
Using the system gcc-c++
package and gnu-efi-devel
package.
This also includes the patch I submitted in #1.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.