diff options
| author | Eugen Wissner <belka@caraus.de> | 2025-11-25 16:20:48 +0100 |
|---|---|---|
| committer | Eugen Wissner <belka@caraus.de> | 2025-11-25 16:20:48 +0100 |
| commit | b5b129a90c9d6bec1d58fe42d4fd374be8e2cf65 (patch) | |
| tree | 8a58de38a80622148a4714f3201e4092893ade49 /Rakefile | |
| parent | c20d9b7240033b462b33030ba4946135bc7d7fef (diff) | |
| download | elna-b5b129a90c9d6bec1d58fe42d4fd374be8e2cf65.tar.gz | |
Build documentation
Diffstat (limited to 'Rakefile')
| -rw-r--r-- | Rakefile | 9 |
1 files changed, 9 insertions, 0 deletions
@@ -6,6 +6,7 @@ require 'open3' require 'pathname' require 'rake/clean' +require 'asciidoctor-pdf' STAGES = Dir.glob('boot/stage*') .collect { |stage| File.basename stage } @@ -13,6 +14,7 @@ STAGES = Dir.glob('boot/stage*') .drop(1) # First assembly stage does not count. CLEAN.include 'build/boot', 'build/valid' +CLEAN.include 'doc/*.pdf' def compile(*arguments) sh(ENV.fetch('CC', 'gcc'), '-fpie', '-g', *arguments) @@ -126,3 +128,10 @@ file 'build/boot/stage1/cl' => ['build/boot/stage1', 'boot/stage1.s'] do |t| compile('-nostdlib', '-o', t.name, *source) end + +rule '.pdf' => '.adoc' do |t| + Asciidoctor.convert_file t.source, backend: 'pdf', safe: :safe +end + +desc 'Generate documentation' +task doc: 'doc/language.pdf' |
