diff --git a/Makefile b/Makefile index d2f877ef..255847ac 100644 --- a/Makefile +++ b/Makefile @@ -252,9 +252,13 @@ check_msquic_dependencies: sh -c "command -v cmake" compile_msquic: check_msquic_dependencies update_submodule +ifeq ($(TARGET_CPU),arm64) + # 如果 TARGET_CPU 是 arm64,不运行 compile_msquic +else mkdir -p ./dep/msquic/$(TARGET) sed -i 's|\(^ *msquic_lib\)$$|\1 ALL|g' ./dep/msquic/src/bin/CMakeLists.txt cmake -B./dep/msquic/$(TARGET) -S./dep/msquic -DQUIC_BUILD_SHARED=OFF -DCMAKE_TARGET_ARCHITECTURE=$(TARGET_CPU) make -C./dep/msquic/$(TARGET) -j$(shell nproc) @renameSymbols=$$(objdump -t ./dep/msquic/$(TARGET)/bin/Release/libmsquic.a | awk -v RS= '/_YB80VJ/{next}1' | grep -E 'g +(F|O) ' | grep -Evi ' (ms){0,1}quic' | awk '{print " --redefine-sym " $$NF "=" $$NF "_YB80VJ"}') && \ - objcopy $$renameSymbols ./dep/msquic/$(TARGET)/bin/Release/libmsquic.a \ No newline at end of file + objcopy $$renameSymbols ./dep/msquic/$(TARGET)/bin/Release/libmsquic.a +endif \ No newline at end of file diff --git a/test/test_host_number_server.yaml b/test/test_host_number_server.yaml new file mode 100644 index 00000000..2dceb558 --- /dev/null +++ b/test/test_host_number_server.yaml @@ -0,0 +1,14 @@ + +users: + id1: + secret: secret1 + id2: + secret: secret2 + id3: + secret: secret3 + host: + number: 2 + id4: + secret: secret4 + host: + number: 2 diff --git a/test/test_host_regex_server.yaml b/test/test_host_regex_server.yaml new file mode 100644 index 00000000..7ab6d3c4 --- /dev/null +++ b/test/test_host_regex_server.yaml @@ -0,0 +1,16 @@ + +users: + id1: + secret: secret1 + id2: + secret: secret2 + id3: + secret: secret3 + host: + regex: + - ^[a-z]+$ + id4: + secret: secret4 + host: + regex: + - ^[a-z]+$ diff --git a/test/test_tcp_number_server.yaml b/test/test_tcp_number_server.yaml new file mode 100644 index 00000000..57859922 --- /dev/null +++ b/test/test_tcp_number_server.yaml @@ -0,0 +1,22 @@ + +users: + id1: + secret: secret1 + id2: + secret: secret2 + id3: + secret: secret3 + id4: + secret: secret4 + tcp: + - range: 41000-42000 + - range: 42001-43000 + id5: + secret: secret5 + tcp: + - range: 51001-51999 + id6: + secret: secret6 + tcp: + - range: 50000-51000 + - range: 52000-60000