Skip to content

Commit

Permalink
Merge branch 'mhx:main' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
maxirmx authored Nov 24, 2023
2 parents 4c25742 + 6214ccb commit c6617dc
Show file tree
Hide file tree
Showing 10 changed files with 50 additions and 113 deletions.
15 changes: 8 additions & 7 deletions .docker/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
# syntax=docker/dockerfile:1
ARG ARCH=amd64
FROM $ARCH/ubuntu:22.04
FROM $ARCH/ubuntu:23.10
RUN apt update && apt install -y gnupg wget software-properties-common
RUN wget -O - https://apt.kitware.com/keys/kitware-archive-latest.asc 2>/dev/null | gpg --dearmor - | tee /etc/apt/trusted.gpg.d/kitware.gpg >/dev/null
RUN apt-add-repository 'deb https://apt.kitware.com/ubuntu/ jammy main'
RUN apt install -y \
gcc \
g++ \
gcc-12 \
g++-12 \
clang \
clang-15 \
gcc-13 \
g++-13 \
clang-16 \
clang-17 \
git \
vim \
zstd \
Expand Down Expand Up @@ -52,13 +52,14 @@ RUN apt install -y \
libfuse3-dev \
libgoogle-glog-dev \
libutfcpp-dev \
libflac++-dev \
bash-completion \
upx
COPY install-static-libs.sh /usr/local/bin/install-static-libs.sh
RUN bash /usr/local/bin/install-static-libs.sh
RUN useradd -g users -u 1000 -m mhx
# RUN useradd -g users -u 1000 -m mhx
ARG SCRIPT=build-linux.sh
COPY $SCRIPT /usr/local/bin/run.sh
RUN chmod +x /usr/local/bin/run.sh
USER mhx
USER ubuntu
ENTRYPOINT /usr/local/bin/run.sh
14 changes: 7 additions & 7 deletions .docker/build-linux.sh
Original file line number Diff line number Diff line change
Expand Up @@ -29,16 +29,16 @@ esac

case "-$BUILD_TYPE-" in
*-gcc-*)
export CC=gcc CXX=g++
export CC=gcc-13 CXX=g++-13
;;
*-clang-*)
export CC=clang CXX=clang++
;;
*-gcc12-*)
*-oldgcc-*)
export CC=gcc-12 CXX=g++-12
;;
*-clang15-*)
export CC=clang-15 CXX=clang++-15
*-clang-*)
export CC=clang-17 CXX=clang++-17
;;
*-oldclang-*)
export CC=clang-16 CXX=clang++-16
;;
*)
echo "missing compiler in: $BUILD_TYPE"
Expand Down
12 changes: 6 additions & 6 deletions .docker/install-static-libs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,18 +6,18 @@ cd "$HOME"
mkdir pkgs
cd pkgs

wget https://github.com/libarchive/libarchive/releases/download/v3.6.2/libarchive-3.6.2.tar.xz
wget ftp://ftp.astron.com/pub/file/file-5.44.tar.gz
wget https://github.com/libarchive/libarchive/releases/download/v3.7.2/libarchive-3.7.2.tar.xz
wget ftp://ftp.astron.com/pub/file/file-5.45.tar.gz

tar xf libarchive-3.6.2.tar.xz
cd libarchive-3.6.2
tar xf libarchive-3.7.2.tar.xz
cd libarchive-3.7.2
./configure --prefix=/opt/static-libs --without-iconv --without-xml2 --without-expat
make -j$(nproc)
make install

cd "$HOME/pkgs"
tar xf file-5.44.tar.gz
cd file-5.44
tar xf file-5.45.tar.gz
cd file-5.45
./configure --prefix=/opt/static-libs --enable-static=yes --enable-shared=no
make -j$(nproc)
make install
Expand Down
19 changes: 10 additions & 9 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -76,20 +76,21 @@ jobs:
- amd64
- arm64v8
build_type:
- gcc-debug-make
- gcc12-debug-ninja
- gcc12-release-ninja
- clang15-release-ninja
- clang15-release-ninja-static
- gcc-debug-ninja
- gcc-release-ninja
- oldgcc-debug-make
- clang-release-ninja
- clang-release-ninja-static
- oldclang-debug-make
include:
- arch: amd64
build_type: clang15-asan-ninja
build_type: clang-asan-ninja
- arch: amd64
build_type: clang15-tsan-ninja
build_type: clang-tsan-ninja
- arch: amd64
build_type: clang15-ubsan-ninja
build_type: clang-ubsan-ninja
- arch: amd64
build_type: gcc12-debug-noperfmon-ninja
build_type: gcc-debug-noperfmon-ninja

