Skip to content

Use ffmpeg version 6.0 #6

New issue

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

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

Already on GitHub? Sign in to your account

Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
87515ed
Update host for Windows binaries, closes #60
TheLastZombie Sep 12, 2020
a789f3b
upgrade deps & dev deps
derhuerst Sep 16, 2020
5597539
Travis CI: run install script manually 💚
derhuerst Nov 21, 2020
31a2508
download win32-x64 binary from gyan.dev
derhuerst Mar 5, 2021
01200fe
fix linux-{x64,ia32,arm,arm64} binary downloads 💚
derhuerst Mar 5, 2021
79c26e1
fix binary publishing 💚
derhuerst Nov 19, 2020
73d0920
add compressed binaries to GitHub release
derhuerst Nov 19, 2020
47bda66
install script: download gzipped binary ⚡️
derhuerst Nov 19, 2020
135837f
upgrade deps & dev deps
derhuerst Mar 17, 2021
1794103
use 4.3.2 binaries, 4.2.8
derhuerst Mar 17, 2021
47523ee
support FreeBSD x64
derhuerst Apr 1, 2021
251282a
minor tweaks; 4.3.0
derhuerst Apr 1, 2021
e974399
readme.md/package.json: mention @Thefrank's FreeBSD builds
derhuerst Apr 3, 2021
78dd999
support darwin-arm64
emyarod Apr 29, 2021
f09b4b5
build script: pull ffmpeg 4.4 binaries
derhuerst Apr 29, 2021
6433f61
Add win32-ia32 build for 4.4
codetheweb Jun 17, 2021
709c0f1
fix FreeBSD x64 binary download 💚
derhuerst Jun 19, 2021
b52c775
use 4.4 binaries; 4.4
derhuerst Jun 19, 2021
40655c5
fix: upgrade eslint from 7.22.0 to 7.30.0
snyk-bot Aug 1, 2021
36eda5d
Merge pull request #4 from eugeneware/master
cvanwinkle Dec 14, 2021
89889f0
Use ffmpeg version 6.0
Aug 29, 2023
50327a8
Fix readme
Aug 29, 2023
0be4e98
Fix readme
Aug 29, 2023
5a8a458
Merge branch 'add-ffprobe' into vyaas/bck-4139-transcription-stuck-ru…
srubin Sep 15, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
106 changes: 98 additions & 8 deletions .github/workflows/release-binaries.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,22 @@ jobs:
- name: Download Binaries
run: sh ./build/index.sh

- name: Compress Binaries
run: |
set -e
set -o pipefail
cat bin/darwin-x64 | gzip --best >bin/darwin-x64.gz
cat bin/darwin-arm64 | gzip --best >bin/darwin-arm64.gz
cat bin/freebsd-x64 | gzip --best >bin/freebsd-x64.gz
cat bin/linux-arm | gzip --best >bin/linux-arm.gz
cat bin/linux-arm64 | gzip --best >bin/linux-arm64.gz
cat bin/linux-ia32 | gzip --best >bin/linux-ia32.gz
cat bin/linux-x64 | gzip --best >bin/linux-x64.gz
cat bin/win32-ia32 | gzip --best >bin/win32-ia32.gz
cat bin/win32-x64 | gzip --best >bin/win32-x64.gz
ls -l bin
shell: bash

- name: Create Release
id: create_release
uses: actions/create-release@v1
Expand All @@ -40,6 +56,14 @@ jobs:
asset_path: bin/ffprobe-darwin-x64
asset_name: ffprobe-darwin-x64
asset_content_type: application/octet-stream
- uses: actions/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: bin/darwin-x64.gz
asset_name: darwin-x64.gz
asset_content_type: application/octet-stream

- uses: actions/[email protected]
env:
Expand All @@ -58,6 +82,42 @@ jobs:
asset_path: bin/ffmpeg-linux-arm
asset_name: ffmpeg-linux-arm
asset_content_type: application/octet-stream

- uses: actions/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: bin/ffmpeg-darwin-arm
asset_name: ffmpeg-darwin-arm
asset_content_type: application/octet-stream

- uses: actions/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: bin/ffprobe-darwin-arm
asset_name: ffprobe-darwin-arm
asset_content_type: application/octet-stream

- uses: actions/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: bin/darwin-arm64.gz
asset_name: darwin-arm64.gz
asset_content_type: application/octet-stream

