Skip to content

Commit

Permalink
Add winlibs.mak
Browse files Browse the repository at this point in the history
  • Loading branch information
cmb69 committed Nov 17, 2020
1 parent b6ed966 commit 671c5f4
Showing 1 changed file with 30 additions and 0 deletions.
30 changes: 30 additions & 0 deletions winlibs.mak
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
!IFNDEF VERSION
VERSION=unknown
!ENDIF

!IF "$(PHP_SDK_ARCH)" == "x64"
PLATFORM=x64
!ELSE
PLATFORM=Win32
!ENDIF

OUTPUT=$(MAKEDIR)\..\libiconv-$(VERSION)-$(PHP_SDK_VS)-$(PHP_SDK_ARCH)
ARCHIVE=$(OUTPUT).zip

all:
git checkout .
git clean -fdx

cd MSVC$(PHP_SDK_VS_NUM)
msbuild libiconv.sln /t:Rebuild /p:Configuration=Release /p:Platform=$(PLATFORM)
msbuild libiconv.sln /t:Rebuild /p:Configuration=Debug /p:Platform=$(PLATFORM)

-rmdir /s /q $(OUTPUT)
xcopy $(PLATFORM)\bin\*.dll $(OUTPUT)\bin\*
xcopy $(PLATFORM)\bin\*.pdb $(OUTPUT)\bin\*
xcopy ..\source\include\iconv.h $(OUTPUT)\include\*
xcopy $(PLATFORM)\lib\*.lib $(OUTPUT)\lib\*
xcopy $(PLATFORM)\lib\*.pdb $(OUTPUT)\lib\*

del $(ARCHIVE)
7za a $(ARCHIVE) $(OUTPUT)\*

0 comments on commit 671c5f4

Please sign in to comment.