convert .txt in Win32 distribution files to CRLF eol

This commit is contained in:
Thomas Bernard 2018-12-02 11:02:37 +01:00
parent 3b90e2199e
commit 4391603f37
No known key found for this signature in database
GPG Key ID: 0FF11B67A5C0863C
4 changed files with 16 additions and 2 deletions

View File

@ -19,7 +19,7 @@ job_linux:
job_win32:
stage: build
before_script:
- apt-get update -qq && apt-get install -y -qq zip
- apt-get update -qq && apt-get install -y -qq zip dos2unix
- apt-get install -y -qq gcc-mingw-w64-i686 g++-mingw-w64-i686 mingw-w64-tools nsis
script:
- "WIN32CROSS=1 make 3rdparty"

View File

@ -18,6 +18,7 @@ addons:
- libsdl2-ttf-dev
- liblua5.2-dev
- nsis
- dos2unix
sudo: false

View File

@ -16,7 +16,13 @@ INSTALLER = grafx2-$(API)-$(VERSION).win32.exe
all: $(INSTALLER)
$(INSTALLER): WinInstaller.nsi $(SOURCES) $(VERSIONTAG)
ifdef WIN32CROSS
for f in ../doc/*.txt; do unix2dos $$f ; done
endif
$(SED) -e 's/VERSION .*/VERSION $(VERSION)/' -e 's/API .*/API $(API)/' $< | $(MAKENSIS) -
ifdef WIN32CROSS
for f in ../doc/*.txt; do dos2unix $$f ; done
endif
$(SOURCES): $(wildcard ../src/*.c) $(wildcard ../src/*.h)
cd ../src && WIN32CROSS=1 $(MAKE) $(SOURCES)

View File

@ -868,7 +868,14 @@ ziprelease: release $(SRCARCH)
cd .. && $(ZIP) $(ZIPOPT) "grafx2-$(API)-$(VERSIONTAG)$(TTFLABEL)-$(PLATFORM).$(ZIP)" \
$(BIN:../%=%) share/grafx2/gfx2def.ini $(SCRIPT_FILES:../%=%) $(SKIN_FILES:../%=%) \
share/grafx2/gfx2.gif share/icons/grafx2.svg \
$(DOC_FILES:../%=%) $(FONT_FILES:../%=%) $(SRCARCH:../%=%) $(PLATFORMFILES:../%=%)
$(FONT_FILES:../%=%) $(SRCARCH:../%=%) $(PLATFORMFILES:../%=%)
ifdef WIN32CROSS
cd .. && $(ZIP) $(ZIPOPT) --to-crlf "grafx2-$(API)-$(VERSIONTAG)$(TTFLABEL)-$(PLATFORM).$(ZIP)" \
$(DOC_FILES:../%=%)
else
cd .. && $(ZIP) $(ZIPOPT) "grafx2-$(API)-$(VERSIONTAG)$(TTFLABEL)-$(PLATFORM).$(ZIP)" \
$(DOC_FILES:../%=%)
endif
ifeq ($(PLATFORM),Darwin)
$(ZIP) $(ZIPOPT) -r ../Grafx2.app-$(shell uname -p)-$(API)-$(VERSIONTAG).zip Grafx2.app
cd .. && $(ZIP) $(ZIPOPT) Grafx2.app-$(shell uname -p)-$(API)-$(VERSIONTAG).zip \