- uses: actions/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: bin/darwin-arm64.README
asset_name: darwin-arm64.README
asset_content_type: text/plain

- uses: actions/[email protected]
env:
Expand All @@ -67,6 +127,14 @@ jobs:
asset_path: bin/ffprobe-linux-arm
asset_name: ffprobe-linux-arm
asset_content_type: application/octet-stream
- uses: actions/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: bin/ffmpeg-linux-arm.gz
asset_name: ffmpeg-linux-arm.gz
asset_content_type: application/octet-stream

- uses: actions/[email protected]
env:
Expand Down Expand Up @@ -103,6 +171,14 @@ jobs:
asset_path: bin/ffprobe-linux-arm64
asset_name: ffprobe-linux-arm64
asset_content_type: application/octet-stream
- uses: actions/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: bin/linux-arm64.gz
asset_name: linux-arm64.gz
asset_content_type: application/octet-stream

- uses: actions/[email protected]
env:
Expand Down Expand Up @@ -139,6 +215,14 @@ jobs:
asset_path: bin/ffprobe-linux-ia32
asset_name: ffprobe-linux-ia32
asset_content_type: application/octet-stream
- uses: actions/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: bin/linux-ia32.gz
asset_name: linux-ia32.gz
asset_content_type: application/octet-stream

- uses: actions/[email protected]
env:
Expand Down Expand Up @@ -175,6 +259,14 @@ jobs:
asset_path: bin/ffprobe-linux-x64
asset_name: ffprobe-linux-x64
asset_content_type: application/octet-stream
- uses: actions/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: bin/linux-x64.gz
asset_name: linux-x64.gz
asset_content_type: application/octet-stream

- uses: actions/[email protected]
env:
Expand Down Expand Up @@ -211,15 +303,14 @@ jobs:
asset_path: bin/ffprobe-win32-ia32
asset_name: ffprobe-win32-ia32
asset_content_type: application/octet-stream

- uses: actions/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: bin/win32-ia32.README
asset_name: win32-ia32.README
asset_content_type: text/plain
asset_path: bin/win32-ia32.gz
asset_name: win32-ia32.gz
asset_content_type: application/octet-stream

- uses: actions/[email protected]
env:
Expand Down Expand Up @@ -247,15 +338,14 @@ jobs:
asset_path: bin/ffprobe-win32-x64
asset_name: ffprobe-win32-x64
asset_content_type: application/octet-stream

- uses: actions/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: bin/win32-x64.README
asset_name: win32-x64.README
asset_content_type: text/plain
asset_path: bin/win32-x64.gz
asset_name: win32-x64.gz
asset_content_type: application/octet-stream

