mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-06-05 06:33:57 +02:00
Add ada library.
This commit is contained in:
parent
4864a6996f
commit
281ad01b85
4 changed files with 56 additions and 1 deletions
|
@ -801,6 +801,18 @@ RUN cmake --build out --config Debug --parallel \
|
||||||
&& find out -mindepth 1 -maxdepth 1 ! -name Debug -exec rm -rf {} \;
|
&& find out -mindepth 1 -maxdepth 1 ! -name Debug -exec rm -rf {} \;
|
||||||
{%- endif %}
|
{%- endif %}
|
||||||
|
|
||||||
|
FROM builder AS ada
|
||||||
|
RUN git clone -b v2.9.0 --depth=1 {{ GIT }}/ada-url/ada.git \
|
||||||
|
&& cd ada \
|
||||||
|
&& cmake -GNinja -B build . \
|
||||||
|
-D CMAKE_BUILD_TYPE=None \
|
||||||
|
-D ADA_TESTING=OFF \
|
||||||
|
-D ADA_TOOLS=OFF \
|
||||||
|
&& cmake --build build --parallel \
|
||||||
|
&& DESTDIR="{{ LibrariesPath }}/ada-cache" cmake --install build \
|
||||||
|
&& cd .. \
|
||||||
|
&& rm -rf ada
|
||||||
|
|
||||||
FROM builder
|
FROM builder
|
||||||
COPY --link --from=zlib {{ LibrariesPath }}/zlib-cache /
|
COPY --link --from=zlib {{ LibrariesPath }}/zlib-cache /
|
||||||
COPY --link --from=xz {{ LibrariesPath }}/xz-cache /
|
COPY --link --from=xz {{ LibrariesPath }}/xz-cache /
|
||||||
|
@ -844,6 +856,7 @@ COPY --link --from=breakpad {{ LibrariesPath }}/breakpad-cache /
|
||||||
COPY --link --from=webrtc {{ LibrariesPath }}/tg_owt tg_owt
|
COPY --link --from=webrtc {{ LibrariesPath }}/tg_owt tg_owt
|
||||||
COPY --link --from=webrtc_release {{ LibrariesPath }}/tg_owt/out/Release tg_owt/out/Release
|
COPY --link --from=webrtc_release {{ LibrariesPath }}/tg_owt/out/Release tg_owt/out/Release
|
||||||
COPY --link --from=libwebp {{ LibrariesPath }}/libwebp-cache /
|
COPY --link --from=libwebp {{ LibrariesPath }}/libwebp-cache /
|
||||||
|
COPY --link --from=ada {{ LibrariesPath }}/ada-cache /
|
||||||
|
|
||||||
{%- if DEBUG %}
|
{%- if DEBUG %}
|
||||||
COPY --link --from=webrtc_debug {{ LibrariesPath }}/tg_owt/out/Debug tg_owt/out/Debug
|
COPY --link --from=webrtc_debug {{ LibrariesPath }}/tg_owt/out/Debug tg_owt/out/Debug
|
||||||
|
|
|
@ -1831,6 +1831,30 @@ release:
|
||||||
lipo -create Release.arm64/libtg_owt.a Release.x86_64/libtg_owt.a -output Release/libtg_owt.a
|
lipo -create Release.arm64/libtg_owt.a Release.x86_64/libtg_owt.a -output Release/libtg_owt.a
|
||||||
""")
|
""")
|
||||||
|
|
||||||
|
stage('ada', """
|
||||||
|
git clone -b v2.9.0 https://github.com/ada-url/ada.git
|
||||||
|
cd ada
|
||||||
|
win:
|
||||||
|
cmake -B out . ^
|
||||||
|
-A %WIN32X64% ^
|
||||||
|
-D ADA_TESTING=OFF ^
|
||||||
|
-D ADA_TOOLS=OFF ^
|
||||||
|
-D CMAKE_MSVC_RUNTIME_LIBRARY="MultiThreaded$<$<CONFIG:Debug>:Debug>" ^
|
||||||
|
-D CMAKE_C_FLAGS_DEBUG="/MTd /Zi /Ob0 /Od /RTC1" ^
|
||||||
|
-D CMAKE_C_FLAGS_RELEASE="/MT /O2 /Ob2 /DNDEBUG"
|
||||||
|
cmake --build out --config Debug --parallel
|
||||||
|
cmake --build out --config Release --parallel
|
||||||
|
mac:
|
||||||
|
CFLAGS="$UNGUARDED" CPPFLAGS="$UNGUARDED" cmake -B build . \\
|
||||||
|
-D ADA_TESTING=OFF \\
|
||||||
|
-D ADA_TOOLS=OFF \\
|
||||||
|
-D CMAKE_OSX_DEPLOYMENT_TARGET:STRING=$MACOSX_DEPLOYMENT_TARGET \\
|
||||||
|
-D CMAKE_OSX_ARCHITECTURES="x86_64;arm64" \\
|
||||||
|
-D CMAKE_INSTALL_PREFIX:STRING=$USED_PREFIX
|
||||||
|
cmake --build build $MAKE_THREADS_CNT
|
||||||
|
cmake --install build
|
||||||
|
""")
|
||||||
|
|
||||||
stage('protobuf', """
|
stage('protobuf', """
|
||||||
win:
|
win:
|
||||||
git clone --recursive -b v21.9 https://github.com/protocolbuffers/protobuf
|
git clone --recursive -b v21.9 https://github.com/protocolbuffers/protobuf
|
||||||
|
|
2
cmake
2
cmake
|
@ -1 +1 @@
|
||||||
Subproject commit 721383d0b901cc5d5cbeec29386671d145f5a1e5
|
Subproject commit 6a1ac8a4eebb968ff6ca538088006a3d06d47421
|
|
@ -488,3 +488,21 @@ parts:
|
||||||
after:
|
after:
|
||||||
- ffmpeg
|
- ffmpeg
|
||||||
- libjxl
|
- libjxl
|
||||||
|
|
||||||
|
ada:
|
||||||
|
source: https://github.com/ada-url/ada.git
|
||||||
|
source-depth: 1
|
||||||
|
source-tag: v2.9.0
|
||||||
|
plugin: cmake
|
||||||
|
build-environment:
|
||||||
|
- LDFLAGS: ${LDFLAGS:+$LDFLAGS} -s
|
||||||
|
cmake-generator: Ninja
|
||||||
|
cmake-parameters:
|
||||||
|
- -DCMAKE_BUILD_TYPE=Release
|
||||||
|
- -DCMAKE_INSTALL_PREFIX=/usr
|
||||||
|
- -DADA_TESTING=OFF
|
||||||
|
- -DADA_TOOLS=OFF
|
||||||
|
prime:
|
||||||
|
- -./usr/include
|
||||||
|
- -./usr/lib/$CRAFT_ARCH_TRIPLET_BUILD_FOR/cmake
|
||||||
|
- -./usr/lib/$CRAFT_ARCH_TRIPLET_BUILD_FOR/*.a
|
||||||
|
|
Loading…
Add table
Reference in a new issue