diff --git a/.github/workflows/make-dist.sh b/.github/workflows/make-dist.sh index e0255dd..46c9f0a 100755 --- a/.github/workflows/make-dist.sh +++ b/.github/workflows/make-dist.sh @@ -48,4 +48,4 @@ if command -v zip >/dev/null; then zip -9r $archive ${archive/.zip/} mv ${archive/.zip/} dist fi -echo "dist done ($archive)" +echo "dist done ($archive)" \ No newline at end of file diff --git a/.github/workflows/make-mac-app.sh b/.github/workflows/make-mac-app.sh new file mode 100755 index 0000000..cb7e9b9 --- /dev/null +++ b/.github/workflows/make-mac-app.sh @@ -0,0 +1,45 @@ +#!/bin/bash +set -e +set -x + +github_ref="$1" +archive="dvdisaster-$(echo "$github_ref" | grep -Eo '[^/]+$').dmg" + +echo "Archive name is $archive" +echo "::set-output name=archive::$archive" + +mkdir dist + +# Create directory structure for the macOS application bundle +mkdir -p dvdisaster.app/Contents/{MacOS,Resources} + +# Copy the main executable to the appropriate location +cp dvdisaster dvdisaster.app/Contents/MacOS + +# Use dylibbundler to bundle dynamic libraries into the application bundle +dylibbundler -od -cd -b -x dvdisaster.app/Contents/MacOS/dvdisaster -d 'dvdisaster.app/Contents/libs/' + +# Copy the Info.plist file to define application metadata +cp macinst/Info.plist dvdisaster.app/Contents/ + +# Create a directory for documentation resources +mkdir dvdisaster.app/Contents/Resources/documentation + +# Copy documentation files to the documentation directory +cp CHANGELOG TODO COPYING CREDITS.* documentation/dvdisaster.*.1 documentation/user-manual/manual.pdf dvdisaster.app/Contents/Resources/documentation + +# Copy localization files to the locale directory +find locale/* -maxdepth 0 -type d -exec cp -r {} dvdisaster.app/Contents/Resources/locale/ \; + +# Copy the application icon to the resources directory +cp macinst/dvdisaster.icns dvdisaster.app/Contents/Resources/ + +# Make the main executable executable +chmod +x dvdisaster.app/Contents/MacOS/dvdisaster + +# Move the application bundle to the 'dist' directory +mv dvdisaster.app dist + +create-dmg "$archive" dist + +echo "dist done ($archive)" \ No newline at end of file diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index fea4c57..2eb6331 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -5,6 +5,57 @@ on: types: [published] jobs: + mac: + runs-on: macos-10.15 + strategy: + matrix: + ui: [cli, gui] + include: + - ui: cli + clionly: --with-gui=no + steps: + - uses: actions/checkout@v2 + - name: install prerequisites + env: + HOMEBREW_NO_INSTALL_CLEANUP: 1 + run: brew install ghostscript glib gdk-pixbuf + - name: install prerequisites (GUI) + if: matrix.ui == 'gui' + env: + HOMEBREW_NO_INSTALL_CLEANUP: 1 + run: brew install gtk+ dylibbundler create-dmg + - name: configure + run: | + set +x + ./configure ${{ matrix.clionly }} --with-werror + - name: make + run: make -j$(sysctl -n hw.ncpu || 2) + - name: check executability + run: ./dvdisaster --version + - name: check executable (GUI) + if: matrix.ui == 'gui' + run: | + ./dvdisaster --version + if ./dvdisaster --version | grep NOGUI; then exit 1; fi + - name: check executable (CLI) + if: matrix.ui == 'cli' + run: | + ./dvdisaster --version + ./dvdisaster --version | grep NOGUI + - name: build dist + run: ./.github/workflows/make-mac-app.sh ${{ github.ref }} + id: dist + - name: Upload Release Asset + id: upload-release-asset + uses: actions/upload-release-asset@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + upload_url: ${{ github.event.release.upload_url }} + asset_path: ./${{ steps.dist.outputs.archive }} + asset_name: ${{ steps.dist.outputs.archive }} + asset_content_type: application/zip + win: runs-on: windows-latest strategy: @@ -24,130 +75,129 @@ jobs: run: shell: msys2 {0} steps: - - uses: msys2/setup-msys2@v2 - with: - msystem: ${{ matrix.msystem }} - update: false - install: git diffutils make pkg-config mingw-w64-${{ matrix.arch }}-glib2 mingw-w64-${{ matrix.arch }}-gcc mingw-w64-${{ matrix.arch }}-ghostscript mingw-w64-${{ matrix.arch }}-ntldd-git man zip - - name: install GUI prereqs - if: matrix.ui == 'gui' - run: pacman -S --noconfirm mingw-w64-${{ matrix.arch }}-gtk2 - - name: git config - run: git config --global core.autocrlf input - shell: bash - - uses: actions/checkout@v2 - - name: configure - run: ./configure ${{ matrix.clionly }} - - name: make - run: nproc && make -j$(nproc) - - name: check executable - run: | + - uses: msys2/setup-msys2@v2 + with: + msystem: ${{ matrix.msystem }} + update: false + install: git diffutils make pkg-config mingw-w64-${{ matrix.arch }}-glib2 mingw-w64-${{ matrix.arch }}-gcc mingw-w64-${{ matrix.arch }}-ghostscript mingw-w64-${{ matrix.arch }}-ntldd-git man zip + - name: install GUI prereqs + if: matrix.ui == 'gui' + run: pacman -S --noconfirm mingw-w64-${{ matrix.arch }}-gtk2 + - name: git config + run: git config --global core.autocrlf input + shell: bash + - uses: actions/checkout@v2 + - name: configure + run: ./configure ${{ matrix.clionly }} + - name: make + run: nproc && make -j$(nproc) + - name: check executable + run: | ./dvdisaster.exe --version file dvdisaster.exe if ./dvdisaster.exe --version | grep dirty; then exit 1; fi file dvdisaster.exe | grep -q '${{ matrix.grep }}, for MS Windows' - - name: check executable (GUI) - if: matrix.ui == 'gui' - run: if ./dvdisaster.exe --version | grep NOGUI; then exit 1; fi - - name: check executable (CLI) - if: matrix.ui == 'cli' - run: ./dvdisaster.exe --version | grep NOGUI - - name: prepare dist - run: ./.github/workflows/make-dist.sh ${{ github.ref }} - id: dist - - name: check executability of dist from cmd.exe - shell: cmd - run: | + - name: check executable (GUI) + if: matrix.ui == 'gui' + run: if ./dvdisaster.exe --version | grep NOGUI; then exit 1; fi + - name: check executable (CLI) + if: matrix.ui == 'cli' + run: ./dvdisaster.exe --version | grep NOGUI + - name: prepare dist + run: ./.github/workflows/make-dist.sh ${{ github.ref }} + id: dist + - name: check executability of dist from cmd.exe + shell: cmd + run: | cd dist dvdisaster.exe --version - - name: Upload Release Asset - id: upload-release-asset - uses: actions/upload-release-asset@v1 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - with: - upload_url: ${{ github.event.release.upload_url }} - asset_path: ./${{ steps.dist.outputs.archive }} - asset_name: ${{ steps.dist.outputs.archive }} - asset_content_type: application/zip + - name: Upload Release Asset + id: upload-release-asset + uses: actions/upload-release-asset@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + upload_url: ${{ github.event.release.upload_url }} + asset_path: ./${{ steps.dist.outputs.archive }} + asset_name: ${{ steps.dist.outputs.archive }} + asset_content_type: application/zip linux64-cli: - runs-on: ubuntu-latest + runs-on: ubuntu-18.04 steps: - - uses: actions/checkout@v2 - - name: install prerequisites - run: sudo apt update && sudo apt install -y libglib2.0-dev ghostscript man - - name: configure - run: ./configure --with-gui=no - - name: make - run: nproc && make -j$(nproc) && make static && mv -f dvdisaster-static dvdisaster - - name: check executable - run: | - ./dvdisaster --version && ./dvdisaster --version | grep -q dirty || true - file dvdisaster && file dvdisaster | grep -q 'ELF 64' && file dvdisaster | grep -q 'statically linked' + - uses: actions/checkout@v2 + - name: install prerequisites + run: sudo apt update && sudo apt install -y libglib2.0-dev ghostscript man + - name: configure + run: ./configure --with-gui=no + - name: make + run: nproc && make -j$(nproc) && make static && mv -f dvdisaster-static dvdisaster + - name: check executable + run: | + ./dvdisaster --version && ./dvdisaster --version | grep -q dirty || true + file dvdisaster && file dvdisaster | grep -q 'ELF 64' && file dvdisaster | grep -q 'statically linked' - - name: build dist - run: ./.github/workflows/make-dist.sh ${{ github.ref }} - id: dist - - name: Upload Release Asset - id: upload-release-asset - uses: actions/upload-release-asset@v1 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - with: - upload_url: ${{ github.event.release.upload_url }} - asset_path: ./${{ steps.dist.outputs.archive }} - asset_name: ${{ steps.dist.outputs.archive }} - asset_content_type: application/zip + - name: build dist + run: ./.github/workflows/make-dist.sh ${{ github.ref }} + id: dist + - name: Upload Release Asset + id: upload-release-asset + uses: actions/upload-release-asset@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + upload_url: ${{ github.event.release.upload_url }} + asset_path: ./${{ steps.dist.outputs.archive }} + asset_name: ${{ steps.dist.outputs.archive }} + asset_content_type: application/zip linux64-appimage: runs-on: ubuntu-18.04 steps: - - uses: actions/checkout@v2 - - name: install prerequisites - run: sudo apt update && sudo apt install -y libglib2.0-dev ghostscript man wget libgtk2.0-dev gtk2-engines-pixbuf gtk2-engines pkg-config gnome-themes-standard - - name: configure - run: ./configure --prefix=/usr - - name: make - run: nproc && make -j$(nproc) && make - - name: make install - run: touch documentation/user-manual/manual.pdf && mkdir /tmp/dist && make install DESTDIR=/tmp/dist - - name: copy things to dist - run: | - install -d /tmp/dist/usr/lib/gtk-2.0 - cp -va $(pkg-config --variable=libdir gtk+-2.0)/gtk-2.0/$(pkg-config --variable=gtk_binary_version gtk+-2.0)/* /tmp/dist/usr/lib/gtk-2.0 - - name: build appimage - run: | - wget https://github.com/linuxdeploy/linuxdeploy/releases/download/continuous/linuxdeploy-x86_64.AppImage - chmod 755 linuxdeploy-x86_64.AppImage - export VERSION=$(echo "${{ github.ref }}" | grep -Eo '[^/]+$') - ./linuxdeploy-x86_64.AppImage -d contrib/dvdisaster.desktop -i contrib/dvdisaster64.png -i contrib/dvdisaster48.png -i contrib/dvdisaster32.png -i contrib/dvdisaster16.png --icon-filename dvdisaster --custom-apprun=contrib/AppRun.sh --appdir /tmp/dist/ --output appimage - - name: apply glib workaround - run: | - wget https://github.com/AppImage/AppImageKit/releases/download/continuous/appimagetool-x86_64.AppImage - chmod 755 appimagetool-x86_64.AppImage - exe=$(ls -1 dvdisaster*.AppImage) - chmod 755 $exe - ./$exe --appimage-extract - rm -vf $exe - ./appimagetool-x86_64.AppImage -v squashfs-root - mv -v dvdisaster*AppImage $exe - chmod 755 $exe - - name: test appimage - id: dist - run: | - chmod 755 dvdisaster*.AppImage && ./dvdisaster*.AppImage --version - archive=$(ls -1 dvdisaster*.AppImage) - echo "::set-output name=archive::$archive" - echo "appimage is <$archive>" - - name: Upload Release Asset - id: upload-release-asset - uses: actions/upload-release-asset@v1 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - with: - upload_url: ${{ github.event.release.upload_url }} - asset_path: ./${{ steps.dist.outputs.archive }} - asset_name: ${{ steps.dist.outputs.archive }} - asset_content_type: application/zip - + - uses: actions/checkout@v2 + - name: install prerequisites + run: sudo apt update && sudo apt install -y libglib2.0-dev ghostscript man wget libgtk2.0-dev gtk2-engines-pixbuf gtk2-engines pkg-config gnome-themes-standard + - name: configure + run: ./configure --prefix=/usr + - name: make + run: nproc && make -j$(nproc) && make + - name: make install + run: touch documentation/user-manual/manual.pdf && mkdir /tmp/dist && make install DESTDIR=/tmp/dist + - name: copy things to dist + run: | + install -d /tmp/dist/usr/lib/gtk-2.0 + cp -va $(pkg-config --variable=libdir gtk+-2.0)/gtk-2.0/$(pkg-config --variable=gtk_binary_version gtk+-2.0)/* /tmp/dist/usr/lib/gtk-2.0 + - name: build appimage + run: | + wget https://github.com/linuxdeploy/linuxdeploy/releases/download/continuous/linuxdeploy-x86_64.AppImage + chmod 755 linuxdeploy-x86_64.AppImage + export VERSION=$(echo "${{ github.ref }}" | grep -Eo '[^/]+$') + ./linuxdeploy-x86_64.AppImage -d contrib/dvdisaster.desktop -i contrib/dvdisaster64.png -i contrib/dvdisaster48.png -i contrib/dvdisaster32.png -i contrib/dvdisaster16.png --icon-filename dvdisaster --custom-apprun=contrib/AppRun.sh --appdir /tmp/dist/ --output appimage + - name: apply glib workaround + run: | + wget https://github.com/AppImage/AppImageKit/releases/download/continuous/appimagetool-x86_64.AppImage + chmod 755 appimagetool-x86_64.AppImage + exe=$(ls -1 dvdisaster*.AppImage) + chmod 755 $exe + ./$exe --appimage-extract + rm -vf $exe + ./appimagetool-x86_64.AppImage -v squashfs-root + mv -v dvdisaster*AppImage $exe + chmod 755 $exe + - name: test appimage + id: dist + run: | + chmod 755 dvdisaster*.AppImage && ./dvdisaster*.AppImage --version + archive=$(ls -1 dvdisaster*.AppImage) + echo "::set-output name=archive::$archive" + echo "appimage is <$archive>" + - name: Upload Release Asset + id: upload-release-asset + uses: actions/upload-release-asset@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + upload_url: ${{ github.event.release.upload_url }} + asset_path: ./${{ steps.dist.outputs.archive }} + asset_name: ${{ steps.dist.outputs.archive }} + asset_content_type: application/zip diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index e5f262b..31bc702 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -3,6 +3,53 @@ name: non-regression tests on: [pull_request] jobs: + mac: + runs-on: macos-latest + strategy: + matrix: + ui: [cli, gui] + printf: [fmtdbg, normal] + include: + - ui: cli + clionly: --with-gui=no + - printf: fmtdbg + debugprintf: --with-debug-printf-format + steps: + - uses: actions/checkout@v2 + - name: install prerequisites + env: + HOMEBREW_NO_INSTALL_CLEANUP: 1 + run: brew install ghostscript + - name: install prerequisites (GUI) + if: matrix.ui == 'gui' + env: + HOMEBREW_NO_INSTALL_CLEANUP: 1 + run: brew install gtk+ + - name: configure + run: | + set +x + ./configure ${{ matrix.clionly }} ${{ matrix.debugprintf }} --with-werror + - name: make + run: make -j$(sysctl -n hw.ncpu || 2) + - name: check executability + run: ./dvdisaster --version + - name: check executable (GUI) + if: matrix.ui == 'gui' + run: | + ./dvdisaster --version + if ./dvdisaster --version | grep NOGUI; then exit 1; fi + - name: check executable (CLI) + if: matrix.ui == 'cli' + run: | + ./dvdisaster --version + ./dvdisaster --version | grep NOGUI + - name: prepare dist + run: ./.github/workflows/make-dist.sh ${{ github.ref }} + - name: regression tests + if: matrix.printf == 'normal' + env: + REGTEST_NO_UTF8: 1 + run: mkdir /var/tmp/regtest && ./regtest/runtests.sh win: runs-on: windows-latest strategy: diff --git a/configure b/configure index f090d3c..25dfa5d 100755 --- a/configure +++ b/configure @@ -47,7 +47,12 @@ DEFINE_STRING HOMEPAGE "https://dvdisaster.jcea.es" # Check for some essential tools. REQUIRE_GMAKE -REQUIRE_GCC + +if [[ $(uname) =~ Darwin ]]; then + REQUIRE_CLANG +else + REQUIRE_GCC +fi # Find out and verify the basedir of the source installation, # and where to install the binary. @@ -122,6 +127,11 @@ CFG_CFLAGS="$CFG_CFLAGS -D_LARGEFILE64_SOURCE" CHECK_SYMBOL fcntl.h O_LARGEFILE CFG_CFLAGS=$SAVE_CFLAGS +if [[ $(uname) =~ Darwin ]]; then + CFG_CFLAGS="$CFG_CFLAGS -Wno-void-pointer-to-int-cast" + CFG_LDFLAGS="$CFG_LDFLAGS -framework CoreFoundation -framework IOKit" +fi + # Machine specific echo diff --git a/documentation/user-manual/manual.pdf b/documentation/user-manual/manual.pdf index 24743c8..015255d 100644 Binary files a/documentation/user-manual/manual.pdf and b/documentation/user-manual/manual.pdf differ diff --git a/locale/cs.po b/locale/cs.po index 8c331be..6509d06 100644 --- a/locale/cs.po +++ b/locale/cs.po @@ -6,7 +6,7 @@ msgid "" msgstr "" "Project-Id-Version: dvdisaster 0.79\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-10-09 17:07+0200\n" +"POT-Creation-Date: 2023-09-13 13:48+0200\n" "PO-Revision-Date: 2011-07-24 21:12+0100\n" "Last-Translator: Jindřich Šesták \n" "Language-Team: none (individual translator)\n" @@ -22,7 +22,7 @@ msgstr "" "X-Poedit-Basepath: d:\\Preklady\\dvdisaster\\cvs\n" "X-Poedit-SearchPath-0: dvdisaster\n" -#: src/closure.c:296 +#: src/closure.c:343 #, c-format msgid "" "# dvdisaster-%s configuration file\n" @@ -35,15 +35,15 @@ msgstr "" "# každém spuštění programu.\n" "\n" -#: src/closure.c:564 +#: src/closure.c:648 msgid "medium.iso" msgstr "disc.iso" -#: src/closure.c:565 +#: src/closure.c:649 msgid "medium.ecc" msgstr "disc.ecc" -#: src/closure.c:566 +#: src/closure.c:650 msgid "sector-" msgstr "sektor-" @@ -890,7 +890,7 @@ msgstr "" "GNU General Public License\n" "Licenční podmínky aplikace dvdisaster." -#: src/help-dialogs.c:515 +#: src/help-dialogs.c:503 #, c-format msgid "" "File\n" @@ -901,7 +901,7 @@ msgstr "" "%s\n" "neexistuje" -#: src/help-dialogs.c:525 +#: src/help-dialogs.c:513 #, c-format msgid "" "File\n" @@ -912,7 +912,7 @@ msgstr "" "%s\n" "není dostupný" -#: src/help-dialogs.c:537 +#: src/help-dialogs.c:525 msgid "" "\n" "<- Error: Text file truncated here" @@ -920,17 +920,17 @@ msgstr "" "\n" "<- Chyba: Textový soubor byl zkrácen" -#: src/help-dialogs.c:736 +#: src/help-dialogs.c:724 msgid "windowtitle|About dvdisaster" msgstr "O aplikaci dvdisaster" -#: src/help-dialogs.c:755 src/misc.c:219 +#: src/help-dialogs.c:743 src/misc.c:219 msgid "" "Copyright 2004-2017 Carsten Gnoerlich.\n" "Copyright 2019-2021 The dvdisaster development team." msgstr "" -#: src/help-dialogs.c:763 +#: src/help-dialogs.c:751 msgid "" "dvdisaster provides a margin of safety against data loss\n" "on optical media caused by aging or scratches.\n" @@ -942,7 +942,7 @@ msgstr "" "Vytvoří data pro opravu chyb, která je možné použít k obnovení\n" "nečitelných sektorů, pokud později dojde k poškození disku.\n" -#: src/help-dialogs.c:768 +#: src/help-dialogs.c:756 msgid "" "This software comes with absolutely no warranty.\n" "This is free software and you are welcome to redistribute it\n" @@ -952,13 +952,13 @@ msgstr "" "Jde o svobodný software a můžete jej šířit za dodržení\n" "podmínek [GNU General Public License].\n" -#: src/help-dialogs.c:773 +#: src/help-dialogs.c:761 msgid "" "\n" "e-mail: support@dvdisaster.org" msgstr "" -#: src/help-dialogs.c:779 +#: src/help-dialogs.c:767 msgid "" "\n" "This version is not the original. It has been patched\n" @@ -969,7 +969,7 @@ msgid "" "but submit bugreports against [GitHub] instead.\n" msgstr "" -#: src/help-dialogs.c:787 +#: src/help-dialogs.c:775 msgid "" "\n" "NetBSD port: Sergey Svishchev <svs@ropnet.ru>" @@ -1519,6 +1519,40 @@ msgstr "" "Seznam dostupných metod:\n" "\n" +#: src/misc-gui.c:241 +#, c-format +msgid "" +"The error correction file is already present:\n" +"\n" +"%s\n" +"\n" +"Overwrite it?" +msgstr "" +"Soubor pro opravu chyb již existuje:\n" +"\n" +"%s\n" +"\n" +"Chcete ho přepsat?" + +#: src/misc-gui.c:639 +msgid "Do not ask again" +msgstr "Příště se již neptat" + +#: src/misc-gui.c:660 +#, c-format +msgid "" +"Image file already exists and does not match the medium:\n" +"\n" +"%s\n" +"\n" +"The existing image file will be deleted." +msgstr "" +"Soubor bitové kopie již existuje a nesouhlasí s diskem.\n" +"\n" +"%s\n" +"\n" +"Existující soubor bitové kopie bude smazán." + #: src/misc.c:225 msgid "" "This software comes with ABSOLUTELY NO WARRANTY. This\n" @@ -1580,40 +1614,6 @@ msgstr "" msgid "Image successfully truncated" msgstr "" -#: src/misc-gui.c:241 -#, c-format -msgid "" -"The error correction file is already present:\n" -"\n" -"%s\n" -"\n" -"Overwrite it?" -msgstr "" -"Soubor pro opravu chyb již existuje:\n" -"\n" -"%s\n" -"\n" -"Chcete ho přepsat?" - -#: src/misc-gui.c:639 -msgid "Do not ask again" -msgstr "Příště se již neptat" - -#: src/misc-gui.c:660 -#, c-format -msgid "" -"Image file already exists and does not match the medium:\n" -"\n" -"%s\n" -"\n" -"The existing image file will be deleted." -msgstr "" -"Soubor bitové kopie již existuje a nesouhlasí s diskem.\n" -"\n" -"%s\n" -"\n" -"Existující soubor bitové kopie bude smazán." - #: src/preferences.c:454 msgid "Switched to the linear reading strategy." msgstr "Přepnuto na lineární strategii čtení." @@ -2854,9 +2854,9 @@ msgid "button|Smart L-EC" msgstr "Chytré L-EC" #: src/raw-sector-cache.c:37 src/raw-sector-cache.c:204 -#: src/raw-sector-cache.c:338 src/scsi-freebsd.c:133 src/scsi-freebsd.c:143 -#: src/scsi-linux.c:117 src/scsi-linux.c:126 src/scsi-netbsd.c:128 -#: src/scsi-netbsd.c:138 src/scsi-win32.c:256 +#: src/raw-sector-cache.c:338 src/scsi-darwin.c:218 src/scsi-freebsd.c:133 +#: src/scsi-freebsd.c:143 src/scsi-linux.c:117 src/scsi-linux.c:126 +#: src/scsi-netbsd.c:128 src/scsi-netbsd.c:138 src/scsi-win32.c:256 #, c-format msgid "Could not open %s: %s" msgstr "Nepodařilo se otevřít %s: %s" @@ -2900,6 +2900,36 @@ msgstr " [Vytvoření nového souboru mezipaměti %s]\n" msgid " [Appended %d/%d sectors to cache file %s; LBA=%, ssize=%d, %d sectors]\n" msgstr " [Přidáno %d/%d sektorů do souboru mezipaměti %s; LBA=%, velikosts=%d, %d sektorů]\n" +#: src/read-adaptive-window.c:84 +msgid "Adaptive reading:" +msgstr "Adaptivní čtení:" + +#: src/read-adaptive-window.c:112 +msgid "Sectors processed" +msgstr "Zpracované sektory" + +#: src/read-adaptive-window.c:115 src/scsi-layer.c:1762 +msgid "readable" +msgstr "čitelné" + +#: src/read-adaptive-window.c:119 +msgid "correctable" +msgstr "opravitelné" + +#: src/read-adaptive-window.c:123 +msgid "missing" +msgstr "chybějící" + +#: src/read-adaptive-window.c:133 +#, c-format +msgid "Readable: %d.%d%% / %d.%d%% required" +msgstr "Čitelné: %d.%d%% / %d.%d%% požadovaných" + +#: src/read-adaptive-window.c:140 +#, c-format +msgid "Total recoverable: %d.%d%%" +msgstr "Celkem opravitelných: %d.%d%%" + #: src/read-adaptive.c:57 src/rs01-create.c:1018 #, c-format msgid "" @@ -3232,35 +3262,44 @@ msgid "" "%2d.%1d%% of the image have been read (% sectors).\n" msgstr "" -#: src/read-adaptive-window.c:84 -msgid "Adaptive reading:" -msgstr "Adaptivní čtení:" - -#: src/read-adaptive-window.c:112 -msgid "Sectors processed" -msgstr "Zpracované sektory" - -#: src/read-adaptive-window.c:115 src/scsi-layer.c:1762 -msgid "readable" -msgstr "čitelné" - -#: src/read-adaptive-window.c:119 -msgid "correctable" -msgstr "opravitelné" - -#: src/read-adaptive-window.c:123 -msgid "missing" -msgstr "chybějící" - -#: src/read-adaptive-window.c:133 +#: src/read-linear-window.c:102 #, c-format -msgid "Readable: %d.%d%% / %d.%d%% required" -msgstr "Čitelné: %d.%d%% / %d.%d%% požadovaných" +msgid "Current Speed: %d.%dx" +msgstr "Aktuální rychlost: %d.%dx" -#: src/read-adaptive-window.c:140 +#: src/read-linear-window.c:109 src/read-linear.c:515 #, c-format -msgid "Total recoverable: %d.%d%%" -msgstr "Celkem opravitelných: %d.%d%%" +msgid "Unreadable / skipped sectors: %" +msgstr "" + +#: src/read-linear-window.c:264 src/read-linear-window.c:333 +msgid "Already present" +msgstr "Již existuje" + +#: src/read-linear-window.c:298 src/read-linear-window.c:340 +#: src/rs01-verify.c:130 src/rs02-verify.c:123 src/rs03-verify.c:133 +msgid "Sectors with CRC errors" +msgstr "Sektory s chybami CRC" + +#: src/read-linear-window.c:321 +msgid "Medium state" +msgstr "Stav disku" + +#: src/read-linear-window.c:329 +msgid "Not touched this time" +msgstr "Vynechán" + +#: src/read-linear-window.c:336 +msgid "Successfully read" +msgstr "Úspěšně přečtený" + +#: src/read-linear-window.c:343 +msgid "Unreadable / skipped" +msgstr "Nečitelný/přeskočený" + +#: src/read-linear-window.c:454 +msgid "Speed" +msgstr "Rychlost" #: src/read-linear.c:122 #, c-format @@ -3315,11 +3354,6 @@ msgstr "dokončeno.\n" msgid "Waiting %d seconds for drive to spin up...\n" msgstr "Čekám %d sekund na roztočení disku...\n" -#: src/read-linear.c:515 src/read-linear-window.c:109 -#, c-format -msgid "Unreadable / skipped sectors: %" -msgstr "" - #: src/read-linear.c:605 #, c-format msgid "Sector %: Speed increased to %4.1fx\n" @@ -3499,40 +3533,6 @@ msgid "" "Use the --dao option to disable image truncating.\n" msgstr "" -#: src/read-linear-window.c:102 -#, c-format -msgid "Current Speed: %d.%dx" -msgstr "Aktuální rychlost: %d.%dx" - -#: src/read-linear-window.c:264 src/read-linear-window.c:333 -msgid "Already present" -msgstr "Již existuje" - -#: src/read-linear-window.c:298 src/read-linear-window.c:340 -#: src/rs01-verify.c:130 src/rs02-verify.c:123 src/rs03-verify.c:133 -msgid "Sectors with CRC errors" -msgstr "Sektory s chybami CRC" - -#: src/read-linear-window.c:321 -msgid "Medium state" -msgstr "Stav disku" - -#: src/read-linear-window.c:329 -msgid "Not touched this time" -msgstr "Vynechán" - -#: src/read-linear-window.c:336 -msgid "Successfully read" -msgstr "Úspěšně přečtený" - -#: src/read-linear-window.c:343 -msgid "Unreadable / skipped" -msgstr "Nečitelný/přeskočený" - -#: src/read-linear-window.c:454 -msgid "Speed" -msgstr "Rychlost" - #: src/recover-raw.c:66 #, c-format msgid "Sector % dumped to %s\n" @@ -5812,6 +5812,15 @@ msgstr "Výkon:" msgid "State:" msgstr "Stav:" +#: src/scsi-darwin.c:183 +msgid "No CD/DVD drives found." +msgstr "Nebyly nalezeny žádné CD/DVD mechaniky." + +#: src/scsi-darwin.c:229 +#, c-format +msgid "Could not open %s (%s)." +msgstr "" + #: src/scsi-freebsd.c:49 src/scsi-linux.c:53 msgid "" "Can not access /dev for devices\n" @@ -6236,15 +6245,19 @@ msgid "" "not found.\n" msgstr "" -#: src/show-manual.c:114 +#: src/show-manual.c:118 msgid "Could not create pipe before fork" msgstr "" -#: src/show-manual.c:122 +#: src/show-manual.c:123 src/show-manual.c:128 +msgid "Could not set pipe flags before fork" +msgstr "" + +#: src/show-manual.c:136 msgid "Could not fork to start xdg-open" msgstr "" -#: src/show-manual.c:145 +#: src/show-manual.c:159 #, c-format msgid "" "execvp could not execute \"xdg-open\":\n" @@ -7379,9 +7392,6 @@ msgstr "Novinky v této verzi:" #~ "\n" #~ "Port pro Darwin (Mac OS X): Julian Einwag <julian@einwag.de>" -#~ msgid "No CD/DVD drives found." -#~ msgstr "Nebyly nalezeny žádné CD/DVD mechaniky." - #~ msgid "dvdisaster-%s log\n" #~ msgstr "záznam programu dvdisaster-%s\n" diff --git a/locale/de.po b/locale/de.po index f51121b..248fd1f 100644 --- a/locale/de.po +++ b/locale/de.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: dvdisaster 0.52.1\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-10-09 17:07+0200\n" +"POT-Creation-Date: 2023-09-13 13:48+0200\n" "PO-Revision-Date: 2004-11-30 19:48+0100\n" "Last-Translator: Carsten Gnörlich \n" "Language-Team: German \n" @@ -18,7 +18,7 @@ msgstr "" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" -#: src/closure.c:296 +#: src/closure.c:343 #, c-format msgid "" "# dvdisaster-%s configuration file\n" @@ -31,15 +31,15 @@ msgstr "" "# Sie wird bei jedem Aufruf von dvdisaster neu überschrieben.\n" "\n" -#: src/closure.c:564 +#: src/closure.c:648 msgid "medium.iso" msgstr "abbild.iso" -#: src/closure.c:565 +#: src/closure.c:649 msgid "medium.ecc" msgstr "abbild.ecc" -#: src/closure.c:566 +#: src/closure.c:650 msgid "sector-" msgstr "sektor_" @@ -933,7 +933,7 @@ msgstr "" "GNU General Public License\n" "Die Lizenzbedingungen von dvdisaster." -#: src/help-dialogs.c:515 +#: src/help-dialogs.c:503 #, c-format msgid "" "File\n" @@ -944,7 +944,7 @@ msgstr "" "%s\n" "nicht vorhanden" -#: src/help-dialogs.c:525 +#: src/help-dialogs.c:513 #, c-format msgid "" "File\n" @@ -955,7 +955,7 @@ msgstr "" "%s\n" "kann nicht zugegriffen werden" -#: src/help-dialogs.c:537 +#: src/help-dialogs.c:525 msgid "" "\n" "<- Error: Text file truncated here" @@ -963,17 +963,17 @@ msgstr "" "\n" "<- Fehler: Textdatei wurde hier abgeschnitten" -#: src/help-dialogs.c:736 +#: src/help-dialogs.c:724 msgid "windowtitle|About dvdisaster" msgstr "Kurzinformation" -#: src/help-dialogs.c:755 src/misc.c:219 +#: src/help-dialogs.c:743 src/misc.c:219 msgid "" "Copyright 2004-2017 Carsten Gnoerlich.\n" "Copyright 2019-2021 The dvdisaster development team." msgstr "" -#: src/help-dialogs.c:763 +#: src/help-dialogs.c:751 msgid "" "dvdisaster provides a margin of safety against data loss\n" "on optical media caused by aging or scratches.\n" @@ -985,7 +985,7 @@ msgstr "" "Es erzeugt Fehlerkorrektur-Daten, um bei nachfolgenden Datenträger-\n" "Problemen unlesbare Sektoren zu rekonstruieren.\n" -#: src/help-dialogs.c:768 +#: src/help-dialogs.c:756 msgid "" "This software comes with absolutely no warranty.\n" "This is free software and you are welcome to redistribute it\n" @@ -994,13 +994,13 @@ msgstr "" "dvdisaster ist freie Software; es gelten die Bedingungen\n" "der [GNU General Public License] .\n" -#: src/help-dialogs.c:773 +#: src/help-dialogs.c:761 msgid "" "\n" "e-mail: support@dvdisaster.org" msgstr "" -#: src/help-dialogs.c:779 +#: src/help-dialogs.c:767 msgid "" "\n" "This version is not the original. It has been patched\n" @@ -1011,7 +1011,7 @@ msgid "" "but submit bugreports against [GitHub] instead.\n" msgstr "" -#: src/help-dialogs.c:787 +#: src/help-dialogs.c:775 msgid "" "\n" "NetBSD port: Sergey Svishchev <svs@ropnet.ru>" @@ -1566,6 +1566,40 @@ msgstr "" "Liste der verfügbaren Methoden:\n" "\n" +#: src/misc-gui.c:241 +#, c-format +msgid "" +"The error correction file is already present:\n" +"\n" +"%s\n" +"\n" +"Overwrite it?" +msgstr "" +"Es gibt bereits eine Fehlerkorrektur-Datei:\n" +"\n" +"%s\n" +"\n" +"Soll sie überschrieben werden?" + +#: src/misc-gui.c:639 +msgid "Do not ask again" +msgstr "Nicht mehr nachfragen" + +#: src/misc-gui.c:660 +#, c-format +msgid "" +"Image file already exists and does not match the medium:\n" +"\n" +"%s\n" +"\n" +"The existing image file will be deleted." +msgstr "" +"Die bereits vorhandene Abbild-Datei paßt nicht zu dem Datenträger:\n" +"\n" +"%s\n" +"\n" +"Soll die Abbild-Datei gelöscht werden?" + #: src/misc.c:225 msgid "" "This software comes with ABSOLUTELY NO WARRANTY. This\n" @@ -1625,40 +1659,6 @@ msgstr "" msgid "Image successfully truncated" msgstr "" -#: src/misc-gui.c:241 -#, c-format -msgid "" -"The error correction file is already present:\n" -"\n" -"%s\n" -"\n" -"Overwrite it?" -msgstr "" -"Es gibt bereits eine Fehlerkorrektur-Datei:\n" -"\n" -"%s\n" -"\n" -"Soll sie überschrieben werden?" - -#: src/misc-gui.c:639 -msgid "Do not ask again" -msgstr "Nicht mehr nachfragen" - -#: src/misc-gui.c:660 -#, c-format -msgid "" -"Image file already exists and does not match the medium:\n" -"\n" -"%s\n" -"\n" -"The existing image file will be deleted." -msgstr "" -"Die bereits vorhandene Abbild-Datei paßt nicht zu dem Datenträger:\n" -"\n" -"%s\n" -"\n" -"Soll die Abbild-Datei gelöscht werden?" - #: src/preferences.c:454 msgid "Switched to the linear reading strategy." msgstr "Lineares Leseverfahren wurde ausgewählt." @@ -2915,9 +2915,9 @@ msgid "button|Smart L-EC" msgstr "Smart L-EC" #: src/raw-sector-cache.c:37 src/raw-sector-cache.c:204 -#: src/raw-sector-cache.c:338 src/scsi-freebsd.c:133 src/scsi-freebsd.c:143 -#: src/scsi-linux.c:117 src/scsi-linux.c:126 src/scsi-netbsd.c:128 -#: src/scsi-netbsd.c:138 src/scsi-win32.c:256 +#: src/raw-sector-cache.c:338 src/scsi-darwin.c:218 src/scsi-freebsd.c:133 +#: src/scsi-freebsd.c:143 src/scsi-linux.c:117 src/scsi-linux.c:126 +#: src/scsi-netbsd.c:128 src/scsi-netbsd.c:138 src/scsi-win32.c:256 #, c-format msgid "Could not open %s: %s" msgstr "Konnte %s nicht öffnen: %s" @@ -2963,6 +2963,36 @@ msgstr " [Erzeuge neue Datei %s]\n" msgid " [Appended %d/%d sectors to cache file %s; LBA=%, ssize=%d, %d sectors]\n" msgstr " [%d/%d Sektoren der Datei %s hinzugefügt; LBA=%, S.-Größe=%d, %d Sektoren]\n" +#: src/read-adaptive-window.c:84 +msgid "Adaptive reading:" +msgstr "Angepaßtes Leseverfahren:" + +#: src/read-adaptive-window.c:112 +msgid "Sectors processed" +msgstr "Bearbeitete Sektoren" + +#: src/read-adaptive-window.c:115 src/scsi-layer.c:1762 +msgid "readable" +msgstr "lesbar" + +#: src/read-adaptive-window.c:119 +msgid "correctable" +msgstr "korrigierbar" + +#: src/read-adaptive-window.c:123 +msgid "missing" +msgstr "fehlend" + +#: src/read-adaptive-window.c:133 +#, c-format +msgid "Readable: %d.%d%% / %d.%d%% required" +msgstr "Lesbar: %d.%d%% / %d.%d%% benötigt" + +#: src/read-adaptive-window.c:140 +#, c-format +msgid "Total recoverable: %d.%d%%" +msgstr "Insgesamt wiederherstellbar: %d.%d%%" + #: src/read-adaptive.c:57 src/rs01-create.c:1018 #, c-format msgid "" @@ -3307,35 +3337,44 @@ msgstr "" "%s\n" "%2d.%1d%% des Abbilds wurden eingelesen (% Sektoren).\n" -#: src/read-adaptive-window.c:84 -msgid "Adaptive reading:" -msgstr "Angepaßtes Leseverfahren:" - -#: src/read-adaptive-window.c:112 -msgid "Sectors processed" -msgstr "Bearbeitete Sektoren" - -#: src/read-adaptive-window.c:115 src/scsi-layer.c:1762 -msgid "readable" -msgstr "lesbar" - -#: src/read-adaptive-window.c:119 -msgid "correctable" -msgstr "korrigierbar" - -#: src/read-adaptive-window.c:123 -msgid "missing" -msgstr "fehlend" - -#: src/read-adaptive-window.c:133 +#: src/read-linear-window.c:102 #, c-format -msgid "Readable: %d.%d%% / %d.%d%% required" -msgstr "Lesbar: %d.%d%% / %d.%d%% benötigt" +msgid "Current Speed: %d.%dx" +msgstr "Momentane Geschwindigkeit: %d.%dx" -#: src/read-adaptive-window.c:140 +#: src/read-linear-window.c:109 src/read-linear.c:515 #, c-format -msgid "Total recoverable: %d.%d%%" -msgstr "Insgesamt wiederherstellbar: %d.%d%%" +msgid "Unreadable / skipped sectors: %" +msgstr "Unlesbare / Übersprungene Sektoren: %" + +#: src/read-linear-window.c:264 src/read-linear-window.c:333 +msgid "Already present" +msgstr "Bereits vorhanden" + +#: src/read-linear-window.c:298 src/read-linear-window.c:340 +#: src/rs01-verify.c:130 src/rs02-verify.c:123 src/rs03-verify.c:133 +msgid "Sectors with CRC errors" +msgstr "Prüfsummen-Fehler" + +#: src/read-linear-window.c:321 +msgid "Medium state" +msgstr "Datenträger-Zustand" + +#: src/read-linear-window.c:329 +msgid "Not touched this time" +msgstr "Diesmal unberücksichtigt" + +#: src/read-linear-window.c:336 +msgid "Successfully read" +msgstr "Erfolgreich gelesen" + +#: src/read-linear-window.c:343 +msgid "Unreadable / skipped" +msgstr "Unlesbar / Übersprungen" + +#: src/read-linear-window.c:454 +msgid "Speed" +msgstr "Geschwindigkeit" #: src/read-linear.c:122 #, c-format @@ -3390,11 +3429,6 @@ msgstr "fertig.\n" msgid "Waiting %d seconds for drive to spin up...\n" msgstr "Warte %d Sekunden auf das Hochdrehen des Laufwerks...\n" -#: src/read-linear.c:515 src/read-linear-window.c:109 -#, c-format -msgid "Unreadable / skipped sectors: %" -msgstr "Unlesbare / Übersprungene Sektoren: %" - #: src/read-linear.c:605 #, c-format msgid "Sector %: Speed increased to %4.1fx\n" @@ -3575,40 +3609,6 @@ msgid "" "Use the --dao option to disable image truncating.\n" msgstr "" -#: src/read-linear-window.c:102 -#, c-format -msgid "Current Speed: %d.%dx" -msgstr "Momentane Geschwindigkeit: %d.%dx" - -#: src/read-linear-window.c:264 src/read-linear-window.c:333 -msgid "Already present" -msgstr "Bereits vorhanden" - -#: src/read-linear-window.c:298 src/read-linear-window.c:340 -#: src/rs01-verify.c:130 src/rs02-verify.c:123 src/rs03-verify.c:133 -msgid "Sectors with CRC errors" -msgstr "Prüfsummen-Fehler" - -#: src/read-linear-window.c:321 -msgid "Medium state" -msgstr "Datenträger-Zustand" - -#: src/read-linear-window.c:329 -msgid "Not touched this time" -msgstr "Diesmal unberücksichtigt" - -#: src/read-linear-window.c:336 -msgid "Successfully read" -msgstr "Erfolgreich gelesen" - -#: src/read-linear-window.c:343 -msgid "Unreadable / skipped" -msgstr "Unlesbar / Übersprungen" - -#: src/read-linear-window.c:454 -msgid "Speed" -msgstr "Geschwindigkeit" - #: src/recover-raw.c:66 #, c-format msgid "Sector % dumped to %s\n" @@ -5927,6 +5927,15 @@ msgstr "Leistung:" msgid "State:" msgstr "Zustand:" +#: src/scsi-darwin.c:183 +msgid "No CD/DVD drives found." +msgstr "" + +#: src/scsi-darwin.c:229 +#, c-format +msgid "Could not open %s (%s)." +msgstr "" + #: src/scsi-freebsd.c:49 src/scsi-linux.c:53 msgid "" "Can not access /dev for devices\n" @@ -6361,15 +6370,19 @@ msgid "" "not found.\n" msgstr "" -#: src/show-manual.c:114 +#: src/show-manual.c:118 msgid "Could not create pipe before fork" msgstr "" -#: src/show-manual.c:122 +#: src/show-manual.c:123 src/show-manual.c:128 +msgid "Could not set pipe flags before fork" +msgstr "" + +#: src/show-manual.c:136 msgid "Could not fork to start xdg-open" msgstr "" -#: src/show-manual.c:145 +#: src/show-manual.c:159 #, c-format msgid "" "execvp could not execute \"xdg-open\":\n" diff --git a/locale/it.po b/locale/it.po index ec5ee77..7d1f5a9 100644 --- a/locale/it.po +++ b/locale/it.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: dvdisaster 0.52.1\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-10-09 17:07+0200\n" +"POT-Creation-Date: 2023-09-13 13:48+0200\n" "PO-Revision-Date: 2005-01-01 14:24+0100\n" "Last-Translator: Andrea Polverini \n" "Language-Team: Italian <>\n" @@ -18,7 +18,7 @@ msgstr "" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" -#: src/closure.c:296 +#: src/closure.c:343 #, c-format msgid "" "# dvdisaster-%s configuration file\n" @@ -31,15 +31,15 @@ msgstr "" "# e sarà sovrascritto ogni volta che verrà eseguito dvdisaster\n" "\n" -#: src/closure.c:564 +#: src/closure.c:648 msgid "medium.iso" msgstr "" -#: src/closure.c:565 +#: src/closure.c:649 msgid "medium.ecc" msgstr "" -#: src/closure.c:566 +#: src/closure.c:650 msgid "sector-" msgstr "" @@ -855,7 +855,7 @@ msgstr "" "Licenza pubblica GNU\n" "Termini di Licenza di dvdisaster." -#: src/help-dialogs.c:515 +#: src/help-dialogs.c:503 #, c-format msgid "" "File\n" @@ -866,7 +866,7 @@ msgstr "" "%s\n" "non presente" -#: src/help-dialogs.c:525 +#: src/help-dialogs.c:513 #, c-format msgid "" "File\n" @@ -874,23 +874,23 @@ msgid "" "not accessible" msgstr "" -#: src/help-dialogs.c:537 +#: src/help-dialogs.c:525 msgid "" "\n" "<- Error: Text file truncated here" msgstr "" -#: src/help-dialogs.c:736 +#: src/help-dialogs.c:724 msgid "windowtitle|About dvdisaster" msgstr "Info su dvdisaster" -#: src/help-dialogs.c:755 src/misc.c:219 +#: src/help-dialogs.c:743 src/misc.c:219 msgid "" "Copyright 2004-2017 Carsten Gnoerlich.\n" "Copyright 2019-2021 The dvdisaster development team." msgstr "" -#: src/help-dialogs.c:763 +#: src/help-dialogs.c:751 msgid "" "dvdisaster provides a margin of safety against data loss\n" "on optical media caused by aging or scratches.\n" @@ -902,7 +902,7 @@ msgstr "" "Crea dei dati di correzione degli errori che saranno poi utilizzati per recuperare\n" "i settori illeggibili se il supporto dovesse danneggiarsi col tempo.\n" -#: src/help-dialogs.c:768 +#: src/help-dialogs.c:756 msgid "" "This software comes with absolutely no warranty.\n" "This is free software and you are welcome to redistribute it\n" @@ -914,13 +914,13 @@ msgstr "" "\n" "Traduzione italiana di Andrea Polverini (info@polve.com).\n" -#: src/help-dialogs.c:773 +#: src/help-dialogs.c:761 msgid "" "\n" "e-mail: support@dvdisaster.org" msgstr "" -#: src/help-dialogs.c:779 +#: src/help-dialogs.c:767 msgid "" "\n" "This version is not the original. It has been patched\n" @@ -931,7 +931,7 @@ msgid "" "but submit bugreports against [GitHub] instead.\n" msgstr "" -#: src/help-dialogs.c:787 +#: src/help-dialogs.c:775 msgid "" "\n" "NetBSD port: Sergey Svishchev <svs@ropnet.ru>" @@ -1456,6 +1456,30 @@ msgstr "" "Elenco dei metodi disponibili:\n" "\n" +#: src/misc-gui.c:241 +#, c-format +msgid "" +"The error correction file is already present:\n" +"\n" +"%s\n" +"\n" +"Overwrite it?" +msgstr "" + +#: src/misc-gui.c:639 +msgid "Do not ask again" +msgstr "" + +#: src/misc-gui.c:660 +#, c-format +msgid "" +"Image file already exists and does not match the medium:\n" +"\n" +"%s\n" +"\n" +"The existing image file will be deleted." +msgstr "" + #: src/misc.c:225 msgid "" "This software comes with ABSOLUTELY NO WARRANTY. This\n" @@ -1517,30 +1541,6 @@ msgstr "" msgid "Image successfully truncated" msgstr "" -#: src/misc-gui.c:241 -#, c-format -msgid "" -"The error correction file is already present:\n" -"\n" -"%s\n" -"\n" -"Overwrite it?" -msgstr "" - -#: src/misc-gui.c:639 -msgid "Do not ask again" -msgstr "" - -#: src/misc-gui.c:660 -#, c-format -msgid "" -"Image file already exists and does not match the medium:\n" -"\n" -"%s\n" -"\n" -"The existing image file will be deleted." -msgstr "" - #: src/preferences.c:454 msgid "Switched to the linear reading strategy." msgstr "Settata la strategia di lettura lineare" @@ -2600,9 +2600,9 @@ msgid "button|Smart L-EC" msgstr "" #: src/raw-sector-cache.c:37 src/raw-sector-cache.c:204 -#: src/raw-sector-cache.c:338 src/scsi-freebsd.c:133 src/scsi-freebsd.c:143 -#: src/scsi-linux.c:117 src/scsi-linux.c:126 src/scsi-netbsd.c:128 -#: src/scsi-netbsd.c:138 src/scsi-win32.c:256 +#: src/raw-sector-cache.c:338 src/scsi-darwin.c:218 src/scsi-freebsd.c:133 +#: src/scsi-freebsd.c:143 src/scsi-linux.c:117 src/scsi-linux.c:126 +#: src/scsi-netbsd.c:128 src/scsi-netbsd.c:138 src/scsi-win32.c:256 #, c-format msgid "Could not open %s: %s" msgstr "Non posso aprire %s: %s" @@ -2646,6 +2646,36 @@ msgstr "" msgid " [Appended %d/%d sectors to cache file %s; LBA=%, ssize=%d, %d sectors]\n" msgstr "" +#: src/read-adaptive-window.c:84 +msgid "Adaptive reading:" +msgstr "Modo di lettura adattivo:" + +#: src/read-adaptive-window.c:112 +msgid "Sectors processed" +msgstr "Settori processati" + +#: src/read-adaptive-window.c:115 src/scsi-layer.c:1762 +msgid "readable" +msgstr "Leggibile" + +#: src/read-adaptive-window.c:119 +msgid "correctable" +msgstr "Correggibili" + +#: src/read-adaptive-window.c:123 +msgid "missing" +msgstr "Mancanti" + +#: src/read-adaptive-window.c:133 +#, c-format +msgid "Readable: %d.%d%% / %d.%d%% required" +msgstr "" + +#: src/read-adaptive-window.c:140 +#, c-format +msgid "Total recoverable: %d.%d%%" +msgstr "Totale recuperabile: %d.%d%%" + #: src/read-adaptive.c:57 src/rs01-create.c:1018 #, c-format msgid "" @@ -2976,35 +3006,44 @@ msgstr "" "%s\n" "%2d.%1d%% dell'immagine è stata letta (% settori).\n" -#: src/read-adaptive-window.c:84 -msgid "Adaptive reading:" -msgstr "Modo di lettura adattivo:" - -#: src/read-adaptive-window.c:112 -msgid "Sectors processed" -msgstr "Settori processati" - -#: src/read-adaptive-window.c:115 src/scsi-layer.c:1762 -msgid "readable" -msgstr "Leggibile" - -#: src/read-adaptive-window.c:119 -msgid "correctable" -msgstr "Correggibili" - -#: src/read-adaptive-window.c:123 -msgid "missing" -msgstr "Mancanti" - -#: src/read-adaptive-window.c:133 +#: src/read-linear-window.c:102 #, c-format -msgid "Readable: %d.%d%% / %d.%d%% required" -msgstr "" +msgid "Current Speed: %d.%dx" +msgstr "Velocità corrente: %d.%dx" -#: src/read-adaptive-window.c:140 +#: src/read-linear-window.c:109 src/read-linear.c:515 #, c-format -msgid "Total recoverable: %d.%d%%" -msgstr "Totale recuperabile: %d.%d%%" +msgid "Unreadable / skipped sectors: %" +msgstr "Settori illeggibili / saltati: %" + +#: src/read-linear-window.c:264 src/read-linear-window.c:333 +msgid "Already present" +msgstr "Già presente" + +#: src/read-linear-window.c:298 src/read-linear-window.c:340 +#: src/rs01-verify.c:130 src/rs02-verify.c:123 src/rs03-verify.c:133 +msgid "Sectors with CRC errors" +msgstr "Settori con errori CRC" + +#: src/read-linear-window.c:321 +msgid "Medium state" +msgstr "Stato del supporto" + +#: src/read-linear-window.c:329 +msgid "Not touched this time" +msgstr "Non toccato questa volta" + +#: src/read-linear-window.c:336 +msgid "Successfully read" +msgstr "letto con successo" + +#: src/read-linear-window.c:343 +msgid "Unreadable / skipped" +msgstr "Illeggibili / Saltati" + +#: src/read-linear-window.c:454 +msgid "Speed" +msgstr "Velocità" #: src/read-linear.c:122 #, c-format @@ -3059,11 +3098,6 @@ msgstr "compiuto.\n" msgid "Waiting %d seconds for drive to spin up...\n" msgstr "Attendere %d secondi per far avviare il drive...\n" -#: src/read-linear.c:515 src/read-linear-window.c:109 -#, c-format -msgid "Unreadable / skipped sectors: %" -msgstr "Settori illeggibili / saltati: %" - #: src/read-linear.c:605 #, c-format msgid "Sector %: Speed increased to %4.1fx\n" @@ -3239,40 +3273,6 @@ msgid "" "Use the --dao option to disable image truncating.\n" msgstr "" -#: src/read-linear-window.c:102 -#, c-format -msgid "Current Speed: %d.%dx" -msgstr "Velocità corrente: %d.%dx" - -#: src/read-linear-window.c:264 src/read-linear-window.c:333 -msgid "Already present" -msgstr "Già presente" - -#: src/read-linear-window.c:298 src/read-linear-window.c:340 -#: src/rs01-verify.c:130 src/rs02-verify.c:123 src/rs03-verify.c:133 -msgid "Sectors with CRC errors" -msgstr "Settori con errori CRC" - -#: src/read-linear-window.c:321 -msgid "Medium state" -msgstr "Stato del supporto" - -#: src/read-linear-window.c:329 -msgid "Not touched this time" -msgstr "Non toccato questa volta" - -#: src/read-linear-window.c:336 -msgid "Successfully read" -msgstr "letto con successo" - -#: src/read-linear-window.c:343 -msgid "Unreadable / skipped" -msgstr "Illeggibili / Saltati" - -#: src/read-linear-window.c:454 -msgid "Speed" -msgstr "Velocità" - #: src/recover-raw.c:66 #, c-format msgid "Sector % dumped to %s\n" @@ -5397,6 +5397,15 @@ msgstr "" msgid "State:" msgstr "" +#: src/scsi-darwin.c:183 +msgid "No CD/DVD drives found." +msgstr "Nessun CD/DVD drive trovato." + +#: src/scsi-darwin.c:229 +#, c-format +msgid "Could not open %s (%s)." +msgstr "" + #: src/scsi-freebsd.c:49 src/scsi-linux.c:53 msgid "" "Can not access /dev for devices\n" @@ -5812,15 +5821,19 @@ msgid "" "not found.\n" msgstr "" -#: src/show-manual.c:114 +#: src/show-manual.c:118 msgid "Could not create pipe before fork" msgstr "" -#: src/show-manual.c:122 +#: src/show-manual.c:123 src/show-manual.c:128 +msgid "Could not set pipe flags before fork" +msgstr "" + +#: src/show-manual.c:136 msgid "Could not fork to start xdg-open" msgstr "" -#: src/show-manual.c:145 +#: src/show-manual.c:159 #, c-format msgid "" "execvp could not execute \"xdg-open\":\n" @@ -6330,9 +6343,6 @@ msgstr "" #~ "Nessun CD/DVD drive trovato in /dev.\n" #~ "Nessun drive sarà preselezionato.\n" -#~ msgid "No CD/DVD drives found." -#~ msgstr "Nessun CD/DVD drive trovato." - #~ msgid "dvdisaster-%s log\n" #~ msgstr "dvdisaster-%s protocollo\n" diff --git a/locale/pt_BR.po b/locale/pt_BR.po index 5295bba..3c3e9a4 100644 --- a/locale/pt_BR.po +++ b/locale/pt_BR.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: dvdisaster 0.72.rc2\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-10-09 17:07+0200\n" +"POT-Creation-Date: 2023-09-13 13:48+0200\n" "PO-Revision-Date: 2010-06-09 11:13+0200\n" "Last-Translator: cg \n" "Language-Team: Portuguese\n" @@ -17,7 +17,7 @@ msgstr "" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=(n > 1);\n" -#: src/closure.c:296 +#: src/closure.c:343 #, c-format msgid "" "# dvdisaster-%s configuration file\n" @@ -30,15 +30,15 @@ msgstr "" "# que será sobreescrevido toda vez que o dvdisaster rodar.\n" "\n" -#: src/closure.c:564 +#: src/closure.c:648 msgid "medium.iso" msgstr "midia.iso" -#: src/closure.c:565 +#: src/closure.c:649 msgid "medium.ecc" msgstr "midia.ecc" -#: src/closure.c:566 +#: src/closure.c:650 msgid "sector-" msgstr "setor-" @@ -871,7 +871,7 @@ msgstr "" "Licença Pública Geral GNU\n" "Os termos de licença do dvdisaster." -#: src/help-dialogs.c:515 +#: src/help-dialogs.c:503 #, c-format msgid "" "File\n" @@ -882,7 +882,7 @@ msgstr "" "%s\n" "não presente" -#: src/help-dialogs.c:525 +#: src/help-dialogs.c:513 #, c-format msgid "" "File\n" @@ -890,23 +890,23 @@ msgid "" "not accessible" msgstr "" -#: src/help-dialogs.c:537 +#: src/help-dialogs.c:525 msgid "" "\n" "<- Error: Text file truncated here" msgstr "" -#: src/help-dialogs.c:736 +#: src/help-dialogs.c:724 msgid "windowtitle|About dvdisaster" msgstr "windowtitle|Sobre o dvdisaster" -#: src/help-dialogs.c:755 src/misc.c:219 +#: src/help-dialogs.c:743 src/misc.c:219 msgid "" "Copyright 2004-2017 Carsten Gnoerlich.\n" "Copyright 2019-2021 The dvdisaster development team." msgstr "" -#: src/help-dialogs.c:763 +#: src/help-dialogs.c:751 msgid "" "dvdisaster provides a margin of safety against data loss\n" "on optical media caused by aging or scratches.\n" @@ -918,7 +918,7 @@ msgstr "" "Ele cria dados de correção de erros que são usados para recuperar\n" "setores ilegíveis se o disco ficar danificado posteriormente.\n" -#: src/help-dialogs.c:768 +#: src/help-dialogs.c:756 msgid "" "This software comes with absolutely no warranty.\n" "This is free software and you are welcome to redistribute it\n" @@ -930,13 +930,13 @@ msgstr "" "\n" "Tradução para português por Pablo Almeida (pabloalmeidaff9@gmail.com)\n" -#: src/help-dialogs.c:773 +#: src/help-dialogs.c:761 msgid "" "\n" "e-mail: support@dvdisaster.org" msgstr "" -#: src/help-dialogs.c:779 +#: src/help-dialogs.c:767 msgid "" "\n" "This version is not the original. It has been patched\n" @@ -947,7 +947,7 @@ msgid "" "but submit bugreports against [GitHub] instead.\n" msgstr "" -#: src/help-dialogs.c:787 +#: src/help-dialogs.c:775 msgid "" "\n" "NetBSD port: Sergey Svishchev <svs@ropnet.ru>" @@ -1481,6 +1481,30 @@ msgstr "" "Lista dos métodos disponíveis:\n" "\n" +#: src/misc-gui.c:241 +#, c-format +msgid "" +"The error correction file is already present:\n" +"\n" +"%s\n" +"\n" +"Overwrite it?" +msgstr "" + +#: src/misc-gui.c:639 +msgid "Do not ask again" +msgstr "" + +#: src/misc-gui.c:660 +#, c-format +msgid "" +"Image file already exists and does not match the medium:\n" +"\n" +"%s\n" +"\n" +"The existing image file will be deleted." +msgstr "" + #: src/misc.c:225 msgid "" "This software comes with ABSOLUTELY NO WARRANTY. This\n" @@ -1544,30 +1568,6 @@ msgstr "" msgid "Image successfully truncated" msgstr "" -#: src/misc-gui.c:241 -#, c-format -msgid "" -"The error correction file is already present:\n" -"\n" -"%s\n" -"\n" -"Overwrite it?" -msgstr "" - -#: src/misc-gui.c:639 -msgid "Do not ask again" -msgstr "" - -#: src/misc-gui.c:660 -#, c-format -msgid "" -"Image file already exists and does not match the medium:\n" -"\n" -"%s\n" -"\n" -"The existing image file will be deleted." -msgstr "" - #: src/preferences.c:454 msgid "Switched to the linear reading strategy." msgstr "Mudado para a estratégia de leitura linear" @@ -2780,9 +2780,9 @@ msgid "button|Smart L-EC" msgstr "Smart L-EC" #: src/raw-sector-cache.c:37 src/raw-sector-cache.c:204 -#: src/raw-sector-cache.c:338 src/scsi-freebsd.c:133 src/scsi-freebsd.c:143 -#: src/scsi-linux.c:117 src/scsi-linux.c:126 src/scsi-netbsd.c:128 -#: src/scsi-netbsd.c:138 src/scsi-win32.c:256 +#: src/raw-sector-cache.c:338 src/scsi-darwin.c:218 src/scsi-freebsd.c:133 +#: src/scsi-freebsd.c:143 src/scsi-linux.c:117 src/scsi-linux.c:126 +#: src/scsi-netbsd.c:128 src/scsi-netbsd.c:138 src/scsi-win32.c:256 #, c-format msgid "Could not open %s: %s" msgstr "Impossível abrir %s: %s" @@ -2826,6 +2826,36 @@ msgstr " [Criando novo arquivo de cache %s]\n" msgid " [Appended %d/%d sectors to cache file %s; LBA=%, ssize=%d, %d sectors]\n" msgstr " [Anexados %d/%d setores ao arquivo de cache %s; LBA=%, ssize=%d, %d setores]\n" +#: src/read-adaptive-window.c:84 +msgid "Adaptive reading:" +msgstr "Leitura adaptiva:" + +#: src/read-adaptive-window.c:112 +msgid "Sectors processed" +msgstr "Setores processados" + +#: src/read-adaptive-window.c:115 src/scsi-layer.c:1762 +msgid "readable" +msgstr "legível" + +#: src/read-adaptive-window.c:119 +msgid "correctable" +msgstr "corrigível" + +#: src/read-adaptive-window.c:123 +msgid "missing" +msgstr "desaparecidos" + +#: src/read-adaptive-window.c:133 +#, c-format +msgid "Readable: %d.%d%% / %d.%d%% required" +msgstr "Legível: %d.%d%% / %d.%d%% necessários" + +#: src/read-adaptive-window.c:140 +#, c-format +msgid "Total recoverable: %d.%d%%" +msgstr "Total recuperável: %d.%d%%" + #: src/read-adaptive.c:57 src/rs01-create.c:1018 #, c-format msgid "" @@ -3161,35 +3191,44 @@ msgstr "" "%s\n" "%2d.%1d%% da imagem foi lido (% setores).\n" -#: src/read-adaptive-window.c:84 -msgid "Adaptive reading:" -msgstr "Leitura adaptiva:" - -#: src/read-adaptive-window.c:112 -msgid "Sectors processed" -msgstr "Setores processados" - -#: src/read-adaptive-window.c:115 src/scsi-layer.c:1762 -msgid "readable" -msgstr "legível" - -#: src/read-adaptive-window.c:119 -msgid "correctable" -msgstr "corrigível" - -#: src/read-adaptive-window.c:123 -msgid "missing" -msgstr "desaparecidos" - -#: src/read-adaptive-window.c:133 +#: src/read-linear-window.c:102 #, c-format -msgid "Readable: %d.%d%% / %d.%d%% required" -msgstr "Legível: %d.%d%% / %d.%d%% necessários" +msgid "Current Speed: %d.%dx" +msgstr "Velocidade atual: %d.%dx" -#: src/read-adaptive-window.c:140 +#: src/read-linear-window.c:109 src/read-linear.c:515 #, c-format -msgid "Total recoverable: %d.%d%%" -msgstr "Total recuperável: %d.%d%%" +msgid "Unreadable / skipped sectors: %" +msgstr "Setores ilegíveis / pulados: %" + +#: src/read-linear-window.c:264 src/read-linear-window.c:333 +msgid "Already present" +msgstr "Já presente" + +#: src/read-linear-window.c:298 src/read-linear-window.c:340 +#: src/rs01-verify.c:130 src/rs02-verify.c:123 src/rs03-verify.c:133 +msgid "Sectors with CRC errors" +msgstr "Setores com erros de CRC" + +#: src/read-linear-window.c:321 +msgid "Medium state" +msgstr "Estado da mídia" + +#: src/read-linear-window.c:329 +msgid "Not touched this time" +msgstr "Não tocados dessa vez" + +#: src/read-linear-window.c:336 +msgid "Successfully read" +msgstr "Lidos com sucesso" + +#: src/read-linear-window.c:343 +msgid "Unreadable / skipped" +msgstr "Ilegíveis / pulados" + +#: src/read-linear-window.c:454 +msgid "Speed" +msgstr "Velocidade" #: src/read-linear.c:122 #, c-format @@ -3244,11 +3283,6 @@ msgstr "pronto.\n" msgid "Waiting %d seconds for drive to spin up...\n" msgstr "Aguardando %d segundos para que o drive gire...\n" -#: src/read-linear.c:515 src/read-linear-window.c:109 -#, c-format -msgid "Unreadable / skipped sectors: %" -msgstr "Setores ilegíveis / pulados: %" - #: src/read-linear.c:605 #, c-format msgid "Sector %: Speed increased to %4.1fx\n" @@ -3425,40 +3459,6 @@ msgid "" "Use the --dao option to disable image truncating.\n" msgstr "" -#: src/read-linear-window.c:102 -#, c-format -msgid "Current Speed: %d.%dx" -msgstr "Velocidade atual: %d.%dx" - -#: src/read-linear-window.c:264 src/read-linear-window.c:333 -msgid "Already present" -msgstr "Já presente" - -#: src/read-linear-window.c:298 src/read-linear-window.c:340 -#: src/rs01-verify.c:130 src/rs02-verify.c:123 src/rs03-verify.c:133 -msgid "Sectors with CRC errors" -msgstr "Setores com erros de CRC" - -#: src/read-linear-window.c:321 -msgid "Medium state" -msgstr "Estado da mídia" - -#: src/read-linear-window.c:329 -msgid "Not touched this time" -msgstr "Não tocados dessa vez" - -#: src/read-linear-window.c:336 -msgid "Successfully read" -msgstr "Lidos com sucesso" - -#: src/read-linear-window.c:343 -msgid "Unreadable / skipped" -msgstr "Ilegíveis / pulados" - -#: src/read-linear-window.c:454 -msgid "Speed" -msgstr "Velocidade" - #: src/recover-raw.c:66 #, c-format msgid "Sector % dumped to %s\n" @@ -5695,6 +5695,15 @@ msgstr "" msgid "State:" msgstr "" +#: src/scsi-darwin.c:183 +msgid "No CD/DVD drives found." +msgstr "Nenhum drive de CD/DVD encontrado." + +#: src/scsi-darwin.c:229 +#, c-format +msgid "Could not open %s (%s)." +msgstr "" + #: src/scsi-freebsd.c:49 src/scsi-linux.c:53 msgid "" "Can not access /dev for devices\n" @@ -6116,15 +6125,19 @@ msgid "" "not found.\n" msgstr "" -#: src/show-manual.c:114 +#: src/show-manual.c:118 msgid "Could not create pipe before fork" msgstr "" -#: src/show-manual.c:122 +#: src/show-manual.c:123 src/show-manual.c:128 +msgid "Could not set pipe flags before fork" +msgstr "" + +#: src/show-manual.c:136 msgid "Could not fork to start xdg-open" msgstr "" -#: src/show-manual.c:145 +#: src/show-manual.c:159 #, c-format msgid "" "execvp could not execute \"xdg-open\":\n" @@ -6987,9 +7000,6 @@ msgstr "Novidades dessa versão:" #~ "\n" #~ "Darwin port (Mac OS X) por: Julian Einwag <julian@einwag.de>" -#~ msgid "No CD/DVD drives found." -#~ msgstr "Nenhum drive de CD/DVD encontrado." - #~ msgid "dvdisaster-%s log\n" #~ msgstr "dvdisaster-%s log\n" diff --git a/locale/ru.po b/locale/ru.po index a2a78ba..63197ef 100644 --- a/locale/ru.po +++ b/locale/ru.po @@ -9,7 +9,7 @@ msgid "" msgstr "" "Project-Id-Version: dvdisaster 0.70.4\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-10-09 17:07+0200\n" +"POT-Creation-Date: 2023-09-13 13:48+0200\n" "PO-Revision-Date: 2009-07-23 08:11+0300\n" "Last-Translator: Igor Gorbounov \n" "Language-Team: Russian\n" @@ -19,7 +19,7 @@ msgstr "" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n" -#: src/closure.c:296 +#: src/closure.c:343 #, c-format msgid "" "# dvdisaster-%s configuration file\n" @@ -32,15 +32,15 @@ msgstr "" "# он автоматически перезаписывается при каждом запуске программы.\n" "\n" -#: src/closure.c:564 +#: src/closure.c:648 msgid "medium.iso" msgstr "medium.iso" -#: src/closure.c:565 +#: src/closure.c:649 msgid "medium.ecc" msgstr "medium.ecc" -#: src/closure.c:566 +#: src/closure.c:650 msgid "sector-" msgstr "сектор-" @@ -872,7 +872,7 @@ msgstr "" "GNU General Public License\n" "Лицензионные условия dvdisaster'а." -#: src/help-dialogs.c:515 +#: src/help-dialogs.c:503 #, c-format msgid "" "File\n" @@ -883,7 +883,7 @@ msgstr "" "%s\n" "отсутствует" -#: src/help-dialogs.c:525 +#: src/help-dialogs.c:513 #, c-format msgid "" "File\n" @@ -891,23 +891,23 @@ msgid "" "not accessible" msgstr "" -#: src/help-dialogs.c:537 +#: src/help-dialogs.c:525 msgid "" "\n" "<- Error: Text file truncated here" msgstr "" -#: src/help-dialogs.c:736 +#: src/help-dialogs.c:724 msgid "windowtitle|About dvdisaster" msgstr "О программе dvdisaster" -#: src/help-dialogs.c:755 src/misc.c:219 +#: src/help-dialogs.c:743 src/misc.c:219 msgid "" "Copyright 2004-2017 Carsten Gnoerlich.\n" "Copyright 2019-2021 The dvdisaster development team." msgstr "" -#: src/help-dialogs.c:763 +#: src/help-dialogs.c:751 msgid "" "dvdisaster provides a margin of safety against data loss\n" "on optical media caused by aging or scratches.\n" @@ -919,7 +919,7 @@ msgstr "" "Он создает данные для исправления ошибок, которые используются\n" "для восстановления нечитаемых секторов, если диск впоследствии повреждается.\n" -#: src/help-dialogs.c:768 +#: src/help-dialogs.c:756 msgid "" "This software comes with absolutely no warranty.\n" "This is free software and you are welcome to redistribute it\n" @@ -931,13 +931,13 @@ msgstr "" "\n" "Русский перевод Игоря Горбунова <igor.gorbounov@gmail.com>\n" -#: src/help-dialogs.c:773 +#: src/help-dialogs.c:761 msgid "" "\n" "e-mail: support@dvdisaster.org" msgstr "" -#: src/help-dialogs.c:779 +#: src/help-dialogs.c:767 msgid "" "\n" "This version is not the original. It has been patched\n" @@ -948,7 +948,7 @@ msgid "" "but submit bugreports against [GitHub] instead.\n" msgstr "" -#: src/help-dialogs.c:787 +#: src/help-dialogs.c:775 msgid "" "\n" "NetBSD port: Sergey Svishchev <svs@ropnet.ru>" @@ -1482,6 +1482,30 @@ msgstr "" "Список имеющихся методов:\n" "\n" +#: src/misc-gui.c:241 +#, c-format +msgid "" +"The error correction file is already present:\n" +"\n" +"%s\n" +"\n" +"Overwrite it?" +msgstr "" + +#: src/misc-gui.c:639 +msgid "Do not ask again" +msgstr "" + +#: src/misc-gui.c:660 +#, c-format +msgid "" +"Image file already exists and does not match the medium:\n" +"\n" +"%s\n" +"\n" +"The existing image file will be deleted." +msgstr "" + #: src/misc.c:225 msgid "" "This software comes with ABSOLUTELY NO WARRANTY. This\n" @@ -1545,30 +1569,6 @@ msgstr "" msgid "Image successfully truncated" msgstr "" -#: src/misc-gui.c:241 -#, c-format -msgid "" -"The error correction file is already present:\n" -"\n" -"%s\n" -"\n" -"Overwrite it?" -msgstr "" - -#: src/misc-gui.c:639 -msgid "Do not ask again" -msgstr "" - -#: src/misc-gui.c:660 -#, c-format -msgid "" -"Image file already exists and does not match the medium:\n" -"\n" -"%s\n" -"\n" -"The existing image file will be deleted." -msgstr "" - #: src/preferences.c:454 msgid "Switched to the linear reading strategy." msgstr "Переход на стратегию линейного чтения." @@ -2784,9 +2784,9 @@ msgid "button|Smart L-EC" msgstr "Интеллектуальный L-EC" #: src/raw-sector-cache.c:37 src/raw-sector-cache.c:204 -#: src/raw-sector-cache.c:338 src/scsi-freebsd.c:133 src/scsi-freebsd.c:143 -#: src/scsi-linux.c:117 src/scsi-linux.c:126 src/scsi-netbsd.c:128 -#: src/scsi-netbsd.c:138 src/scsi-win32.c:256 +#: src/raw-sector-cache.c:338 src/scsi-darwin.c:218 src/scsi-freebsd.c:133 +#: src/scsi-freebsd.c:143 src/scsi-linux.c:117 src/scsi-linux.c:126 +#: src/scsi-netbsd.c:128 src/scsi-netbsd.c:138 src/scsi-win32.c:256 #, c-format msgid "Could not open %s: %s" msgstr "Не удалось открыть %s: %s" @@ -2830,6 +2830,36 @@ msgstr " [Создание нового буферного файла %s]\n" msgid " [Appended %d/%d sectors to cache file %s; LBA=%, ssize=%d, %d sectors]\n" msgstr " [Добавлено %d/%d секторов к буферному файлу %s; LBA=%, размер с.=%d, %d секторов]\n" +#: src/read-adaptive-window.c:84 +msgid "Adaptive reading:" +msgstr "Адаптивное чтение:" + +#: src/read-adaptive-window.c:112 +msgid "Sectors processed" +msgstr "Обработанные сектора" + +#: src/read-adaptive-window.c:115 src/scsi-layer.c:1762 +msgid "readable" +msgstr "можно прочитать" + +#: src/read-adaptive-window.c:119 +msgid "correctable" +msgstr "можно исправить" + +#: src/read-adaptive-window.c:123 +msgid "missing" +msgstr "отсутствует" + +#: src/read-adaptive-window.c:133 +#, c-format +msgid "Readable: %d.%d%% / %d.%d%% required" +msgstr "Можно прочитать: %d.%d%% / %d.%d%% требуется" + +#: src/read-adaptive-window.c:140 +#, c-format +msgid "Total recoverable: %d.%d%%" +msgstr "Всего можно восстановить: %d.%d%%" + #: src/read-adaptive.c:57 src/rs01-create.c:1018 #, c-format msgid "" @@ -3165,35 +3195,44 @@ msgstr "" "%s\n" "%2d.%1d%% образа прочитано (% секторов).\n" -#: src/read-adaptive-window.c:84 -msgid "Adaptive reading:" -msgstr "Адаптивное чтение:" - -#: src/read-adaptive-window.c:112 -msgid "Sectors processed" -msgstr "Обработанные сектора" - -#: src/read-adaptive-window.c:115 src/scsi-layer.c:1762 -msgid "readable" -msgstr "можно прочитать" - -#: src/read-adaptive-window.c:119 -msgid "correctable" -msgstr "можно исправить" - -#: src/read-adaptive-window.c:123 -msgid "missing" -msgstr "отсутствует" - -#: src/read-adaptive-window.c:133 +#: src/read-linear-window.c:102 #, c-format -msgid "Readable: %d.%d%% / %d.%d%% required" -msgstr "Можно прочитать: %d.%d%% / %d.%d%% требуется" +msgid "Current Speed: %d.%dx" +msgstr "Текущая скорость: %d.%dx" -#: src/read-adaptive-window.c:140 +#: src/read-linear-window.c:109 src/read-linear.c:515 #, c-format -msgid "Total recoverable: %d.%d%%" -msgstr "Всего можно восстановить: %d.%d%%" +msgid "Unreadable / skipped sectors: %" +msgstr "Нечитаемые / пропущенные сектора: %" + +#: src/read-linear-window.c:264 src/read-linear-window.c:333 +msgid "Already present" +msgstr "Уже есть" + +#: src/read-linear-window.c:298 src/read-linear-window.c:340 +#: src/rs01-verify.c:130 src/rs02-verify.c:123 src/rs03-verify.c:133 +msgid "Sectors with CRC errors" +msgstr "Сектора с CRC-ошибками" + +#: src/read-linear-window.c:321 +msgid "Medium state" +msgstr "Состояние носителя" + +#: src/read-linear-window.c:329 +msgid "Not touched this time" +msgstr "В этот раз не затронут" + +#: src/read-linear-window.c:336 +msgid "Successfully read" +msgstr "Успешно прочитано" + +#: src/read-linear-window.c:343 +msgid "Unreadable / skipped" +msgstr "Нечитаемый / пропущенный" + +#: src/read-linear-window.c:454 +msgid "Speed" +msgstr "Скорость" #: src/read-linear.c:122 #, c-format @@ -3248,11 +3287,6 @@ msgstr "готово.\n" msgid "Waiting %d seconds for drive to spin up...\n" msgstr "Задержка на %d секунд для раскручивания привода...\n" -#: src/read-linear.c:515 src/read-linear-window.c:109 -#, c-format -msgid "Unreadable / skipped sectors: %" -msgstr "Нечитаемые / пропущенные сектора: %" - #: src/read-linear.c:605 #, c-format msgid "Sector %: Speed increased to %4.1fx\n" @@ -3432,40 +3466,6 @@ msgid "" "Use the --dao option to disable image truncating.\n" msgstr "" -#: src/read-linear-window.c:102 -#, c-format -msgid "Current Speed: %d.%dx" -msgstr "Текущая скорость: %d.%dx" - -#: src/read-linear-window.c:264 src/read-linear-window.c:333 -msgid "Already present" -msgstr "Уже есть" - -#: src/read-linear-window.c:298 src/read-linear-window.c:340 -#: src/rs01-verify.c:130 src/rs02-verify.c:123 src/rs03-verify.c:133 -msgid "Sectors with CRC errors" -msgstr "Сектора с CRC-ошибками" - -#: src/read-linear-window.c:321 -msgid "Medium state" -msgstr "Состояние носителя" - -#: src/read-linear-window.c:329 -msgid "Not touched this time" -msgstr "В этот раз не затронут" - -#: src/read-linear-window.c:336 -msgid "Successfully read" -msgstr "Успешно прочитано" - -#: src/read-linear-window.c:343 -msgid "Unreadable / skipped" -msgstr "Нечитаемый / пропущенный" - -#: src/read-linear-window.c:454 -msgid "Speed" -msgstr "Скорость" - #: src/recover-raw.c:66 #, c-format msgid "Sector % dumped to %s\n" @@ -5703,6 +5703,15 @@ msgstr "" msgid "State:" msgstr "" +#: src/scsi-darwin.c:183 +msgid "No CD/DVD drives found." +msgstr "CD/DVD приводов не найдено." + +#: src/scsi-darwin.c:229 +#, c-format +msgid "Could not open %s (%s)." +msgstr "" + #: src/scsi-freebsd.c:49 src/scsi-linux.c:53 msgid "" "Can not access /dev for devices\n" @@ -6127,15 +6136,19 @@ msgid "" "not found.\n" msgstr "" -#: src/show-manual.c:114 +#: src/show-manual.c:118 msgid "Could not create pipe before fork" msgstr "" -#: src/show-manual.c:122 +#: src/show-manual.c:123 src/show-manual.c:128 +msgid "Could not set pipe flags before fork" +msgstr "" + +#: src/show-manual.c:136 msgid "Could not fork to start xdg-open" msgstr "" -#: src/show-manual.c:145 +#: src/show-manual.c:159 #, c-format msgid "" "execvp could not execute \"xdg-open\":\n" @@ -7009,9 +7022,6 @@ msgstr "Новое в этой версии:" #~ "\n" #~ "Порт для Darwin (Mac OS X): Julian Einwag <julian@einwag.de>" -#~ msgid "No CD/DVD drives found." -#~ msgstr "CD/DVD приводов не найдено." - #~ msgid "dvdisaster-%s log\n" #~ msgstr "Журнал dvdisaster-%s\n" diff --git a/locale/sv.po b/locale/sv.po index 0915cb6..4bdf31f 100644 --- a/locale/sv.po +++ b/locale/sv.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: dvdisaster\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-10-09 17:07+0200\n" +"POT-Creation-Date: 2023-09-13 13:48+0200\n" "PO-Revision-Date: 2006-06-14 23:48+0100\n" "Last-Translator: Daniel Nylander \n" "Language-Team: Swedish \n" @@ -17,7 +17,7 @@ msgstr "" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" -#: src/closure.c:296 +#: src/closure.c:343 #, c-format msgid "" "# dvdisaster-%s configuration file\n" @@ -30,15 +30,15 @@ msgstr "" "# som kommer att skrivas över varje gång dvdisaster körs.\n" "\n" -#: src/closure.c:564 +#: src/closure.c:648 msgid "medium.iso" msgstr "" -#: src/closure.c:565 +#: src/closure.c:649 msgid "medium.ecc" msgstr "" -#: src/closure.c:566 +#: src/closure.c:650 msgid "sector-" msgstr "" @@ -856,7 +856,7 @@ msgstr "" "GNU General Public License\n" "Licensvillkoren för dvdisaster." -#: src/help-dialogs.c:515 +#: src/help-dialogs.c:503 #, c-format msgid "" "File\n" @@ -867,7 +867,7 @@ msgstr "" "%s\n" "inte tillgänglig" -#: src/help-dialogs.c:525 +#: src/help-dialogs.c:513 #, c-format msgid "" "File\n" @@ -875,23 +875,23 @@ msgid "" "not accessible" msgstr "" -#: src/help-dialogs.c:537 +#: src/help-dialogs.c:525 msgid "" "\n" "<- Error: Text file truncated here" msgstr "" -#: src/help-dialogs.c:736 +#: src/help-dialogs.c:724 msgid "windowtitle|About dvdisaster" msgstr "Om dvdisaster" -#: src/help-dialogs.c:755 src/misc.c:219 +#: src/help-dialogs.c:743 src/misc.c:219 msgid "" "Copyright 2004-2017 Carsten Gnoerlich.\n" "Copyright 2019-2021 The dvdisaster development team." msgstr "" -#: src/help-dialogs.c:763 +#: src/help-dialogs.c:751 msgid "" "dvdisaster provides a margin of safety against data loss\n" "on optical media caused by aging or scratches.\n" @@ -903,7 +903,7 @@ msgstr "" "Det skapar felkorrigeringsdata som kan användas för att\n" "återskapa oläsliga sektorer om skivan senare blir skadad.\n" -#: src/help-dialogs.c:768 +#: src/help-dialogs.c:756 msgid "" "This software comes with absolutely no warranty.\n" "This is free software and you are welcome to redistribute it\n" @@ -915,13 +915,13 @@ msgstr "" "\n" "Svensk översättning av Daniel Nylander (info@danielnylander.se)\n" -#: src/help-dialogs.c:773 +#: src/help-dialogs.c:761 msgid "" "\n" "e-mail: support@dvdisaster.org" msgstr "" -#: src/help-dialogs.c:779 +#: src/help-dialogs.c:767 msgid "" "\n" "This version is not the original. It has been patched\n" @@ -932,7 +932,7 @@ msgid "" "but submit bugreports against [GitHub] instead.\n" msgstr "" -#: src/help-dialogs.c:787 +#: src/help-dialogs.c:775 msgid "" "\n" "NetBSD port: Sergey Svishchev <svs@ropnet.ru>" @@ -1462,6 +1462,30 @@ msgstr "" "Lista på tillgängliga metoder:\n" "\n" +#: src/misc-gui.c:241 +#, c-format +msgid "" +"The error correction file is already present:\n" +"\n" +"%s\n" +"\n" +"Overwrite it?" +msgstr "" + +#: src/misc-gui.c:639 +msgid "Do not ask again" +msgstr "" + +#: src/misc-gui.c:660 +#, c-format +msgid "" +"Image file already exists and does not match the medium:\n" +"\n" +"%s\n" +"\n" +"The existing image file will be deleted." +msgstr "" + #: src/misc.c:225 msgid "" "This software comes with ABSOLUTELY NO WARRANTY. This\n" @@ -1523,30 +1547,6 @@ msgstr "" msgid "Image successfully truncated" msgstr "" -#: src/misc-gui.c:241 -#, c-format -msgid "" -"The error correction file is already present:\n" -"\n" -"%s\n" -"\n" -"Overwrite it?" -msgstr "" - -#: src/misc-gui.c:639 -msgid "Do not ask again" -msgstr "" - -#: src/misc-gui.c:660 -#, c-format -msgid "" -"Image file already exists and does not match the medium:\n" -"\n" -"%s\n" -"\n" -"The existing image file will be deleted." -msgstr "" - #: src/preferences.c:454 msgid "Switched to the linear reading strategy." msgstr "Växlade till linjär lässtategi." @@ -2607,9 +2607,9 @@ msgid "button|Smart L-EC" msgstr "" #: src/raw-sector-cache.c:37 src/raw-sector-cache.c:204 -#: src/raw-sector-cache.c:338 src/scsi-freebsd.c:133 src/scsi-freebsd.c:143 -#: src/scsi-linux.c:117 src/scsi-linux.c:126 src/scsi-netbsd.c:128 -#: src/scsi-netbsd.c:138 src/scsi-win32.c:256 +#: src/raw-sector-cache.c:338 src/scsi-darwin.c:218 src/scsi-freebsd.c:133 +#: src/scsi-freebsd.c:143 src/scsi-linux.c:117 src/scsi-linux.c:126 +#: src/scsi-netbsd.c:128 src/scsi-netbsd.c:138 src/scsi-win32.c:256 #, c-format msgid "Could not open %s: %s" msgstr "Kunde inte öppna %s: %s" @@ -2653,6 +2653,36 @@ msgstr "" msgid " [Appended %d/%d sectors to cache file %s; LBA=%, ssize=%d, %d sectors]\n" msgstr "" +#: src/read-adaptive-window.c:84 +msgid "Adaptive reading:" +msgstr "Adaptiv läsning:" + +#: src/read-adaptive-window.c:112 +msgid "Sectors processed" +msgstr "Sektorer behandlade" + +#: src/read-adaptive-window.c:115 src/scsi-layer.c:1762 +msgid "readable" +msgstr "läsbar" + +#: src/read-adaptive-window.c:119 +msgid "correctable" +msgstr "korrigerbar" + +#: src/read-adaptive-window.c:123 +msgid "missing" +msgstr "saknas" + +#: src/read-adaptive-window.c:133 +#, c-format +msgid "Readable: %d.%d%% / %d.%d%% required" +msgstr "" + +#: src/read-adaptive-window.c:140 +#, c-format +msgid "Total recoverable: %d.%d%%" +msgstr "Totalt återhämtningsbara: %d.%d%%" + #: src/read-adaptive.c:57 src/rs01-create.c:1018 #, c-format msgid "" @@ -2978,35 +3008,44 @@ msgid "" "%2d.%1d%% of the image have been read (% sectors).\n" msgstr "" -#: src/read-adaptive-window.c:84 -msgid "Adaptive reading:" -msgstr "Adaptiv läsning:" - -#: src/read-adaptive-window.c:112 -msgid "Sectors processed" -msgstr "Sektorer behandlade" - -#: src/read-adaptive-window.c:115 src/scsi-layer.c:1762 -msgid "readable" -msgstr "läsbar" - -#: src/read-adaptive-window.c:119 -msgid "correctable" -msgstr "korrigerbar" - -#: src/read-adaptive-window.c:123 -msgid "missing" -msgstr "saknas" - -#: src/read-adaptive-window.c:133 +#: src/read-linear-window.c:102 #, c-format -msgid "Readable: %d.%d%% / %d.%d%% required" -msgstr "" +msgid "Current Speed: %d.%dx" +msgstr "Aktuell hastighet: %d.%dx" -#: src/read-adaptive-window.c:140 +#: src/read-linear-window.c:109 src/read-linear.c:515 #, c-format -msgid "Total recoverable: %d.%d%%" -msgstr "Totalt återhämtningsbara: %d.%d%%" +msgid "Unreadable / skipped sectors: %" +msgstr "Oläsbara / överhoppade sektorer: %" + +#: src/read-linear-window.c:264 src/read-linear-window.c:333 +msgid "Already present" +msgstr "Finns redan" + +#: src/read-linear-window.c:298 src/read-linear-window.c:340 +#: src/rs01-verify.c:130 src/rs02-verify.c:123 src/rs03-verify.c:133 +msgid "Sectors with CRC errors" +msgstr "Sektorer med CRC-fel" + +#: src/read-linear-window.c:321 +msgid "Medium state" +msgstr "Mediastatus" + +#: src/read-linear-window.c:329 +msgid "Not touched this time" +msgstr "Rörs inte denna gång" + +#: src/read-linear-window.c:336 +msgid "Successfully read" +msgstr "Läsning lyckades" + +#: src/read-linear-window.c:343 +msgid "Unreadable / skipped" +msgstr "Oläsbar / överhoppad" + +#: src/read-linear-window.c:454 +msgid "Speed" +msgstr "Hastighet" #: src/read-linear.c:122 #, c-format @@ -3061,11 +3100,6 @@ msgstr "klar.\n" msgid "Waiting %d seconds for drive to spin up...\n" msgstr "Väntar %d sekunder på att enheten ska varva upp...\n" -#: src/read-linear.c:515 src/read-linear-window.c:109 -#, c-format -msgid "Unreadable / skipped sectors: %" -msgstr "Oläsbara / överhoppade sektorer: %" - #: src/read-linear.c:605 #, c-format msgid "Sector %: Speed increased to %4.1fx\n" @@ -3238,40 +3272,6 @@ msgid "" "Use the --dao option to disable image truncating.\n" msgstr "" -#: src/read-linear-window.c:102 -#, c-format -msgid "Current Speed: %d.%dx" -msgstr "Aktuell hastighet: %d.%dx" - -#: src/read-linear-window.c:264 src/read-linear-window.c:333 -msgid "Already present" -msgstr "Finns redan" - -#: src/read-linear-window.c:298 src/read-linear-window.c:340 -#: src/rs01-verify.c:130 src/rs02-verify.c:123 src/rs03-verify.c:133 -msgid "Sectors with CRC errors" -msgstr "Sektorer med CRC-fel" - -#: src/read-linear-window.c:321 -msgid "Medium state" -msgstr "Mediastatus" - -#: src/read-linear-window.c:329 -msgid "Not touched this time" -msgstr "Rörs inte denna gång" - -#: src/read-linear-window.c:336 -msgid "Successfully read" -msgstr "Läsning lyckades" - -#: src/read-linear-window.c:343 -msgid "Unreadable / skipped" -msgstr "Oläsbar / överhoppad" - -#: src/read-linear-window.c:454 -msgid "Speed" -msgstr "Hastighet" - #: src/recover-raw.c:66 #, c-format msgid "Sector % dumped to %s\n" @@ -5414,6 +5414,15 @@ msgstr "" msgid "State:" msgstr "" +#: src/scsi-darwin.c:183 +msgid "No CD/DVD drives found." +msgstr "Inga cd/dvd-enheter hittades." + +#: src/scsi-darwin.c:229 +#, c-format +msgid "Could not open %s (%s)." +msgstr "" + #: src/scsi-freebsd.c:49 src/scsi-linux.c:53 msgid "" "Can not access /dev for devices\n" @@ -5823,15 +5832,19 @@ msgid "" "not found.\n" msgstr "" -#: src/show-manual.c:114 +#: src/show-manual.c:118 msgid "Could not create pipe before fork" msgstr "" -#: src/show-manual.c:122 +#: src/show-manual.c:123 src/show-manual.c:128 +msgid "Could not set pipe flags before fork" +msgstr "" + +#: src/show-manual.c:136 msgid "Could not fork to start xdg-open" msgstr "" -#: src/show-manual.c:145 +#: src/show-manual.c:159 #, c-format msgid "" "execvp could not execute \"xdg-open\":\n" @@ -6425,9 +6438,6 @@ msgstr "" #~ "Inga cd/dvd-enheter hittades i /dev.\n" #~ "Inga enheter kommer att vara förvalda.\n" -#~ msgid "No CD/DVD drives found." -#~ msgstr "Inga cd/dvd-enheter hittades." - #~ msgid "dvdisaster-%s log\n" #~ msgstr "dvdisaster-%s logg\n" diff --git a/macinst/Info.plist b/macinst/Info.plist new file mode 100644 index 0000000..11d50b0 --- /dev/null +++ b/macinst/Info.plist @@ -0,0 +1,26 @@ + + + + + + + CFBundleExecutable + dvdisaster + CFBundleIconFile + dvdisaster + CFBundleIdentifier + com.dvdisaster.dvdisaster + CFBundleName + dvdisaster + CFBundlePackageType + APPL + CFBundleShortVersionString + 0.79.10 + CFBundleSignature + CGCG + CFBundleVersion + 1 + NSHumanReadableCopyright + © 2004-2009 Carsten Gnörlich et al + + diff --git a/macinst/dvdisaster.icns b/macinst/dvdisaster.icns new file mode 100644 index 0000000..b3ead84 Binary files /dev/null and b/macinst/dvdisaster.icns differ diff --git a/regtest/common.bash b/regtest/common.bash index 1238c24..ce629ff 100644 --- a/regtest/common.bash +++ b/regtest/common.bash @@ -19,9 +19,7 @@ fi # directory for temporary files; e.g. to keep them away from SSDs TMPDIR=/dev/shm if ! test -d $TMPDIR; then - echo "$TMPDIR does not exist." - echo "Please create it manually, or edit common.bash" - exit 0 + TMPDIR=/var/tmp fi LOGDIR="/dev/shm" @@ -33,7 +31,14 @@ DIFFLOG="$LOGDIR/difflog.txt" NEWLOG="$LOGDIR/newlog.txt" TMPLOG="$LOGDIR/tmplog.txt" -MD5SUM=md5sum +UNAME="$(uname -s)" + +if [ "$UNAME" = Darwin ]; then + MD5SUM="md5 -r" +else + MD5SUM=md5sum +fi + if ! $MD5SUM $RNDSEQ >/dev/null 2>&1; then MD5SUM=../simple-md5sum fi @@ -115,7 +120,7 @@ function file_exists() function try() { local doit=$(grep "${CODEC_PREFIX}_$2 " $CONFIGFILE) - if echo "$OS" | grep -q Windows && test -e "$CONFIGFILE_WIN" && grep -q "${CODEC_PREFIX}_$2 " "$CONFIGFILE_WIN"; then + if [[ $OS =~ Windows ]] && test -e "$CONFIGFILE_WIN" && grep -q "${CODEC_PREFIX}_$2 " "$CONFIGFILE_WIN"; then doit=$(grep "${CODEC_PREFIX}_$2 " "$CONFIGFILE_WIN") fi @@ -221,7 +226,12 @@ function run_regtest() testeccopt="-e ${testecc}" fi - REFLOG=${DATABASE}/${CODEC_PREFIX}_${testsymbol} + REFLOG="${DATABASE}/${CODEC_PREFIX}_${testsymbol}" + if [ "$UNAME" = "Darwin" ] && [ -f "$REFLOG.darwin" ]; then + REFLOG="$REFLOG.darwin" + elif [[ $OS =~ Windows ]] && [ -f "$REFLOG.win" ]; then + REFLOG="$REFLOG.win" + fi if test "$gui_mode" == "false"; then rm -f $NEWLOG @@ -253,16 +263,11 @@ function run_regtest() filter=cat echo "$options" | grep -qw SORTED && filter=sort - # for Windows - if [[ $testsymbol =~ _no_device$ ]]; then - sed -i -re "s=device $NON_EXISTENT_DEVICE\.=/dev/sdz: No such file or directory=" $NEWLOG - fi - # for Windows, just remove any path we find: sed -i -re "s=[A-Z]:/[A-Za-z0-9_/-]+/==g" $NEWLOG # remove all paths to get reproducible output: - sed -i -re "s=$TMPDIR/*==g;s=$ISODIR/*==g" $NEWLOG + sed -i -re "s=$TMPDIR/*==g;s=$ISODIR/*==g;s=regtest/==g" $NEWLOG # remote tmp path of github actions sed -i -re "s=[-A-Za-z0-9_~]+/AppData/Local/Temp/==g" $NEWLOG diff --git a/regtest/database/RS01_adaptive_no_device.darwin b/regtest/database/RS01_adaptive_no_device.darwin new file mode 100644 index 0000000..41aa2a3 --- /dev/null +++ b/regtest/database/RS01_adaptive_no_device.darwin @@ -0,0 +1,12 @@ +ignore +ignore +This software comes with ABSOLUTELY NO WARRANTY. This +is free software and you are welcome to redistribute it +under the conditions of the GNU GENERAL PUBLIC LICENSE. +See the file "COPYING" for further information. + +* +* dvdisaster - can not continue: +* +Could not open /dev/sdz (). + diff --git a/regtest/database/RS01_adaptive_no_device.win b/regtest/database/RS01_adaptive_no_device.win new file mode 100644 index 0000000..b2781d0 --- /dev/null +++ b/regtest/database/RS01_adaptive_no_device.win @@ -0,0 +1,12 @@ +ignore +ignore +This software comes with ABSOLUTELY NO WARRANTY. This +is free software and you are welcome to redistribute it +under the conditions of the GNU GENERAL PUBLIC LICENSE. +See the file "COPYING" for further information. + +* +* dvdisaster - can not continue: +* +Could not open device V:. + diff --git a/regtest/database/RS01_adaptive_no_device_access.darwin b/regtest/database/RS01_adaptive_no_device_access.darwin new file mode 100644 index 0000000..1312cd1 --- /dev/null +++ b/regtest/database/RS01_adaptive_no_device_access.darwin @@ -0,0 +1,12 @@ +ignore +ignore +This software comes with ABSOLUTELY NO WARRANTY. This +is free software and you are welcome to redistribute it +under the conditions of the GNU GENERAL PUBLIC LICENSE. +See the file "COPYING" for further information. + +* +* dvdisaster - can not continue: +* +Could not open sdz (). + diff --git a/regtest/database/RS01_read_no_device.darwin b/regtest/database/RS01_read_no_device.darwin new file mode 100644 index 0000000..41aa2a3 --- /dev/null +++ b/regtest/database/RS01_read_no_device.darwin @@ -0,0 +1,12 @@ +ignore +ignore +This software comes with ABSOLUTELY NO WARRANTY. This +is free software and you are welcome to redistribute it +under the conditions of the GNU GENERAL PUBLIC LICENSE. +See the file "COPYING" for further information. + +* +* dvdisaster - can not continue: +* +Could not open /dev/sdz (). + diff --git a/regtest/database/RS01_read_no_device.win b/regtest/database/RS01_read_no_device.win new file mode 100644 index 0000000..b2781d0 --- /dev/null +++ b/regtest/database/RS01_read_no_device.win @@ -0,0 +1,12 @@ +ignore +ignore +This software comes with ABSOLUTELY NO WARRANTY. This +is free software and you are welcome to redistribute it +under the conditions of the GNU GENERAL PUBLIC LICENSE. +See the file "COPYING" for further information. + +* +* dvdisaster - can not continue: +* +Could not open device V:. + diff --git a/regtest/database/RS01_read_no_device_access.darwin b/regtest/database/RS01_read_no_device_access.darwin new file mode 100644 index 0000000..1312cd1 --- /dev/null +++ b/regtest/database/RS01_read_no_device_access.darwin @@ -0,0 +1,12 @@ +ignore +ignore +This software comes with ABSOLUTELY NO WARRANTY. This +is free software and you are welcome to redistribute it +under the conditions of the GNU GENERAL PUBLIC LICENSE. +See the file "COPYING" for further information. + +* +* dvdisaster - can not continue: +* +Could not open sdz (). + diff --git a/regtest/database/RS01_scan_no_device.darwin b/regtest/database/RS01_scan_no_device.darwin new file mode 100644 index 0000000..41aa2a3 --- /dev/null +++ b/regtest/database/RS01_scan_no_device.darwin @@ -0,0 +1,12 @@ +ignore +ignore +This software comes with ABSOLUTELY NO WARRANTY. This +is free software and you are welcome to redistribute it +under the conditions of the GNU GENERAL PUBLIC LICENSE. +See the file "COPYING" for further information. + +* +* dvdisaster - can not continue: +* +Could not open /dev/sdz (). + diff --git a/regtest/database/RS01_scan_no_device.win b/regtest/database/RS01_scan_no_device.win new file mode 100644 index 0000000..b2781d0 --- /dev/null +++ b/regtest/database/RS01_scan_no_device.win @@ -0,0 +1,12 @@ +ignore +ignore +This software comes with ABSOLUTELY NO WARRANTY. This +is free software and you are welcome to redistribute it +under the conditions of the GNU GENERAL PUBLIC LICENSE. +See the file "COPYING" for further information. + +* +* dvdisaster - can not continue: +* +Could not open device V:. + diff --git a/regtest/database/RS01_scan_no_device_access.darwin b/regtest/database/RS01_scan_no_device_access.darwin new file mode 100644 index 0000000..1312cd1 --- /dev/null +++ b/regtest/database/RS01_scan_no_device_access.darwin @@ -0,0 +1,12 @@ +ignore +ignore +This software comes with ABSOLUTELY NO WARRANTY. This +is free software and you are welcome to redistribute it +under the conditions of the GNU GENERAL PUBLIC LICENSE. +See the file "COPYING" for further information. + +* +* dvdisaster - can not continue: +* +Could not open sdz (). + diff --git a/regtest/database/RS03i_read_bad_header_exhaustive.win b/regtest/database/RS03i_read_bad_header_exhaustive.win deleted file mode 100644 index b3c65b4..0000000 --- a/regtest/database/RS03i_read_bad_header_exhaustive.win +++ /dev/null @@ -1,522 +0,0 @@ -ca01afa400e2244fc4797cae542888d1 -ignore -This software comes with ABSOLUTELY NO WARRANTY. This -is free software and you are welcome to redistribute it -under the conditions of the GNU GENERAL PUBLIC LICENSE. -See the file "COPYING" for further information. -# *** OpenImageFromDevice(sim-cd) *** -# InquireDevice returned: Simulated CD drive 1.00 - -Device: sim-cd, Simulated CD drive 1.00 -# *** query_type(Simulated CD drive 1.00, 0) *** -# *** get_configuration(Simulated CD drive 1.00) *** -# 8 data len, 9 current --> profile 9: CD-R -# trying READ DISC INFORMATION for size -# size returned is 32 -# trying READ DISC INFORMATION for real info -0000: 00 20 1e 00 00 00 00 00 00 00 00 00 00 00 00 00 . ...... ........ -0010: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ........ ........ -# status is 1e, disc type 0 -#CD: starting media probe -#CD: querying size of READ TOC/PMA/ATIP (for TOC) -#CD: size returned is 12 -#CD: querying real READ TOC/PMA/ATIP (for TOC) -0000: 00 0a 00 00 00 14 00 00 00 00 00 00 ........ .... -#CD: control is 0x14 -#CD: querying size of READ TOC/PMA/ATIP (for full TOC) -# Warning: Realigning length from 26 to 24 -#CD: size returned is 24 -#CD: querying real READ TOC/PMA/ATIP (for full TOC) -0000: 00 18 00 01 00 00 00 a0 00 00 00 00 00 00 00 00 ........ ........ -0010: 00 00 00 00 00 00 00 00 ........ -#CD: 1 sessions -#CD: CD medium detected, type: CD-R mode 1 -# query_type() returned. -# deciding reading strategy... -Using READ CD. -GetImageFingerprint(16): read & cached - -ExamineUDF(Device: Simulated CD drive 1.00) - Examining the ISO file system... - Sector 16: - Volume descriptor type = 1 - Volume descriptor version = 1 - Standard identifier = CD001 - -> primary volume descriptor: - System identifier : | | - Volume identifier : |RANDOM IMAGE | - Volume space size : 21000 sectors - Volume set size : 1 - Volume sequence size : 1 - Logical block size : 2048 - Path table size : 10 bytes - L-Path table location : 19 - Opt L-Path table location : 0 - M-Path table location : 20 - Opt M-Path table location : 0 - Volume creation date/time : 16-07-2006 10:35:46.23 - Volume modification d/t : 16-07-2006 10:35:46.23 - Volume expiration d/t : 16-07-2106 10:35:46.23 - Volume effective d/t : 16-07-2006 10:35:46.23 - File structure version : 1 - Sector 17: - Volume descriptor type = 2 - Volume descriptor version = 1 - Standard identifier = CD001 - -> supplementary volume descriptor: *skipped* - Sector 18: - Volume descriptor type = 255 - Volume descriptor version = 1 - Standard identifier = CD001 - -> volume descriptor set terminator; - end of ISO file system parsing. - Examining the UDF file system... - not yet implemented. - -# *** read_capacity(Simulated CD drive 1.00) *** - -> 24989 -ExamineECC() started -...trying RS01 -...trying RS02 -RS02Recognize: medium sim-cd -try_sector: trying sector 21000 -try_sector: no cookie, skipping current modulo -try_sector: trying sector 20850 -try_sector: no cookie, skipping current modulo -RS02Recognize: quick RS02 search, attempting up to 3 sector reads max -Medium rewriteable: FALSE -FindHeaderInMedium: Trying modulo 4611686018427387904 -FindHeaderInMedium: Trying modulo 2305843009213693952 -FindHeaderInMedium: Trying modulo 1152921504606846976 -FindHeaderInMedium: Trying modulo 576460752303423488 -FindHeaderInMedium: Trying modulo 288230376151711744 -FindHeaderInMedium: Trying modulo 144115188075855872 -FindHeaderInMedium: Trying modulo 72057594037927936 -FindHeaderInMedium: Trying modulo 36028797018963968 -FindHeaderInMedium: Trying modulo 18014398509481984 -FindHeaderInMedium: Trying modulo 9007199254740992 -FindHeaderInMedium: Trying modulo 4503599627370496 -FindHeaderInMedium: Trying modulo 2251799813685248 -FindHeaderInMedium: Trying modulo 1125899906842624 -FindHeaderInMedium: Trying modulo 562949953421312 -FindHeaderInMedium: Trying modulo 281474976710656 -FindHeaderInMedium: Trying modulo 140737488355328 -FindHeaderInMedium: Trying modulo 70368744177664 -FindHeaderInMedium: Trying modulo 35184372088832 -FindHeaderInMedium: Trying modulo 17592186044416 -FindHeaderInMedium: Trying modulo 8796093022208 -FindHeaderInMedium: Trying modulo 4398046511104 -FindHeaderInMedium: Trying modulo 2199023255552 -FindHeaderInMedium: Trying modulo 1099511627776 -FindHeaderInMedium: Trying modulo 549755813888 -FindHeaderInMedium: Trying modulo 274877906944 -FindHeaderInMedium: Trying modulo 137438953472 -FindHeaderInMedium: Trying modulo 68719476736 -FindHeaderInMedium: Trying modulo 34359738368 -FindHeaderInMedium: Trying modulo 17179869184 -FindHeaderInMedium: Trying modulo 8589934592 -FindHeaderInMedium: Trying modulo 4294967296 -FindHeaderInMedium: Trying modulo 2147483648 -FindHeaderInMedium: Trying modulo 1073741824 -FindHeaderInMedium: Trying modulo 536870912 -FindHeaderInMedium: Trying modulo 268435456 -FindHeaderInMedium: Trying modulo 134217728 -FindHeaderInMedium: Trying modulo 67108864 -FindHeaderInMedium: Trying modulo 33554432 -FindHeaderInMedium: Trying modulo 16777216 -FindHeaderInMedium: Trying modulo 8388608 -FindHeaderInMedium: Trying modulo 4194304 -FindHeaderInMedium: Trying modulo 2097152 -FindHeaderInMedium: Trying modulo 1048576 -FindHeaderInMedium: Trying modulo 524288 -FindHeaderInMedium: Trying modulo 262144 -FindHeaderInMedium: Trying modulo 131072 -FindHeaderInMedium: Trying modulo 65536 -FindHeaderInMedium: Trying modulo 32768 -FindHeaderInMedium: Trying modulo 16384 -try_sector: trying sector 16384 -try_sector: no cookie, skipping current modulo -FindHeaderInMedium: Trying modulo 8192 -try_sector: trying sector 24576 -try_sector: no cookie, skipping current modulo -FindHeaderInMedium: Trying modulo 4096 -Sector 24576 cached; skipping modulo -FindHeaderInMedium: Trying modulo 2048 -Sector 24576 cached; skipping modulo -FindHeaderInMedium: Trying modulo 1024 -Sector 24576 cached; skipping modulo -FindHeaderInMedium: Trying modulo 512 -Sector 24576 cached; skipping modulo -FindHeaderInMedium: Trying modulo 256 -try_sector: trying sector 24832 -try_sector: no cookie, skipping current modulo -...trying RS03 -RS03RecognizeImage: medium sim-cd -FindRS03HeaderInImage: medium sim-cd -RS03RecognizeImage: No EH, entering exhaustive search -Warning: image size set to 25000 for debugging! -.. trying layer size 98 -Scanning layers for signatures. -- layer slice 0 -RS03: try number = 1, reading sector 8232 -RS03: try number = 2, reading sector 8330 -RS03: try number = 3, reading sector 8428 -RS03: try number = 4, reading sector 8526 -RS03: try number = 5, reading sector 8624 -RS03: try number = 6, reading sector 8722 -RS03: try number = 7, reading sector 8820 -RS03: try number = 8, reading sector 8918 -RS03: try number = 9, reading sector 9016 -RS03: try number = 10, reading sector 9114 -RS03: try number = 11, reading sector 9212 -RS03: try number = 12, reading sector 9310 -RS03: try number = 13, reading sector 9408 -RS03: try number = 14, reading sector 9506 -RS03: try number = 15, reading sector 9604 -RS03: try number = 16, reading sector 9702 -RS03: try number = 17, reading sector 9800 -RS03: try number = 18, reading sector 9898 -RS03: try number = 19, reading sector 9996 -RS03: try number = 20, reading sector 10094 -RS03: try number = 21, reading sector 10192 -RS03: try number = 22, reading sector 10290 -RS03: try number = 23, reading sector 10388 -RS03: try number = 24, reading sector 10486 -RS03: try number = 25, reading sector 10584 -RS03: try number = 26, reading sector 10682 -RS03: try number = 27, reading sector 10780 -RS03: try number = 28, reading sector 10878 -RS03: try number = 29, reading sector 10976 -RS03: try number = 30, reading sector 11074 -RS03: try number = 31, reading sector 11172 -RS03: try number = 32, reading sector 11270 -RS03: try number = 33, reading sector 11368 -RS03: try number = 34, reading sector 11466 -RS03: try number = 35, reading sector 11564 -RS03: try number = 36, reading sector 11662 -RS03: try number = 37, reading sector 11760 -RS03: try number = 38, reading sector 11858 -RS03: try number = 39, reading sector 11956 -RS03: try number = 40, reading sector 12054 -RS03: try number = 41, reading sector 12152 -RS03: try number = 42, reading sector 12250 -RS03: try number = 43, reading sector 12348 -RS03: try number = 44, reading sector 12446 -RS03: try number = 45, reading sector 12544 -RS03: try number = 46, reading sector 12642 -RS03: try number = 47, reading sector 12740 -RS03: try number = 48, reading sector 12838 -RS03: try number = 49, reading sector 12936 -RS03: try number = 50, reading sector 13034 -RS03: try number = 51, reading sector 13132 -RS03: try number = 52, reading sector 13230 -RS03: try number = 53, reading sector 13328 -RS03: try number = 54, reading sector 13426 -RS03: try number = 55, reading sector 13524 -RS03: try number = 56, reading sector 13622 -RS03: try number = 57, reading sector 13720 -RS03: try number = 58, reading sector 13818 -RS03: try number = 59, reading sector 13916 -RS03: try number = 60, reading sector 14014 -RS03: try number = 61, reading sector 14112 -RS03: try number = 62, reading sector 14210 -RS03: try number = 63, reading sector 14308 -RS03: try number = 64, reading sector 14406 -RS03: try number = 65, reading sector 14504 -RS03: try number = 66, reading sector 14602 -RS03: try number = 67, reading sector 14700 -RS03: try number = 68, reading sector 14798 -RS03: try number = 69, reading sector 14896 -RS03: try number = 70, reading sector 14994 -RS03: try number = 71, reading sector 15092 -RS03: try number = 72, reading sector 15190 -RS03: try number = 73, reading sector 15288 -RS03: try number = 74, reading sector 15386 -RS03: try number = 75, reading sector 15484 -RS03: try number = 76, reading sector 15582 -RS03: try number = 77, reading sector 15680 -RS03: try number = 78, reading sector 15778 -RS03: try number = 79, reading sector 15876 -RS03: try number = 80, reading sector 15974 -RS03: try number = 81, reading sector 16072 -RS03: try number = 82, reading sector 16170 -RS03: try number = 83, reading sector 16268 -RS03: try number = 84, reading sector 16366 -RS03: try number = 85, reading sector 16464 -RS03: try number = 86, reading sector 16562 -RS03: try number = 87, reading sector 16660 -RS03: try number = 88, reading sector 16758 -RS03: try number = 89, reading sector 16856 -RS03: try number = 90, reading sector 16954 -RS03: try number = 91, reading sector 17052 -RS03: try number = 92, reading sector 17150 -RS03: try number = 93, reading sector 17248 -RS03: try number = 94, reading sector 17346 -RS03: try number = 95, reading sector 17444 -RS03: try number = 96, reading sector 17542 -RS03: try number = 97, reading sector 17640 -RS03: try number = 98, reading sector 17738 -RS03: try number = 99, reading sector 17836 -RS03: try number = 100, reading sector 17934 -RS03: try number = 101, reading sector 18032 -RS03: try number = 102, reading sector 18130 -RS03: try number = 103, reading sector 18228 -RS03: try number = 104, reading sector 18326 -RS03: try number = 105, reading sector 18424 -RS03: try number = 106, reading sector 18522 -RS03: try number = 107, reading sector 18620 -RS03: try number = 108, reading sector 18718 -RS03: try number = 109, reading sector 18816 -RS03: try number = 110, reading sector 18914 -RS03: try number = 111, reading sector 19012 -RS03: try number = 112, reading sector 19110 -RS03: try number = 113, reading sector 19208 -RS03: try number = 114, reading sector 19306 -RS03: try number = 115, reading sector 19404 -RS03: try number = 116, reading sector 19502 -RS03: try number = 117, reading sector 19600 -RS03: try number = 118, reading sector 19698 -RS03: try number = 119, reading sector 19796 -RS03: try number = 120, reading sector 19894 -RS03: try number = 121, reading sector 19992 -RS03: try number = 122, reading sector 20090 -RS03: try number = 123, reading sector 20188 -RS03: try number = 124, reading sector 20286 -RS03: try number = 125, reading sector 20384 -RS03: try number = 126, reading sector 20482 -RS03: try number = 127, reading sector 20580 -RS03: try number = 128, reading sector 20678 -RS03: try number = 129, reading sector 20776 -RS03: try number = 130, reading sector 20874 -RS03: try number = 131, reading sector 20972 -RS03: try number = 132, reading sector 21070 -** Success: sector 21070, rediscovered format with 39 roots -...augmented image found -# Calling query_size() -# *** query_size(Simulated CD drive 1.00) *** -Medium size obtained from ECC header: 24990 sectors -# returned: 24990 sectors -Medium "Random Image": CD-R mode 1, 24990 sectors, Ecc, created 16-07-2006. - -Creating new rs03i-tmp.iso image. -Reading CRC information from ecc data (RS03) ... Calculated layout for RS03 image: -data sectors = 21000 -data padding = 68 -layer size = 98 -total sectors = 24990 -medium capacity = 0 -header position = 21000 -first CRC sector = 21070 -first ECC sector = 21168 -ndata = 216 -nroots = 39 (18.1%) - -done. -* CRC error, sector: 21000 -Current sector: 22032. This session: NewSectorsReadOK=22032, ReadErrors=0, CRCErrors=1 -Current sector: 22048. This session: NewSectorsReadOK=22048, ReadErrors=0, CRCErrors=1 -Current sector: 22064. This session: NewSectorsReadOK=22064, ReadErrors=0, CRCErrors=1 -Current sector: 22080. This session: NewSectorsReadOK=22080, ReadErrors=0, CRCErrors=1 -Current sector: 22096. This session: NewSectorsReadOK=22096, ReadErrors=0, CRCErrors=1 -Current sector: 22112. This session: NewSectorsReadOK=22112, ReadErrors=0, CRCErrors=1 -Current sector: 22128. This session: NewSectorsReadOK=22128, ReadErrors=0, CRCErrors=1 -Current sector: 22144. This session: NewSectorsReadOK=22144, ReadErrors=0, CRCErrors=1 -Current sector: 22160. This session: NewSectorsReadOK=22160, ReadErrors=0, CRCErrors=1 -Current sector: 22176. This session: NewSectorsReadOK=22176, ReadErrors=0, CRCErrors=1 -Current sector: 22192. This session: NewSectorsReadOK=22192, ReadErrors=0, CRCErrors=1 -Current sector: 22208. This session: NewSectorsReadOK=22208, ReadErrors=0, CRCErrors=1 -Current sector: 22224. This session: NewSectorsReadOK=22224, ReadErrors=0, CRCErrors=1 -Current sector: 22240. This session: NewSectorsReadOK=22240, ReadErrors=0, CRCErrors=1 -Current sector: 22256. This session: NewSectorsReadOK=22256, ReadErrors=0, CRCErrors=1 -Current sector: 22272. This session: NewSectorsReadOK=22272, ReadErrors=0, CRCErrors=1 -Current sector: 22288. This session: NewSectorsReadOK=22288, ReadErrors=0, CRCErrors=1 -Current sector: 22304. This session: NewSectorsReadOK=22304, ReadErrors=0, CRCErrors=1 -Current sector: 22320. This session: NewSectorsReadOK=22320, ReadErrors=0, CRCErrors=1 -Current sector: 22336. This session: NewSectorsReadOK=22336, ReadErrors=0, CRCErrors=1 -Current sector: 22352. This session: NewSectorsReadOK=22352, ReadErrors=0, CRCErrors=1 -Current sector: 22368. This session: NewSectorsReadOK=22368, ReadErrors=0, CRCErrors=1 -Current sector: 22384. This session: NewSectorsReadOK=22384, ReadErrors=0, CRCErrors=1 -Current sector: 22400. This session: NewSectorsReadOK=22400, ReadErrors=0, CRCErrors=1 -Current sector: 22416. This session: NewSectorsReadOK=22416, ReadErrors=0, CRCErrors=1 -Current sector: 22432. This session: NewSectorsReadOK=22432, ReadErrors=0, CRCErrors=1 -Current sector: 22448. This session: NewSectorsReadOK=22448, ReadErrors=0, CRCErrors=1 -Current sector: 22464. This session: NewSectorsReadOK=22464, ReadErrors=0, CRCErrors=1 -Current sector: 22480. This session: NewSectorsReadOK=22480, ReadErrors=0, CRCErrors=1 -Current sector: 22496. This session: NewSectorsReadOK=22496, ReadErrors=0, CRCErrors=1 -Current sector: 22512. This session: NewSectorsReadOK=22512, ReadErrors=0, CRCErrors=1 -Current sector: 22528. This session: NewSectorsReadOK=22528, ReadErrors=0, CRCErrors=1 -Current sector: 22544. This session: NewSectorsReadOK=22544, ReadErrors=0, CRCErrors=1 -Current sector: 22560. This session: NewSectorsReadOK=22560, ReadErrors=0, CRCErrors=1 -Current sector: 22576. This session: NewSectorsReadOK=22576, ReadErrors=0, CRCErrors=1 -Current sector: 22592. This session: NewSectorsReadOK=22592, ReadErrors=0, CRCErrors=1 -Current sector: 22608. This session: NewSectorsReadOK=22608, ReadErrors=0, CRCErrors=1 -Current sector: 22624. This session: NewSectorsReadOK=22624, ReadErrors=0, CRCErrors=1 -Current sector: 22640. This session: NewSectorsReadOK=22640, ReadErrors=0, CRCErrors=1 -Current sector: 22656. This session: NewSectorsReadOK=22656, ReadErrors=0, CRCErrors=1 -Current sector: 22672. This session: NewSectorsReadOK=22672, ReadErrors=0, CRCErrors=1 -Current sector: 22688. This session: NewSectorsReadOK=22688, ReadErrors=0, CRCErrors=1 -Current sector: 22704. This session: NewSectorsReadOK=22704, ReadErrors=0, CRCErrors=1 -Current sector: 22720. This session: NewSectorsReadOK=22720, ReadErrors=0, CRCErrors=1 -Current sector: 22736. This session: NewSectorsReadOK=22736, ReadErrors=0, CRCErrors=1 -Current sector: 22752. This session: NewSectorsReadOK=22752, ReadErrors=0, CRCErrors=1 -Current sector: 22768. This session: NewSectorsReadOK=22768, ReadErrors=0, CRCErrors=1 -Current sector: 22784. This session: NewSectorsReadOK=22784, ReadErrors=0, CRCErrors=1 -Current sector: 22800. This session: NewSectorsReadOK=22800, ReadErrors=0, CRCErrors=1 -Current sector: 22816. This session: NewSectorsReadOK=22816, ReadErrors=0, CRCErrors=1 -Current sector: 22832. This session: NewSectorsReadOK=22832, ReadErrors=0, CRCErrors=1 -Current sector: 22848. This session: NewSectorsReadOK=22848, ReadErrors=0, CRCErrors=1 -Current sector: 22864. This session: NewSectorsReadOK=22864, ReadErrors=0, CRCErrors=1 -Current sector: 22880. This session: NewSectorsReadOK=22880, ReadErrors=0, CRCErrors=1 -Current sector: 22896. This session: NewSectorsReadOK=22896, ReadErrors=0, CRCErrors=1 -Current sector: 22912. This session: NewSectorsReadOK=22912, ReadErrors=0, CRCErrors=1 -Current sector: 22928. This session: NewSectorsReadOK=22928, ReadErrors=0, CRCErrors=1 -Current sector: 22944. This session: NewSectorsReadOK=22944, ReadErrors=0, CRCErrors=1 -Current sector: 22960. This session: NewSectorsReadOK=22960, ReadErrors=0, CRCErrors=1 -Current sector: 22976. This session: NewSectorsReadOK=22976, ReadErrors=0, CRCErrors=1 -Current sector: 22992. This session: NewSectorsReadOK=22992, ReadErrors=0, CRCErrors=1 -Current sector: 23008. This session: NewSectorsReadOK=23008, ReadErrors=0, CRCErrors=1 -Current sector: 23024. This session: NewSectorsReadOK=23024, ReadErrors=0, CRCErrors=1 -Current sector: 23040. This session: NewSectorsReadOK=23040, ReadErrors=0, CRCErrors=1 -Current sector: 23056. This session: NewSectorsReadOK=23056, ReadErrors=0, CRCErrors=1 -Current sector: 23072. This session: NewSectorsReadOK=23072, ReadErrors=0, CRCErrors=1 -Current sector: 23088. This session: NewSectorsReadOK=23088, ReadErrors=0, CRCErrors=1 -Current sector: 23104. This session: NewSectorsReadOK=23104, ReadErrors=0, CRCErrors=1 -Current sector: 23120. This session: NewSectorsReadOK=23120, ReadErrors=0, CRCErrors=1 -Current sector: 23136. This session: NewSectorsReadOK=23136, ReadErrors=0, CRCErrors=1 -Current sector: 23152. This session: NewSectorsReadOK=23152, ReadErrors=0, CRCErrors=1 -Current sector: 23168. This session: NewSectorsReadOK=23168, ReadErrors=0, CRCErrors=1 -Current sector: 23184. This session: NewSectorsReadOK=23184, ReadErrors=0, CRCErrors=1 -Current sector: 23200. This session: NewSectorsReadOK=23200, ReadErrors=0, CRCErrors=1 -Current sector: 23216. This session: NewSectorsReadOK=23216, ReadErrors=0, CRCErrors=1 -Current sector: 23232. This session: NewSectorsReadOK=23232, ReadErrors=0, CRCErrors=1 -Current sector: 23248. This session: NewSectorsReadOK=23248, ReadErrors=0, CRCErrors=1 -Current sector: 23264. This session: NewSectorsReadOK=23264, ReadErrors=0, CRCErrors=1 -Current sector: 23280. This session: NewSectorsReadOK=23280, ReadErrors=0, CRCErrors=1 -Current sector: 23296. This session: NewSectorsReadOK=23296, ReadErrors=0, CRCErrors=1 -Current sector: 23312. This session: NewSectorsReadOK=23312, ReadErrors=0, CRCErrors=1 -Current sector: 23328. This session: NewSectorsReadOK=23328, ReadErrors=0, CRCErrors=1 -Current sector: 23344. This session: NewSectorsReadOK=23344, ReadErrors=0, CRCErrors=1 -Current sector: 23360. This session: NewSectorsReadOK=23360, ReadErrors=0, CRCErrors=1 -Current sector: 23376. This session: NewSectorsReadOK=23376, ReadErrors=0, CRCErrors=1 -Current sector: 23392. This session: NewSectorsReadOK=23392, ReadErrors=0, CRCErrors=1 -Current sector: 23408. This session: NewSectorsReadOK=23408, ReadErrors=0, CRCErrors=1 -Current sector: 23424. This session: NewSectorsReadOK=23424, ReadErrors=0, CRCErrors=1 -Current sector: 23440. This session: NewSectorsReadOK=23440, ReadErrors=0, CRCErrors=1 -Current sector: 23456. This session: NewSectorsReadOK=23456, ReadErrors=0, CRCErrors=1 -Current sector: 23472. This session: NewSectorsReadOK=23472, ReadErrors=0, CRCErrors=1 -Current sector: 23488. This session: NewSectorsReadOK=23488, ReadErrors=0, CRCErrors=1 -Current sector: 23504. This session: NewSectorsReadOK=23504, ReadErrors=0, CRCErrors=1 -Current sector: 23520. This session: NewSectorsReadOK=23520, ReadErrors=0, CRCErrors=1 -Current sector: 23536. This session: NewSectorsReadOK=23536, ReadErrors=0, CRCErrors=1 -Current sector: 23552. This session: NewSectorsReadOK=23552, ReadErrors=0, CRCErrors=1 -Current sector: 23568. This session: NewSectorsReadOK=23568, ReadErrors=0, CRCErrors=1 -Current sector: 23584. This session: NewSectorsReadOK=23584, ReadErrors=0, CRCErrors=1 -Current sector: 23600. This session: NewSectorsReadOK=23600, ReadErrors=0, CRCErrors=1 -Current sector: 23616. This session: NewSectorsReadOK=23616, ReadErrors=0, CRCErrors=1 -Current sector: 23632. This session: NewSectorsReadOK=23632, ReadErrors=0, CRCErrors=1 -Current sector: 23648. This session: NewSectorsReadOK=23648, ReadErrors=0, CRCErrors=1 -Current sector: 23664. This session: NewSectorsReadOK=23664, ReadErrors=0, CRCErrors=1 -Current sector: 23680. This session: NewSectorsReadOK=23680, ReadErrors=0, CRCErrors=1 -Current sector: 23696. This session: NewSectorsReadOK=23696, ReadErrors=0, CRCErrors=1 -Current sector: 23712. This session: NewSectorsReadOK=23712, ReadErrors=0, CRCErrors=1 -Current sector: 23728. This session: NewSectorsReadOK=23728, ReadErrors=0, CRCErrors=1 -Current sector: 23744. This session: NewSectorsReadOK=23744, ReadErrors=0, CRCErrors=1 -Current sector: 23760. This session: NewSectorsReadOK=23760, ReadErrors=0, CRCErrors=1 -Current sector: 23776. This session: NewSectorsReadOK=23776, ReadErrors=0, CRCErrors=1 -Current sector: 23792. This session: NewSectorsReadOK=23792, ReadErrors=0, CRCErrors=1 -Current sector: 23808. This session: NewSectorsReadOK=23808, ReadErrors=0, CRCErrors=1 -Current sector: 23824. This session: NewSectorsReadOK=23824, ReadErrors=0, CRCErrors=1 -Current sector: 23840. This session: NewSectorsReadOK=23840, ReadErrors=0, CRCErrors=1 -Current sector: 23856. This session: NewSectorsReadOK=23856, ReadErrors=0, CRCErrors=1 -Current sector: 23872. This session: NewSectorsReadOK=23872, ReadErrors=0, CRCErrors=1 -Current sector: 23888. This session: NewSectorsReadOK=23888, ReadErrors=0, CRCErrors=1 -Current sector: 23904. This session: NewSectorsReadOK=23904, ReadErrors=0, CRCErrors=1 -Current sector: 23920. This session: NewSectorsReadOK=23920, ReadErrors=0, CRCErrors=1 -Current sector: 23936. This session: NewSectorsReadOK=23936, ReadErrors=0, CRCErrors=1 -Current sector: 23952. This session: NewSectorsReadOK=23952, ReadErrors=0, CRCErrors=1 -Current sector: 23968. This session: NewSectorsReadOK=23968, ReadErrors=0, CRCErrors=1 -Current sector: 23984. This session: NewSectorsReadOK=23984, ReadErrors=0, CRCErrors=1 -Current sector: 24000. This session: NewSectorsReadOK=24000, ReadErrors=0, CRCErrors=1 -Current sector: 24016. This session: NewSectorsReadOK=24016, ReadErrors=0, CRCErrors=1 -Current sector: 24032. This session: NewSectorsReadOK=24032, ReadErrors=0, CRCErrors=1 -Current sector: 24048. This session: NewSectorsReadOK=24048, ReadErrors=0, CRCErrors=1 -Current sector: 24064. This session: NewSectorsReadOK=24064, ReadErrors=0, CRCErrors=1 -Current sector: 24080. This session: NewSectorsReadOK=24080, ReadErrors=0, CRCErrors=1 -Current sector: 24096. This session: NewSectorsReadOK=24096, ReadErrors=0, CRCErrors=1 -Current sector: 24112. This session: NewSectorsReadOK=24112, ReadErrors=0, CRCErrors=1 -Current sector: 24128. This session: NewSectorsReadOK=24128, ReadErrors=0, CRCErrors=1 -Current sector: 24144. This session: NewSectorsReadOK=24144, ReadErrors=0, CRCErrors=1 -Current sector: 24160. This session: NewSectorsReadOK=24160, ReadErrors=0, CRCErrors=1 -Current sector: 24176. This session: NewSectorsReadOK=24176, ReadErrors=0, CRCErrors=1 -Current sector: 24192. This session: NewSectorsReadOK=24192, ReadErrors=0, CRCErrors=1 -Current sector: 24208. This session: NewSectorsReadOK=24208, ReadErrors=0, CRCErrors=1 -Current sector: 24224. This session: NewSectorsReadOK=24224, ReadErrors=0, CRCErrors=1 -Current sector: 24240. This session: NewSectorsReadOK=24240, ReadErrors=0, CRCErrors=1 -Current sector: 24256. This session: NewSectorsReadOK=24256, ReadErrors=0, CRCErrors=1 -Current sector: 24272. This session: NewSectorsReadOK=24272, ReadErrors=0, CRCErrors=1 -Current sector: 24288. This session: NewSectorsReadOK=24288, ReadErrors=0, CRCErrors=1 -Current sector: 24304. This session: NewSectorsReadOK=24304, ReadErrors=0, CRCErrors=1 -Current sector: 24320. This session: NewSectorsReadOK=24320, ReadErrors=0, CRCErrors=1 -Current sector: 24336. This session: NewSectorsReadOK=24336, ReadErrors=0, CRCErrors=1 -Current sector: 24352. This session: NewSectorsReadOK=24352, ReadErrors=0, CRCErrors=1 -Current sector: 24368. This session: NewSectorsReadOK=24368, ReadErrors=0, CRCErrors=1 -Current sector: 24384. This session: NewSectorsReadOK=24384, ReadErrors=0, CRCErrors=1 -Current sector: 24400. This session: NewSectorsReadOK=24400, ReadErrors=0, CRCErrors=1 -Current sector: 24416. This session: NewSectorsReadOK=24416, ReadErrors=0, CRCErrors=1 -Current sector: 24432. This session: NewSectorsReadOK=24432, ReadErrors=0, CRCErrors=1 -Current sector: 24448. This session: NewSectorsReadOK=24448, ReadErrors=0, CRCErrors=1 -Current sector: 24464. This session: NewSectorsReadOK=24464, ReadErrors=0, CRCErrors=1 -Current sector: 24480. This session: NewSectorsReadOK=24480, ReadErrors=0, CRCErrors=1 -Current sector: 24496. This session: NewSectorsReadOK=24496, ReadErrors=0, CRCErrors=1 -Current sector: 24512. This session: NewSectorsReadOK=24512, ReadErrors=0, CRCErrors=1 -Current sector: 24528. This session: NewSectorsReadOK=24528, ReadErrors=0, CRCErrors=1 -Current sector: 24544. This session: NewSectorsReadOK=24544, ReadErrors=0, CRCErrors=1 -Current sector: 24560. This session: NewSectorsReadOK=24560, ReadErrors=0, CRCErrors=1 -Current sector: 24576. This session: NewSectorsReadOK=24576, ReadErrors=0, CRCErrors=1 -Current sector: 24592. This session: NewSectorsReadOK=24592, ReadErrors=0, CRCErrors=1 -Current sector: 24608. This session: NewSectorsReadOK=24608, ReadErrors=0, CRCErrors=1 -Current sector: 24624. This session: NewSectorsReadOK=24624, ReadErrors=0, CRCErrors=1 -Current sector: 24640. This session: NewSectorsReadOK=24640, ReadErrors=0, CRCErrors=1 -Current sector: 24656. This session: NewSectorsReadOK=24656, ReadErrors=0, CRCErrors=1 -Current sector: 24672. This session: NewSectorsReadOK=24672, ReadErrors=0, CRCErrors=1 -Current sector: 24688. This session: NewSectorsReadOK=24688, ReadErrors=0, CRCErrors=1 -Current sector: 24704. This session: NewSectorsReadOK=24704, ReadErrors=0, CRCErrors=1 -Current sector: 24720. This session: NewSectorsReadOK=24720, ReadErrors=0, CRCErrors=1 -Current sector: 24736. This session: NewSectorsReadOK=24736, ReadErrors=0, CRCErrors=1 -Current sector: 24752. This session: NewSectorsReadOK=24752, ReadErrors=0, CRCErrors=1 -Current sector: 24768. This session: NewSectorsReadOK=24768, ReadErrors=0, CRCErrors=1 -Current sector: 24784. This session: NewSectorsReadOK=24784, ReadErrors=0, CRCErrors=1 -Current sector: 24800. This session: NewSectorsReadOK=24800, ReadErrors=0, CRCErrors=1 -Current sector: 24816. This session: NewSectorsReadOK=24816, ReadErrors=0, CRCErrors=1 -Current sector: 24832. This session: NewSectorsReadOK=24832, ReadErrors=0, CRCErrors=1 -Current sector: 24848. This session: NewSectorsReadOK=24848, ReadErrors=0, CRCErrors=1 -Current sector: 24864. This session: NewSectorsReadOK=24864, ReadErrors=0, CRCErrors=1 -Current sector: 24880. This session: NewSectorsReadOK=24880, ReadErrors=0, CRCErrors=1 -Current sector: 24896. This session: NewSectorsReadOK=24896, ReadErrors=0, CRCErrors=1 -Current sector: 24912. This session: NewSectorsReadOK=24912, ReadErrors=0, CRCErrors=1 -Current sector: 24928. This session: NewSectorsReadOK=24928, ReadErrors=0, CRCErrors=1 -Current sector: 24944. This session: NewSectorsReadOK=24944, ReadErrors=0, CRCErrors=1 -Current sector: 24960. This session: NewSectorsReadOK=24960, ReadErrors=0, CRCErrors=1 -Current sector: 24976. This session: NewSectorsReadOK=24976, ReadErrors=0, CRCErrors=1 -Current sector: 24977. This session: NewSectorsReadOK=24977, ReadErrors=0, CRCErrors=1 -Current sector: 24978. This session: NewSectorsReadOK=24978, ReadErrors=0, CRCErrors=1 -Current sector: 24979. This session: NewSectorsReadOK=24979, ReadErrors=0, CRCErrors=1 -Current sector: 24980. This session: NewSectorsReadOK=24980, ReadErrors=0, CRCErrors=1 -Current sector: 24981. This session: NewSectorsReadOK=24981, ReadErrors=0, CRCErrors=1 -Current sector: 24982. This session: NewSectorsReadOK=24982, ReadErrors=0, CRCErrors=1 -Current sector: 24983. This session: NewSectorsReadOK=24983, ReadErrors=0, CRCErrors=1 -Current sector: 24984. This session: NewSectorsReadOK=24984, ReadErrors=0, CRCErrors=1 -Current sector: 24985. This session: NewSectorsReadOK=24985, ReadErrors=0, CRCErrors=1 -Current sector: 24986. This session: NewSectorsReadOK=24986, ReadErrors=0, CRCErrors=1 -Current sector: 24987. This session: NewSectorsReadOK=24987, ReadErrors=0, CRCErrors=1 -Current sector: 24988. This session: NewSectorsReadOK=24988, ReadErrors=0, CRCErrors=1 -Current sector: 24989. This session: NewSectorsReadOK=24989, ReadErrors=0, CRCErrors=1 -Current sector: 24990. This session: NewSectorsReadOK=24990, ReadErrors=0, CRCErrors=1 - -1 CRC errors. -CrcBuf contents, image path none (medium): - crcSize: 24990, dataSectors: 21000, coveredSectors: 21070, allSectors: 24990 - md5State: invalid - fp sector: 16; 15c0fd35a0cfa0f83b9ccbd8604c2592 - missing crcs: 0 diff --git a/scripts/bash-based-configure b/scripts/bash-based-configure index 163c04f..528d17e 100644 --- a/scripts/bash-based-configure +++ b/scripts/bash-based-configure @@ -127,6 +127,15 @@ case "$cfg_uname" in } ;; + Darwin*) cfg_system=darwin + CFG_SYS_OPTIONS="-DSYS_DARWIN" + CFG_SYS_NAME="-DSYS_NAME=\\\"Darwin\\\"" + CFG_EXE_SUFFIX="" + function add_linker_flags() + { lflags_return="-L$1 -Wl,-rpath,$1 $2" + } + ;; + FreeBSD*) cfg_system=freebsd-std CFG_SYS_OPTIONS="-DSYS_FREEBSD" CFG_SYS_NAME="-DSYS_NAME=\\\"FreeBSD\\\"" @@ -348,6 +357,42 @@ function REQUIRE_GMAKE() exit 1; } +function REQUIRE_CLANG() +{ + if test -n "$cfg_help_mode"; then + return 0 + fi + + echo -n "Checking for clang: " + + # Try $CC first + + if test -n "$CC" && $CC -v >/dev/null 2>&1; then + if ($CC -v 2>&1 | grep "clang") > /dev/null 2>&1 ; then + CC=`type -P $CC` + echo "yes ($CC)" + echo "CC = $CC" >>Makefile.config + return 0 + fi + fi + + # Try clang binary + + CC=clang + if test -n "$CC" && $CC -v >/dev/null 2>&1; then + if ($CC -v 2>&1 | grep "clang") > /dev/null 2>&1 ; then + CC=`type -P $CC` + echo "yes ($CC)" + echo "CC = $CC" >>Makefile.config + return 0 + fi + fi + + echo "no" + echo "This package requires the Clang C compiler (clang)." + exit 1; +} + function REQUIRE_GCC() { if test -n "$cfg_help_mode"; then diff --git a/src/closure.c b/src/closure.c index 57d58ed..1e4600b 100644 --- a/src/closure.c +++ b/src/closure.c @@ -58,6 +58,35 @@ static char* get_exe_path() } #endif +#ifdef SYS_DARWIN +#include + +// Get the path of the current executable +static char* get_bin_path() { + char path[PATH_MAX]; + uint32_t size = sizeof(path); + + if (_NSGetExecutablePath(path, &size) == 0) { + char *lastSlash = strrchr(path, '/'); + if (lastSlash) { + *lastSlash = '\0'; + return strdup(path); + } + } + + return strdup("."); +} + +// Check if the given path is within an app bundle +int isWithinAppBundle(const char *filePath) { + // Check if "Contents/MacOS" exists in the path + if (strstr(filePath, ".app/Contents/MacOS") != NULL) { + return 1; // The binary is within an app bundle + } + return 0; // The binary is not within an app bundle +} +#endif + #ifdef WITH_GUI_YES /*** @@ -396,7 +425,7 @@ static void get_base_dirs() source directory is supposed to hold the most recent files, so try this first. */ -#if defined(WITH_EMBEDDED_SRC_PATH_YES) && !defined(SYS_MINGW) +#if defined(WITH_EMBEDDED_SRC_PATH_YES) && !defined(SYS_MINGW) && !defined(SYS_DARWIN) if(DirStat(SRCDIR)) { Closure->binDir = g_strdup(SRCDIR); Closure->docDir = g_strdup_printf("%s/documentation",SRCDIR); @@ -405,6 +434,29 @@ static void get_base_dirs() } #endif /* WITH_EMBEDDED_SRC_PATH_YES */ +#if defined(WITH_EMBEDDED_SRC_PATH_YES) && defined(SYS_DARWIN) + char *binPath = get_bin_path(); + Closure->binDir = g_strdup_printf("%s/../Resources",binPath); + Closure->docDir = g_strdup_printf("%s/../Resources/documentation",binPath); + free(binPath); + goto find_dotfile; +#endif + +// We may also be in an app bundle +#if defined(SYS_DARWIN) + // Obtain the path to the executable + const char *pathToExecutable = get_bin_path(); + + // Check if the executable is within an app bundle + if (isWithinAppBundle(pathToExecutable)) { + // Inside an app bundle, set directory paths accordingly + Closure->binDir = g_strdup_printf("%s/../Resources", pathToExecutable); + Closure->docDir = g_strdup_printf("%s/../Resources/documentation", pathToExecutable); + goto find_dotfile; + } + +#endif /* SYS_DARWIN */ + /*** Otherwise try the installation directory. On Unices this is a hardcoded directory. */ diff --git a/src/scsi-darwin.c b/src/scsi-darwin.c new file mode 100644 index 0000000..a4ca243 --- /dev/null +++ b/src/scsi-darwin.c @@ -0,0 +1,378 @@ +/* dvdisaster: Additional error correction for optical media. + * Copyright (C) 2004-2011 Carsten Gnoerlich. + * + * Email: carsten@dvdisaster.org -or- cgnoerlich@fsfe.org + * Project homepage: http://www.dvdisaster.org + * + * This file is part of dvdisaster. + * + * dvdisaster is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * dvdisaster is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with dvdisaster. If not, see . + */ + +/* + * Darwin support by Julian Einwag . + * This is still an early version. + */ + +#include "dvdisaster.h" + +#include "scsi-layer.h" +#include "udf.h" + +#ifdef SYS_DARWIN +#include +#include +#include +#include +#include +#include +#include + + +#include + +/* + * Unmount media before trying to access them. + * Added by Bernd Heller, + */ + +static void unmountDVD(io_object_t scsiDevice) +{ + CFStringRef bsdName = NULL; + + bsdName = (CFStringRef) IORegistryEntrySearchCFProperty(scsiDevice, + kIOServicePlane, + CFSTR(kIOBSDNameKey), + kCFAllocatorDefault, + kIORegistryIterateRecursively); + if (bsdName != NULL) { + // unmount all partitions + char cmd[4096]; + char bsdNameStr[100]; + CFStringGetCString(bsdName, bsdNameStr, sizeof(bsdNameStr), kCFStringEncodingUTF8); + + sprintf(cmd, "/usr/sbin/diskutil unmountDisk /dev/%s", bsdNameStr); + system(cmd); + + CFRelease(bsdName); + } else { + // no media to unmount + return; + } +} + +char *getProductName(io_object_t device) +{ + CFDictionaryRef devCharacteristics; + CFStringRef nameRef; + CFIndex length; + char *prodName; + + devCharacteristics = IORegistryEntryCreateCFProperty(device, CFSTR(kIOPropertyDeviceCharacteristicsKey), kCFAllocatorDefault, 0); + + if (CFDictionaryGetValueIfPresent(devCharacteristics, CFSTR("Product Name"), (const void **) &nameRef)) { + length = CFStringGetLength(nameRef)+1; + prodName = malloc(length); + CFStringGetCString(nameRef, prodName, length, 0); + CFRelease(nameRef); + return prodName; + } else + return NULL; +} + +io_iterator_t getDVDIterator(char* ioClass) +{ + io_iterator_t scsiObjectIterator = (io_iterator_t) NULL; + CFMutableDictionaryRef matchingDict = NULL; + IOReturn ioReturnValue = kIOReturnSuccess; + + matchingDict = IOServiceMatching(ioClass); + if (matchingDict == (CFMutableDictionaryRef) NULL) { + return (io_iterator_t) NULL; + } + ioReturnValue = IOServiceGetMatchingServices(kIOMasterPortDefault, matchingDict, &scsiObjectIterator); + if (scsiObjectIterator == (io_iterator_t) NULL || (ioReturnValue != kIOReturnSuccess)) { + return (io_iterator_t) NULL; + } + return scsiObjectIterator; + +} + +IOCFPlugInInterface **getPlugInInterface(io_object_t scsiDevice) +{ + IOReturn ioReturnValue; + SInt32 score = 0; + IOCFPlugInInterface **plugInInterface = NULL; + + ioReturnValue = IOCreatePlugInInterfaceForService(scsiDevice, kIOMMCDeviceUserClientTypeID, kIOCFPlugInInterfaceID,&plugInInterface, &score); + if (ioReturnValue != kIOReturnSuccess) { + return NULL; + } + return plugInInterface; +} + +MMCDeviceInterface** getMMCInterface(IOCFPlugInInterface** plugInInterface) +{ + MMCDeviceInterface **mmcDeviceInterface = NULL; + HRESULT pluginResult; + pluginResult = (*plugInInterface)->QueryInterface(plugInInterface, + CFUUIDGetUUIDBytes(kIOMMCDeviceInterfaceID), + (LPVOID)&mmcDeviceInterface); + if (pluginResult != KERN_SUCCESS) { + return NULL; + } + return mmcDeviceInterface; +} + +char *DefaultDevice() +{ + int i; + io_iterator_t scsiObjectIterator = (io_iterator_t) NULL; + io_object_t scsiDevice; + char *deviceName, *prodName; + + /* As a convenience, add the simulated drive first. */ + + InitSimulatedCD(); + + /* Now probe the physical drives. */ + + scsiObjectIterator = getDVDIterator("IOBDServices"); + for (i = 1; (scsiDevice = (io_object_t) IOIteratorNext(scsiObjectIterator)) != (io_object_t) NULL; i++) { + deviceName = g_malloc0(80); + sprintf(deviceName,"IOBDServices/%d",i); + + prodName = getProductName(scsiDevice); + g_ptr_array_add(Closure->deviceNodes, g_strdup(deviceName)); + g_ptr_array_add(Closure->deviceNames, g_strdup(prodName)); + g_free(deviceName); + } + IOObjectRelease(scsiObjectIterator); + scsiObjectIterator = getDVDIterator("IODVDServices"); + for (i = 1; (scsiDevice = (io_object_t) IOIteratorNext(scsiObjectIterator)) != (io_object_t) NULL; i++) { + deviceName = g_malloc0(80); + sprintf(deviceName,"IODVDServices/%d",i); + + prodName = getProductName(scsiDevice); + g_ptr_array_add(Closure->deviceNodes, g_strdup(deviceName)); + g_ptr_array_add(Closure->deviceNames, g_strdup(prodName)); + g_free(deviceName); + } + IOObjectRelease(scsiObjectIterator); + scsiObjectIterator = getDVDIterator("IOCompactDiscServices"); + for (i = 1; (scsiDevice = IOIteratorNext(scsiObjectIterator)) != (io_object_t) NULL; i++) { + deviceName = g_malloc0(80); + sprintf(deviceName,"IOCompactDiscServices/%d",i); + g_ptr_array_add(Closure->deviceNodes, g_strdup(deviceName)); + g_ptr_array_add(Closure->deviceNames, g_strdup(deviceName)); + g_free(deviceName); + } + if(Closure->deviceNodes->len) + return g_strdup(g_ptr_array_index(Closure->deviceNodes, 0)); + else { PrintLog(_("No CD/DVD drives found.")); + return NULL; + } + +} + +DeviceHandle* OpenDevice(char *device) +{ + DeviceHandle *dh; + io_iterator_t scsiObjectIterator; + io_object_t scsiDevice; + IOReturn ioReturnValue = kIOReturnSuccess; + int numericalId = 1, i; + char *realdevice = NULL, *tmp; + + /* use a naming scheme identical to cdrtools */ + realdevice = tmp = strdup(device); + tmp = strchr(tmp, '/'); + if (tmp != NULL) { + *tmp++ = '\0'; + numericalId = atoi(tmp); + } + dh = g_malloc0(sizeof(DeviceHandle)); + dh->senseSize = sizeof(SCSI_Sense_Data); + + if(!strcmp(device, "sim-cd")) + { if(!Closure->simulateCD) /* can happen via resource file / last-device */ + { g_free(dh); + return NULL; + } + + dh->simImage = LargeOpen(Closure->simulateCD, O_RDONLY, IMG_PERMS); + if(!dh->simImage) + { g_free(dh); + + Stop(_("Could not open %s: %s"), Closure->simulateCD, strerror(errno)); + return NULL; + } + + dh->device = g_strdup(device); + return dh; + } + + scsiObjectIterator = getDVDIterator(realdevice); + if (scsiObjectIterator == (io_iterator_t) NULL) { + g_free(dh); + Stop(_("Could not open %s (%s)."), device, realdevice); + return NULL; + } + /* look up handle for the selected device */ + for (i = 1; (scsiDevice = IOIteratorNext(scsiObjectIterator)) != (io_object_t) NULL; i++) { + if (i == numericalId) { + break; + } + } + + unmountDVD(scsiDevice); + + dh->plugInInterface = getPlugInInterface(scsiDevice); + if (dh->plugInInterface == NULL) { + g_free(dh); + Stop("Could not get PlugInInterface."); + return NULL; + } + dh->mmcDeviceInterface = getMMCInterface(dh->plugInInterface); + if (dh->mmcDeviceInterface == NULL) { + g_free(dh); + Stop("Could not get MMCDeviceInterface."); + return NULL; + } + (dh->scsiTaskDeviceInterface) = (*dh->mmcDeviceInterface)->GetSCSITaskDeviceInterface(dh->mmcDeviceInterface); + if (dh->scsiTaskDeviceInterface == NULL) { + g_free(dh); + Stop("Could not get SCSITaskDeviceInterface."); + return NULL; + } + ioReturnValue = (*dh->scsiTaskDeviceInterface)->ObtainExclusiveAccess(dh->scsiTaskDeviceInterface); + if (ioReturnValue != kIOReturnSuccess) { + Stop("Couldn't obtain exclusive access to drive."); + return NULL; + } + dh->taskInterface = (*dh->scsiTaskDeviceInterface)->CreateSCSITask(dh->scsiTaskDeviceInterface); + if (dh->taskInterface == NULL) { + Stop("Could not create taskInterface."); + return NULL; + } + (*dh->taskInterface)->SetTimeoutDuration(dh->taskInterface, 120*1000); + dh->device = g_strdup(device); + return dh; +} + +void CloseDevice(DeviceHandle *dh) +{ + if(dh->simImage) + LargeClose(dh->simImage); + + if(dh->canReadDefective) + SetRawMode(dh, MODE_PAGE_UNSET); + + if(dh->rawBuffer) + FreeRawBuffer(dh->rawBuffer); + + if (dh->taskInterface) { + (*dh->taskInterface)->Release(dh->taskInterface); + } + if (dh->scsiTaskDeviceInterface) { + (*dh->scsiTaskDeviceInterface)->ReleaseExclusiveAccess(dh->scsiTaskDeviceInterface); + (*dh->scsiTaskDeviceInterface)->Release(dh->scsiTaskDeviceInterface); + } + if (dh->mmcDeviceInterface) { + (*dh->mmcDeviceInterface)->Release(dh->mmcDeviceInterface); + } + if(dh->plugInInterface) { + IODestroyPlugInInterface(dh->plugInInterface); + } + if(dh->range) { + g_free(dh->range); + } + + if(dh->typeDescr) + g_free(dh->typeDescr); + if(dh->mediumDescr) + g_free(dh->mediumDescr); + if(dh->defects) + FreeBitmap(dh->defects); + + g_free(dh); + +} + +int SendPacket(DeviceHandle *dh, unsigned char *cmd, int cdb_size, unsigned char *buf, int size, Sense *sense, int data_mode) +{ + u_int32_t flags = 0; + SCSITaskInterface **taskInterface; + SCSITaskStatus taskStatus = kSCSITaskStatus_No_Status; + IOReturn ioReturnValue; + + if(dh->simImage) + return SimulateSendPacket(dh, cmd, cdb_size, buf, size, sense, data_mode); + + switch(data_mode) { + case DATA_READ: + flags = kSCSIDataTransfer_FromTargetToInitiator; + break; + case DATA_WRITE: + flags = kSCSIDataTransfer_FromInitiatorToTarget; + break; + case DATA_NONE: + flags = kSCSIDataTransfer_NoDataTransfer; + break; + default: + Stop("illegal data_mode: %d",data_mode); + } + + taskInterface = dh->taskInterface; + if (flags == kSCSIDataTransfer_FromTargetToInitiator || flags == kSCSIDataTransfer_FromInitiatorToTarget) { + dh->range = (IOVirtualRange *) g_malloc(sizeof(IOVirtualRange)); + dh->range->address = (IOVirtualAddress) buf; + dh->range->length = size; + } + ioReturnValue = (*taskInterface)->SetCommandDescriptorBlock(taskInterface, cmd, cdb_size); + if (ioReturnValue != kIOReturnSuccess) { + Stop("Couldn't set command descriptor block."); + } + if (flags == kSCSIDataTransfer_FromTargetToInitiator || flags == kSCSIDataTransfer_FromInitiatorToTarget) { + ioReturnValue = (*taskInterface)->SetScatterGatherEntries(taskInterface, dh->range, 1, size, flags); + if (ioReturnValue != kIOReturnSuccess) { + Stop("Couldn't set scatter-gather."); + } + } + + // Set the timeout in the task + ioReturnValue = ( *taskInterface )->SetTimeoutDuration ( taskInterface, 5000 ); + if ( ioReturnValue != kIOReturnSuccess ) { + Stop("Operation timed out.");; + } + + + ioReturnValue = (*taskInterface)->ExecuteTaskSync(taskInterface, (SCSI_Sense_Data*) sense, &taskStatus, NULL); + if (ioReturnValue != kIOReturnSuccess) { + return -1; + } + + if (taskStatus == kSCSITaskStatus_DeliveryFailure && cmd[0] == 0x00) { + return 0; + } + + if (taskStatus != kSCSITaskStatus_GOOD) { + return -1; + } + + return 0; + +} + +#endif diff --git a/src/scsi-layer.h b/src/scsi-layer.h index 5703a37..2df78a7 100644 --- a/src/scsi-layer.h +++ b/src/scsi-layer.h @@ -37,6 +37,20 @@ #include #endif +#ifdef SYS_DARWIN +#define REAL_VERSION VERSION +#undef VERSION +#include +#include +#include +#include +#include +#include +#include +#include +#define VERSION REAL_VERSION +#endif + /*** *** Global settings ***/ @@ -113,6 +127,12 @@ typedef struct _DeviceHandle union ccb *ccb; #elif defined(SYS_MINGW) HANDLE fd; /* Windows SPTI file handle for the device */ +#elif defined(SYS_DARWIN) + IOCFPlugInInterface **plugInInterface; + MMCDeviceInterface **mmcDeviceInterface; + SCSITaskDeviceInterface **scsiTaskDeviceInterface; + SCSITaskInterface **taskInterface; + IOVirtualRange *range; #endif /* diff --git a/src/show-manual.c b/src/show-manual.c index 2e86186..97125e3 100644 --- a/src/show-manual.c +++ b/src/show-manual.c @@ -30,7 +30,7 @@ #include "shellapi.h" #endif -#ifndef SYS_MINGW +#if !defined(SYS_MINGW) && !defined(SYS_DARWIN) static void send_errormsg(int fd, char *format, ...) { va_list argp; char *msg; @@ -63,7 +63,7 @@ void GuiShowURL(char *target) int hyperlink = 0; char *path; -#ifndef SYS_MINGW +#if !defined(SYS_MINGW) && !defined(SYS_DARWIN) pid_t pid; char *msg; int err_pipe[2]; /* child may send down err msgs to us here */ @@ -105,15 +105,29 @@ void GuiShowURL(char *target) /* Okay, Billy wins big time here ;-) */ ShellExecute(NULL, "open", path, NULL, NULL, SW_SHOWNORMAL); +#elif defined(SYS_DARWIN) + char command[256]; + snprintf(command, sizeof(command), "open \"%s\"", path); + system(command); #else /* fork xdg-open */ - result = pipe2(err_pipe, O_CLOEXEC); + result = pipe(err_pipe); if(result == -1) { GuiCreateMessage(_("Could not create pipe before fork"), GTK_MESSAGE_ERROR); return; } + result = fcntl(err_pipe[0], F_SETFL, O_CLOEXEC); + if(result == -1) + { GuiCreateMessage(_("Could not set pipe flags before fork"), GTK_MESSAGE_ERROR); + return; + } + result = fcntl(err_pipe[1], F_SETFL, O_CLOEXEC); + if(result == -1) + { GuiCreateMessage(_("Could not set pipe flags before fork"), GTK_MESSAGE_ERROR); + return; + } pid = fork(); if(pid == -1)