- uses: actions/[email protected]
env:
Expand Down
1 change: 1 addition & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ addons:
- unzip
- tar
script:
- npm run install
- npm test
- 'file=$(npm pack -s) && file=$(realpath $file)'
- 'cd $(mktemp -d) && npm init -y'
Expand Down
15 changes: 8 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ Fork of [ffmpeg-static](https://github.com/eugeneware/ffmpeg-static) that includ

## Info

**[ffmpeg](https://ffmpeg.org) static binaries for Mac OSX and Linux and Windows.**
**[ffmpeg](https://ffmpeg.org) static binaries for Mac OSX, Linux, Windows and FreeBSD.**

Supports macOS (64-bit), Linux (32 and 64-bit, armhf, arm64) and Windows (32 and 64-bit). [The ffmpeg version currently used is `4.3.1`.](https://github.com/descriptinc/ffmpeg-ffprobe-static/releases/tag/b4.3.1)
Supports macOS (64-bit and arm64), Linux (32 and 64-bit, armhf, arm64) and Windows (32 and 64-bit). [The ffmpeg version currently used is `6.0`.](https://github.com/descriptinc/ffmpeg-ffprobe-static/releases/tag/b6.0)

*Note:* The version of `ffmpeg-ffprobe-static` follows [SemVer](http://semver.org). When releasing new versions, **we do *not* consider breaking changes in `ffmpeg` itself**, but only the JS interface (see below). To stop `ffmpeg-ffprobe-static` from breaking your code by getting updated, [lock the version down](https://docs.npmjs.com/files/package.json#dependencies) or use a [lockfile](https://docs.npmjs.com/files/package-lock.json).

Expand All @@ -22,11 +22,10 @@ This module is installed via npm:
$ npm install ffmpeg-ffprobe-static
```

*Note:* During installation, it will download the appropriate `ffmpeg`/`ffprobe` binary from the [`b4.3.1` GitHub release](https://github.com/descriptinc/ffmpeg-ffprobe-static/releases/tag/b4.3.1). Use and distribution of the binary releases of FFmpeg are covered by their respective license.
*Note:* During installation, it will download the appropriate `ffmpeg` binary from the [`b6.0` GitHub release](https://github.com/descriptinc/ffmpeg-ffprobe-static/releases/tag/b6.0). Use and distribution of the binary releases of FFmpeg are covered by their respective license.

Alternatively, it will fetch binaries from `FFMPEG_FFPROBE_STATIC_BASE_URL` if set as an environment variable. The default base URL is https://github.com/descriptinc/ffmpeg-ffprobe-static/releases/download/. The install script will fetch binaries from `BASE_URL/binary-release-tag` (the `binary-release-tag` is set in package.json and can customized by setting `FFMPEG_BINARY_RELEASE`).


### Electron & other cross-platform packaging tools

Because `ffmpeg-ffprobe-static` will download a binary specific to the OS/platform, you need to purge `node_modules` before (re-)packaging your app *for a different OS/platform* ([read more in #35](https://github.com/eugeneware/ffmpeg-static/issues/35#issuecomment-630225392)).
Expand All @@ -50,17 +49,19 @@ Check the [example script](example.js) for a more thorough example.

[The build script](build/index.sh) downloads binaries from these locations:

- [Windows builds](https://ffmpeg.zeranoe.com/builds/win64/static/)
- [Windows x64 builds](https://github.com/ShareX/FFmpeg/)
- [Windows x86 builds](https://github.com/sudo-nautilus/FFmpeg-Builds-Win32/)
- [Linux builds](https://johnvansickle.com/ffmpeg/)
- [macOS builds](https://evermeet.cx/pub/ffmpeg/)
- macOS builds [for Intel](https://evermeet.cx/pub/ffmpeg/) / [for ARM (Apple Silicon)](https://osxexperts.net/)
- [FreeBSD builds](https://github.com/Thefrank/ffmpeg-static-freebsd/releases)

The build script extracts build information and (when possible) the license file from the downloaded package or the distribution server. Please consult the individual build's project site for exact source versions, which you can locate based on the version information included in the README file.

## Show your support

This npm package includes statically linked binaries that are produced by the following individuals. Please consider supporting and donating to them who have been providing quality binary builds for many years:

- **Windows builds**: [Kyle Schwarz](https://ffmpeg.zeranoe.com/builds/)
- **Windows builds**: [Jaex](https://getsharex.com/donate/)
- **Linux builds**: [John Van Sickle](https://www.johnvansickle.com/ffmpeg/)
- **macOS builds**: [Helmut K. C. Tessarek](https://evermeet.cx/ffmpeg/#donations)

Expand Down
68 changes: 43 additions & 25 deletions build/index.sh
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@ echo using tar executable: $tar_exec $tar_options

cd $(dirname $0)

mkdir -p ../bin

download () {
if [ -e $2 ]; then
echo " already downloaded: $2"
Expand All @@ -26,58 +28,60 @@ download () {
}

echo 'windows x64'
download 'https://ffmpeg.zeranoe.com/builds/win64/static/ffmpeg-4.3-win64-static.zip' win32-x64.zip
echo ' downloading from gyan.dev'
download 'https://www.gyan.dev/ffmpeg/builds/ffmpeg-release-essentials.7z' win32-x64.7z
echo ' extracting'
unzip -o -d ../bin -j win32-x64.zip '**/ffmpeg.exe' '**/ffprobe.exe'
mv ../bin/ffmpeg.exe ../bin/ffmpeg-win32-x64
mv ../bin/ffprobe.exe ../bin/ffprobe-win32-x64
unzip -p win32-x64.zip '**/LICENSE.txt' > ../bin/win32-x64.LICENSE
unzip -p win32-x64.zip '**/README.txt' > ../bin/win32-x64.README
tmpdir=$(mktemp -d)
7zr e -y -bd -o"$tmpdir" win32-x64.7z >/dev/null
mv "$tmpdir/ffmpeg.exe" ../bin/win32-x64
mv "$tmpdir/ffprobe.exe" ../bin/win32-x64
mv "$tmpdir/LICENSE" ../bin/win32-x64.LICENSE
mv "$tmpdir/README.txt" ../bin/win32-x64.README

echo 'windows ia32'
download 'https://ffmpeg.zeranoe.com/builds/win32/static/ffmpeg-4.3-win32-static.zip' win32-ia32.zip
echo ' downloading from github.com'
download 'https://github.com/sudo-nautilus/FFmpeg-Builds-Win32/releases/download/autobuild-2021-06-17-12-48/ffmpeg-n4.4-19-g8d172d9409-win32-gpl-4.4.zip' win32-ia32.zip
echo ' extracting'
unzip -o -d ../bin -j win32-ia32.zip '**/ffmpeg.exe' '**/ffprobe.exe'
mv ../bin/ffmpeg.exe ../bin/ffmpeg-win32-ia32
mv ../bin/ffprobe.exe ../bin/ffprobe-win32-ia32
unzip -p win32-ia32.zip '**/LICENSE.txt' > ../bin/win32-ia32.LICENSE
unzip -p win32-ia32.zip '**/README.txt' > ../bin/win32-ia32.README
unzip -o -d ../bin -j win32-ia32.zip '*/bin/ffmpeg.exe' '*/bin/ffprobe.exe'
mv ../bin/ffmpeg.exe ../bin/win32-ia32
mv ../bin/ffprobe.exe ../bin/win32-ia32
curl -s -L 'https://github.com/raw/sudo-nautilus/FFmpeg-Builds-Win32/master/LICENSE' -o ../bin/win32-ia32.LICENSE

echo 'linux x64'
download 'https://johnvansickle.com/ffmpeg/releases/ffmpeg-release-amd64-static.tar.xz' linux-x64.tar.xz
echo ' extracting'
$tar_exec $tar_options -x -C ../bin --strip-components 1 -f linux-x64.tar.xz '*/ffmpeg' '*/ffprobe'
xzcat linux-x64.tar.xz | $tar_exec -x -C ../bin --strip-components 1 --wildcards '*/ffmpeg' '*/ffprobe'
mv ../bin/ffmpeg ../bin/ffmpeg-linux-x64
mv ../bin/ffprobe ../bin/ffprobe-linux-x64
$tar_exec $tar_options -x -f linux-x64.tar.xz -O '**/GPLv3.txt' > ../bin/linux-x64.LICENSE
$tar_exec $tar_options -x -f linux-x64.tar.xz -O '**/readme.txt' > ../bin/linux-x64.README
xzcat ffmpeg-linux-x64.tar.xz | $tar_exec -x --ignore-case --wildcards -O '**/GPLv3.txt' >../bin/linux-x64.LICENSE
xzcat ffmpeg-linux-x64.tar.xz | $tar_exec -x --ignore-case --wildcards -O '**/readme.txt' >../bin/linux-x64.README

echo 'linux ia32'
download 'https://johnvansickle.com/ffmpeg/releases/ffmpeg-release-i686-static.tar.xz' linux-ia32.tar.xz
echo ' extracting'
$tar_exec $tar_options -x -C ../bin --strip-components 1 -f linux-ia32.tar.xz '*/ffmpeg' '*/ffprobe'
xzcat linux-ia32.tar.xz | $tar_exec -x -C ../bin --strip-components 1 --wildcards '*/ffmpeg' '*/ffprobe'
mv ../bin/ffmpeg ../bin/ffmpeg-linux-ia32
mv ../bin/ffprobe ../bin/ffprobe-linux-ia32
$tar_exec $tar_options -x -f linux-ia32.tar.xz -O '**/GPLv3.txt' > ../bin/linux-ia32.LICENSE
$tar_exec $tar_options -x -f linux-ia32.tar.xz -O '**/readme.txt' > ../bin/linux-ia32.README
xzcat ffmpeg-linux-ia32.tar.xz | $tar_exec -x --ignore-case --wildcards -O '**/GPLv3.txt' >../bin/linux-ia32.LICENSE
xzcat ffmpeg-linux-ia32.tar.xz | $tar_exec -x --ignore-case --wildcards -O '**/readme.txt' >../bin/linux-ia32.README

echo 'linux arm'
download 'https://johnvansickle.com/ffmpeg/releases/ffmpeg-release-armhf-static.tar.xz' linux-arm.tar.xz
echo ' extracting'
$tar_exec $tar_options -x -C ../bin --strip-components 1 -f linux-arm.tar.xz '*/ffmpeg' '*/ffprobe'
xzcat linux-arm.tar.xz | $tar_exec -x -C ../bin --strip-components 1 --wildcards '*/ffmpeg' '*/ffprobe'
mv ../bin/ffmpeg ../bin/ffmpeg-linux-arm
mv ../bin/ffprobe ../bin/ffprobe-linux-arm
$tar_exec $tar_options -x -f linux-arm.tar.xz -O '**/GPLv3.txt' > ../bin/linux-arm.LICENSE
$tar_exec $tar_options -x -f linux-arm.tar.xz -O '**/readme.txt' > ../bin/linux-arm.README
xzcat ffmpeg-linux-arm.tar.xz | $tar_exec -x --ignore-case --wildcards -O '**/GPLv3.txt' >../bin/linux-arm.LICENSE
xzcat ffmpeg-linux-arm.tar.xz | $tar_exec -x --ignore-case --wildcards -O '**/readme.txt' >../bin/linux-arm.README

echo 'linux arm64'
download 'https://johnvansickle.com/ffmpeg/releases/ffmpeg-release-arm64-static.tar.xz' linux-arm64.tar.xz
echo ' extracting'
$tar_exec $tar_options -x -C ../bin --strip-components 1 -f linux-arm64.tar.xz '*/ffmpeg' '*/ffprobe'
xzcat linux-arm64.tar.xz | $tar_exec -x -C ../bin --strip-components 1 --wildcards '*/ffmpeg' '*/ffprobe'
mv ../bin/ffmpeg ../bin/ffmpeg-linux-arm64
mv ../bin/ffprobe ../bin/ffprobe-linux-arm64
$tar_exec $tar_options -x -f linux-arm64.tar.xz -O '**/GPLv3.txt' > ../bin/linux-arm64.LICENSE
$tar_exec $tar_options -x -f linux-arm64.tar.xz -O '**/readme.txt' > ../bin/linux-arm64.README
xzcat ffmpeg-linux-arm64.tar.xz | $tar_exec -x --ignore-case --wildcards -O '**/GPLv3.txt' >../bin/linux-arm64.LICENSE
xzcat ffmpeg-linux-arm64.tar.xz | $tar_exec -x --ignore-case --wildcards -O '**/readme.txt' >../bin/linux-arm64.README

echo 'darwin x64'
download 'https://evermeet.cx/ffmpeg/getrelease/ffmpeg/zip' ffmpeg-darwin-x64.zip
Expand All @@ -89,4 +93,18 @@ download 'https://evermeet.cx/ffmpeg/getrelease/ffprobe/zip' ffprobe-darwin-x64.
echo ' extracting'
unzip -o -d ../bin -j ffprobe-darwin-x64.zip ffprobe
mv ../bin/ffprobe ../bin/ffprobe-darwin-x64
curl -s -L 'https://evermeet.cx/ffmpeg/info/ffmpeg/release' | jq --tab '.' >../bin/darwin-x64.README
curl -s -L 'https://git.ffmpeg.org/gitweb/ffmpeg.git/blob_plain/HEAD:/LICENSE.md' -o ../bin/darwin-x64.LICENSE

echo 'darwin arm64'
echo ' downloading from osxexperts.net'
download 'https://www.osxexperts.net/ffmpeg44arm.zip' darwin-arm64.zip
echo ' extracting'
unzip -o -d ../bin -j darwin-arm64.zip ffmpeg
mv ../bin/ffmpeg ../bin/darwin-arm64
curl -s -L 'https://git.ffmpeg.org/gitweb/ffmpeg.git/blob_plain/HEAD:/LICENSE.md' -o ../bin/darwin-arm64.LICENSE
curl -s -L 'https://git.ffmpeg.org/gitweb/ffmpeg.git/blob_plain/HEAD:/README.md' -o ../bin/darwin-arm64.README

echo 'freebsd x64'
echo ' downloading from github.com/Thefrank/ffmpeg-static-freebsd'
download 'https://github.com/Thefrank/ffmpeg-static-freebsd/releases/download/v6.0/ffmpeg' ../bin/freebsd-x64
chmod +x ../bin/freebsd-x64
4 changes: 2 additions & 2 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ function getPath(name) {
const os = require('os')
const path = require('path')

const binaries = Object.assign(Object.create(null), {
darwin: ['x64'],
var binaries = Object.assign(Object.create(null), {
darwin: ['x64', 'arm64'],
linux: ['x64', 'ia32', 'arm64', 'arm'],
win32: ['x64', 'ia32']
})
Expand Down
Loading