Skip to content

Commit

Permalink
Shell script to build Windows binaries in workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
tfpf committed Nov 1, 2024
1 parent a35190e commit ea3da10
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 12 deletions.
9 changes: 1 addition & 8 deletions .github/workflows/package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,15 +19,8 @@ jobs:
msystem: ucrt64
install: git make
pacboy: cmake gcc pkgconf
- run: |
git clone https://github.com/libgit2/libgit2.git
mkdir libgit2/build
cd libgit2/build
cmake .. -DCMAKE_INSTALL_PREFIX='C:/ProgramData/libgit2' -DBUILD_CLI=OFF -DBUILD_SHARED_LIBS=OFF -DBUILD_TESTS=OFF
cmake --build . --target install --parallel 4
- uses: actions/checkout@v4
- run: PKG_CONFIG_PATH='C:/ProgramData/libgit2/lib/pkgconfig' make -j release
working-directory: custom-prompt
- run: .github/workflows/build_windows.sh
- uses: actions/upload-artifact@v4
with:
name: custom-prompt-amd64-windows
Expand Down
5 changes: 1 addition & 4 deletions custom-prompt/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,7 @@ MainZshObject = custom-zsh-prompt.o
MainZshExecutable = bin/$(MainZshObject:.o=)
GetActiveWidObjects = get_active_wid_linux.o get_active_wid_windows.o

ifeq "$(OS)" "Windows_NT"
LDFLAGS += -static
LDLIBS += -lws2_32 -lwinhttp -lcrypt32 -lrpcrt4 -lole32 -lz
else
ifneq "$(OS)" "Windows_NT"
UNAME = $(shell uname)
ifeq "$(UNAME)" "Linux"
CPPFLAGS += $(shell pkg-config --cflags glib-2.0 libnotify x11)
Expand Down

0 comments on commit ea3da10

Please sign in to comment.