Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bregonig.dll を sakura.exe と同じ場所に自動配置 #329

Merged
merged 2 commits into from
Aug 12, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 17 additions & 0 deletions installer/externals/bregonig/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# 正規表現ライブラリ bregonig.dll
## Website
- http://k-takata.o.oo7.jp/mysoft/bregonig.html

## バイナリ入手先
- https://bitbucket.org/k_takata/bregonig/downloads/bron412.zip

## ソースコード
- http://github.com/k-takata/bregonig

## ライセンス
- http://k-takata.o.oo7.jp/mysoft/bregonig.html#SCT-9.

## 展開ファイル
- bron412.zip … 上述サイトから入手したZIPアーカイブ
- Win32/bregonig.dll … bron412.zip から取り出した 32bit版 bregonig.dll
- x64/bregonig.dll … bron412.zip から取り出した 64bit版 bregonig.dll
Binary file added installer/externals/bregonig/Win32/bregonig.dll
Binary file not shown.
19 changes: 0 additions & 19 deletions installer/externals/bregonig/readme.txt

This file was deleted.

Binary file added installer/externals/bregonig/x64/bregonig.dll
Binary file not shown.
22 changes: 22 additions & 0 deletions sakura/postBuild.bat
Original file line number Diff line number Diff line change
@@ -1 +1,23 @@
@echo off

SETLOCAL

@echo =======================
@echo postBuild
@echo =======================

: ---- arguments ---- :
: "Win32" or "x64"
set PLATFORM=%1
@echo PLATFORM=%PLATFORM%

: "Debug" or "Release"
set CONFIGURATION=%2
@echo CONFIGURATION=%CONFIGURATION%

: ---- copy bregonig.dll ---- :
@echo Copy bregonig.dll to destination directory.
copy /B ..\installer\externals\bregonig\%PLATFORM%\bregonig.dll ..\%PLATFORM%\%CONFIGURATION%\bregonig.dll
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

末尾 ..\%PLATFORM%\%CONFIGURATION%\bregonig.dll ですが ..\%PLATFORM%\%CONFIGURATION%\ でもいけるはずです。そうすることのメリットはコピー対象ファイルが変わったとき、変更が1箇所で済む、です。まぁ、ファイル名変わらないでしょうけどw

感想なので変更は任意で。

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

僕もここはどっちにしようか迷いましたがなんとなく明示的にファイル名書きました。こだわりはあんまりないです。



ENDLOCAL
8 changes: 4 additions & 4 deletions sakura/sakura.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@
<TargetMachine>MachineX86</TargetMachine>
</Link>
<PostBuildEvent>
<Command>call postBuild.bat "$(TargetPath).manifest"</Command>
<Command>call postBuild.bat $(Platform) $(Configuration)</Command>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

変更後の引数にダブルクォーテーションがないですが意図的でしょうか?
Configuration には 空白を含む名前 を付けたくなることもあるかも知れません。

・・・たぶんないですよね。外したのが意図的でなければ付けといたほうが無難な気がします。

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

実は全部スペースは入らない想定で組んでます。スペース入ると .bat 側も実はうまく動かなくなります。運用として割り切りたいな~というお気持ち。

</PostBuildEvent>
<PreBuildEvent>
<Command>call preBuild.bat $(SolutionDir)Win32\$(Configuration)</Command>
Expand Down Expand Up @@ -156,7 +156,7 @@
<EnableCOMDATFolding>true</EnableCOMDATFolding>
</Link>
<PostBuildEvent>
<Command>call postBuild.bat "$(TargetPath).manifest"</Command>
<Command>call postBuild.bat $(Platform) $(Configuration)</Command>
</PostBuildEvent>
<PreBuildEvent>
<Command>call preBuild.bat $(SolutionDir)Win32\$(Configuration)</Command>
Expand Down Expand Up @@ -193,7 +193,7 @@
<ImageHasSafeExceptionHandlers>false</ImageHasSafeExceptionHandlers>
</Link>
<PostBuildEvent>
<Command>call postBuild.bat "$(TargetPath).manifest"</Command>
<Command>call postBuild.bat $(Platform) $(Configuration)</Command>
</PostBuildEvent>
<PreBuildEvent>
<Command>call preBuild.bat $(SolutionDir)Win32\$(Configuration)</Command>
Expand Down Expand Up @@ -229,7 +229,7 @@
<ImageHasSafeExceptionHandlers>false</ImageHasSafeExceptionHandlers>
</Link>
<PostBuildEvent>
<Command>call postBuild.bat "$(TargetPath).manifest"</Command>
<Command>call postBuild.bat $(Platform) $(Configuration)</Command>
</PostBuildEvent>
<PreBuildEvent>
<Command>call preBuild.bat $(SolutionDir)Win32\$(Configuration)</Command>
Expand Down