Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

new packages: shotcut, mlt and their deps #20353

Merged
merged 2 commits into from
Sep 23, 2024
Merged

Conversation

knyipab
Copy link
Contributor

@knyipab knyipab commented May 29, 2024

Draft PR. currently the app mostly works well but cannot output video results, perhaps there are problems with QProcess, see #20354 . [fixed]

Other things to note:

x11-packages/shotcut/build.sh Outdated Show resolved Hide resolved
@knyipab
Copy link
Contributor Author

knyipab commented May 31, 2024

This package will be ready and I will force-push it once #20352 and #20374 are merged.
The sound effects should work with sdl2 package. jack-dummy is more for runtime purpose (won't produce sound) otherwise need to patch the code. rtaudio is a longer run TODO item when pipewire is in a good state. opencv is nice-to-have item if someone find a fix but that shouldn't matter much.

@TomJo2000
Copy link
Member

This package will be ready and I will force-push it once #20352 and #20374 are merged. The sound effects should work with sdl2 package. jack-dummy is more for runtime purpose (won't produce sound) otherwise need to patch the code. rtaudio is a longer run TODO item when pipewire is in a good state. opencv is nice-to-have item if someone find a fix but that shouldn't matter much.

Please make sure to add

termux_step_pre_configure(){
	CXXFLAGS+=' -Wno-c++11-narrowing'
}

to make sure the 32 bit builds succeed.

@knyipab
Copy link
Contributor Author

knyipab commented May 31, 2024

Thanks and will do when movit is available

@TomJo2000
Copy link
Member

In that case I'm gonna go ahead and merge movit.

@knyipab knyipab marked this pull request as ready for review June 1, 2024 01:37
@knyipab
Copy link
Contributor Author

knyipab commented Jun 1, 2024

Tested on my aarch64 phone. Import playlist, track editor, preview, some basic filters (rotate, opacity), export work.

Ready to be merged. See if you are fine with the way I patch the source code.

@truboxl
Copy link
Contributor

truboxl commented Jun 1, 2024

Please change all the .patch files that hardcoded with /data/data/com.termux/files/usr to @TERMUX_PREFIX@

@knyipab
Copy link
Contributor Author

knyipab commented Jun 1, 2024

fixed. thanks

@Biswa96
Copy link
Member

Biswa96 commented Jun 1, 2024

x11-packages/mlt/0001-cmake-mlt-undefined-version.patch and x11-packages/mlt/0002-cmake-mlt++-undefined-version.patch are probably not required. The issue can be fixed with LDFLAGS+=" -Wl,--undefined-version" (see packages/zlib/build.sh).

@knyipab
Copy link
Contributor Author

knyipab commented Jun 1, 2024

Thanks @Biswa96 . You are right and force-pushed.

@truboxl
Copy link
Contributor

truboxl commented Jun 2, 2024

Please change TERMUX_PKG_MAINTAINER field

@knyipab
Copy link
Contributor Author

knyipab commented Jun 2, 2024

oh right, fixed.

x11-packages/mlt/build.sh Outdated Show resolved Hide resolved
@knyipab
Copy link
Contributor Author

knyipab commented Jun 25, 2024

@truboxl refactored: addressed your comments, used the jack merged in #20544, removed TODO, and removed the libjack.so.0 patch.

@knyipab
Copy link
Contributor Author

knyipab commented Sep 19, 2024

Just realized that this PR should be ready but has not yet merged. Any chance merging to provide shotcut to Termux users? And then close #20021

@TomJo2000
Copy link
Member

TomJo2000 commented Sep 20, 2024

LGTM.
Gonna wait for the CI to run through before merging.

fixes #20021

x11-packages/mlt/build.sh Outdated Show resolved Hide resolved
x11-packages/shotcut/build.sh Outdated Show resolved Hide resolved
Copy link
Member

@TomJo2000 TomJo2000 left a comment

Choose a reason for hiding this comment

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

I went in and updated the build scripts.

I had to regenerate mlt/0004-fhs-path.patch, but that was just some line drift causing the 7.24.0 version of the patch to no longer apply.

@TomJo2000
Copy link
Member

Guess that's what I get for only testing against AArch64 locally.
We're having symbol issues with 32Bit again.

ld.lld: error: undefined symbol: Mlt::Producer::set_creation_time(long long)
>>> referenced by mltcontroller.cpp
>>>               src/CMakeFiles/shotcut.dir/mltcontroller.cpp.o:(Mlt::Controller::setupNewProducer(Mlt::Producer*) const)
>>> referenced by mltcontroller.cpp
>>>               src/CMakeFiles/shotcut.dir/mltcontroller.cpp.o:(Mlt::Controller::lockCreationTime(Mlt::Producer*) const)
>>> referenced by filedatedialog.cpp
>>>               src/CMakeFiles/shotcut.dir/dialogs/filedatedialog.cpp.o:(FileDateDialog::accept())
clang++: error: linker command failed with exit code 1 (use -v to see invocation)

@knyipab
Copy link
Contributor Author

knyipab commented Sep 22, 2024

Related to mltframework/shotcut#1580 and mltframework/mlt#1020.
TLDR: Someone suggested below patch and mlt dev said that only apply it conditionally for 32-bit build:

--- a/src/mlt++/mlt++.vers
+++ b/src/mlt++/mlt++.vers
@@ -541,6 +541,7 @@ MLTPP_6.14.0 {
       "Mlt::Playlist::reorder(int const*)";
       "Mlt::Transition::connect(Mlt::Service&, int, int)";
       "Mlt::Producer::set_creation_time(long)";
+      "Mlt::Producer::set_creation_time(long long)";
       "Mlt::Producer::get_creation_time()";
   };
 } MLTPP_6.10.0;

Honestly, I am not so sure how to make a conditional patch other than writing some sed shell script. Help is appreciated. Thanks.

@TomJo2000
Copy link
Member

Should be easy enough.
I'll do it in a bit.

@TomJo2000
Copy link
Member

util-linux has an example of a bit-ness depedent configure argument.

elif [ $TERMUX_ARCH_BITS = 32 ]; then
TERMUX_PKG_EXTRA_CONFIGURE_ARGS+=" --disable-year2038"
fi

We can use the same approach and just apply a *.diff patch instead.

@knyipab knyipab force-pushed the shotcut branch 2 times, most recently from e404c1d to d409b20 Compare September 22, 2024 15:43
@knyipab
Copy link
Contributor Author

knyipab commented Sep 23, 2024

EDITED:

Can't build even reverting to your version. Clueless and shouldn't relates to libicu cuz there was no update.

Previous incorrect comments.

There seems to be a bug in the build system handling qt6 cross tool. Can't build even reverting to your version.

Not many clues, I guess related to gst-plugins-gl-headers being installed during the build process for unknown reason and breaks other packages (it conflicts with mesa). Cuz I encountered weird problem recently in TUR's on device building.

@truboxl
Copy link
Contributor

truboxl commented Sep 23, 2024

The cross tools need to be rebuilt after the Ubuntu base image upgraded to 24.04.

@knyipab
Copy link
Contributor Author

knyipab commented Sep 23, 2024

Thanks a lot! Ready to be merged.

Copy link
Member

@TomJo2000 TomJo2000 left a comment

Choose a reason for hiding this comment

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

LGTM.
Thanks a lot for your contribution and working with us on it.

@TomJo2000 TomJo2000 merged commit 939ebcf into termux:master Sep 23, 2024
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants