mirror of
https://gitlab.com/mbunkus/mkvtoolnix.git
synced 2024-12-25 04:11:44 +00:00
build system: build Qt translation files on MingW
This commit is contained in:
parent
75f2cdd6f9
commit
479f5d3670
1
.gitignore
vendored
1
.gitignore
vendored
@ -44,6 +44,7 @@
|
||||
/lib/saxon-he
|
||||
/po/*.mo
|
||||
/po/mkvtoolnix.pot
|
||||
/po/qt/*.qm
|
||||
/rake.d/dependency.d
|
||||
/share/icons/*/*.h
|
||||
/src/common/common.h.gch
|
||||
|
13
Rakefile
13
Rakefile
@ -173,6 +173,9 @@ def define_default_task
|
||||
# The GUI help
|
||||
targets << "translations:guides" if c?(:USE_WXWIDGETS)
|
||||
|
||||
# The Qt translation files: only for Windows
|
||||
targets << "translations:qt" if c?(:MINGW) && !c(:LCONVERT).blank?
|
||||
|
||||
task :default => targets do
|
||||
puts "Done. Enjoy :)"
|
||||
end
|
||||
@ -251,6 +254,12 @@ rule '.mo' => '.po' do |t|
|
||||
runq " MSGFMT #{t.source}", "msgfmt -c -o #{t.name} #{t.sources.join(" ")}"
|
||||
end
|
||||
|
||||
if !c(:LCONVERT).blank?
|
||||
rule '.qm' => '.ts' do |t|
|
||||
runq "LCONVERT #{t.source}", "#{c(:LCONVERT)} -o #{t.name} -i #{t.sources.join(" ")}"
|
||||
end
|
||||
end
|
||||
|
||||
# HTML help book stuff
|
||||
rule '.hhk' => '.hhc' do |t|
|
||||
runq " GREP #{t.source}", "#{c(:GREP)} -v 'name=\"ID\"' #{t.sources.join(" ")} > #{t.name}"
|
||||
@ -401,6 +410,8 @@ EOT
|
||||
|
||||
[ :applications, :manpages, :guides ].each { |type| task type => $translations[type] }
|
||||
|
||||
task :qt => FileList[ "#{$top_srcdir }/po/qt/*.ts" ].collect { |file| file.ext 'qm' }
|
||||
|
||||
$available_languages[:manpages].each do |language|
|
||||
$manpages.each do |manpage|
|
||||
name = manpage.gsub(/man\//, "man/#{language}/")
|
||||
@ -643,7 +654,7 @@ task :clean do
|
||||
share/icons/*x*/*.h
|
||||
src/info/ui/*.h src/mkvtoolnix-gui/forms/**/*.h src/**/*.moc src/**/*.moco src/mkvtoolnix-gui/qt_resources.cpp
|
||||
tests/unit/**/*.o tests/unit/**/*.a tests/unit/all
|
||||
po/*.mo doc/guide/**/*.hhk
|
||||
po/*.mo po/qt/*.qm doc/guide/**/*.hhk
|
||||
}
|
||||
patterns += $applications + $tools.collect { |name| "src/tools/#{name}" }
|
||||
|
||||
|
@ -228,6 +228,8 @@ return 0;
|
||||
BUILD_MKVTOOLNIX_GUI=no
|
||||
fi
|
||||
|
||||
AC_PATH_PROG(LCONVERT, lconvert)
|
||||
|
||||
else
|
||||
echo '*** Not checking for Qt: disabled by user request'
|
||||
fi
|
||||
|
@ -55,6 +55,7 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@
|
||||
install_sh_DATA = $(install_sh) -c -m 644
|
||||
install_sh_PROGRAM = $(install_sh) -c
|
||||
install_sh_SCRIPT = $(install_sh) -c
|
||||
LCONVERT = @LCONVERT@
|
||||
LD = @LD@
|
||||
MOC = @MOC@
|
||||
OBJEXT = @OBJEXT@
|
||||
|
Loading…
Reference in New Issue
Block a user