runs-on:
- self-hosted
Expand Down
2 changes: 2 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -771,6 +771,7 @@ add_custom_command(
COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/fbthrift/thrift/lib/thrift/frozen.thrift
${CMAKE_CURRENT_BINARY_DIR}/thrift/lib/thrift/
COMMAND ${CMAKE_CURRENT_BINARY_DIR}/bin/thrift1
-I ${CMAKE_CURRENT_SOURCE_DIR}/fbthrift
-o ${CMAKE_CURRENT_BINARY_DIR}/thrift/lib/thrift
--gen mstch_cpp2
frozen.thrift
Expand All @@ -792,6 +793,7 @@ add_custom_command(
COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/thrift/metadata.thrift
${CMAKE_CURRENT_BINARY_DIR}/thrift/dwarfs/metadata.thrift
COMMAND ${CMAKE_CURRENT_BINARY_DIR}/bin/thrift1
-I ${CMAKE_CURRENT_SOURCE_DIR}/fbthrift
-o ${CMAKE_CURRENT_BINARY_DIR}/thrift/dwarfs
--gen mstch_cpp2:frozen2
metadata.thrift
Expand Down
8 changes: 7 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,7 @@ $ ln -s dwarfs-universal-0.7.0-Linux-aarch64 mkdwarfs
$ ./mkdwarfs --help
```

This also works on Windows ift the file system supports symbolic links:
This also works on Windows if the file system supports symbolic links:

```
> mklink mkdwarfs.exe dwarfs-universal-0.7.0-Windows-AMD64.exe
Expand Down Expand Up @@ -421,6 +421,12 @@ There are a few things worth pointing out, though:
a DwarFS image that contains links of some sort, you might run into
errors if you don't have the right privileges.

- Due to a [problem](https://github.com/winfsp/winfsp/issues/454) in
WinFsp, symlinks cannot currently point outside of the mounted file
system. Furthermore, due to another
[problem](https://github.com/winfsp/winfsp/issues/530) in WinFsp,
symlinks with a drive letter will appear with a mangled target path.

- The DwarFS driver on Windows correctly reports hardlink counts via
its API, but currently these counts are not correctly propagated
to the Windows file system layer. This is presumably due to a
Expand Down
2 changes: 1 addition & 1 deletion fbthrift
Submodule fbthrift updated 566 files
2 changes: 1 addition & 1 deletion folly
Submodule folly updated 43 files
+19 −0 build/fbcode_builder/CMake/FindLMDB.cmake
+200 −0 build/fbcode_builder/CMake/RustStaticLibrary.cmake
+7 −0 build/fbcode_builder/getdeps.py
+2 −0 build/fbcode_builder/manifests/eden
+17 −0 build/fbcode_builder/manifests/lmdb
+9 −2 folly/MapUtil.h
+1 −1 folly/Memory.h
+10 −8 folly/SharedMutex.h
+6 −1 folly/container/F14Map.h
+36 −0 folly/docs/examples/folly/MapUtil.cpp
+84 −0 folly/experimental/channels/MaxConcurrentRateLimiter.cpp
+56 −0 folly/experimental/channels/MaxConcurrentRateLimiter.h
+1 −1 folly/experimental/channels/MultiplexChannel-inl.h
+0 −65 folly/experimental/channels/RateLimiter.cpp
+31 −37 folly/experimental/channels/RateLimiter.h
+26 −24 folly/experimental/channels/Transform-inl.h
+1 −1 folly/experimental/channels/detail/Utility.h
+89 −0 folly/experimental/channels/test/MaxConcurrentRateLimiterTest.cpp
+2 −1 folly/experimental/channels/test/MultiplexChannelTest.cpp
+3 −2 folly/experimental/channels/test/TransformTest.cpp
+4 −1 folly/experimental/coro/AsyncGenerator.h
+3 −0 folly/experimental/coro/Mutex.h
+2 −0 folly/experimental/coro/SharedMutex.h
+9 −0 folly/experimental/coro/detail/BarrierTask.h
+40 −0 folly/experimental/coro/test/AsyncGeneratorBenchmark.cpp
+7 −4 folly/experimental/io/AsyncIoUringSocket.cpp
+6 −2 folly/experimental/io/AsyncIoUringSocket.h
+33 −1 folly/experimental/io/IoUringBackend.cpp
+23 −0 folly/experimental/io/IoUringBackend.h
+14 −1 folly/experimental/io/IoUringBase.h
+54 −55 folly/experimental/settings/Settings.h
+5 −1 folly/init/Init.cpp
+3 −0 folly/init/Init.h
+343 −33 folly/io/Cursor.h
+5 −2 folly/io/async/EventBase.cpp
+8 −8 folly/io/async/EventBaseAtomicNotificationQueue-inl.h
+37 −4 folly/lang/Hint.h
+29 −0 folly/lang/test/HintTest.cpp
+33 −7 folly/logging/Init.cpp
+2 −0 folly/logging/Init.h
+1 −1 folly/ssl/OpenSSLLockTypes.h
+2 −16 folly/ssl/detail/OpenSSLThreading.cpp
+14 −17 folly/synchronization/Lock.h
78 changes: 0 additions & 78 deletions scripts/example.py

This file was deleted.

11 changes: 8 additions & 3 deletions thrift/metadata.thrift
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,16 @@
* along with dwarfs. If not, see <https://www.gnu.org/licenses/>.
*/

include "thrift/annotation/cpp.thrift"

namespace cpp2 dwarfs.thrift.metadata

typedef i16 (cpp2.type = "uint16_t") UInt16
typedef i32 (cpp2.type = "uint32_t") UInt32
typedef i64 (cpp2.type = "uint64_t") UInt64
@cpp.Type{name = "uint16_t"}
typedef i16 UInt16
@cpp.Type{name = "uint32_t"}
typedef i32 UInt32
@cpp.Type{name = "uint64_t"}
typedef i64 UInt64

/**
* One chunk of data
Expand Down

0 comments on commit c6617dc

Please sign in to comment.