Bug 275143 - [NEW PORT] audio/atracdenc: ATRAC1, ATRAC3 compatible encoder with LGPL licence
Summary: [NEW PORT] audio/atracdenc: ATRAC1, ATRAC3 compatible encoder with LGPL licence
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Some People
Assignee: Daniel Engberg
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-11-16 22:15 UTC by dan.cherednik
Modified: 2023-11-24 17:41 UTC (History)
1 user (show)

See Also:


Attachments
shar attchment for new port (1.85 KB, text/plain)
2023-11-16 22:15 UTC, dan.cherednik
no flags Details
atracdenc shar. Fixed MASTER_SITES url (1.84 KB, text/plain)
2023-11-17 22:31 UTC, dan.cherednik
no flags Details
Use gtest, change MASTER_SITES priority (1.47 KB, patch)
2023-11-19 20:31 UTC, dan.cherednik
no flags Details | Diff
Patch for atracdenc (1.57 KB, patch)
2023-11-20 23:38 UTC, Daniel Engberg
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description dan.cherednik 2023-11-16 22:15:07 UTC
Created attachment 246364 [details]
shar attchment for new port

This is FreeBSD port for https://github.com/dcherednik/atracdenc project - LGPL implementation of ATRAC compatible encoder.

This software can be used to encode and than transfer audio files (by linux-minidisc) in to MD devices without sonic stage.

RealMedia format is also supported
Comment 1 Daniel Engberg freebsd_committer freebsd_triage 2023-11-16 23:48:47 UTC
Hi,

Some initial thoughts

Github URL returns 404, the cgit site generates a snapshot on the fly as far as I know so it would be great if you could create a release and upload a static release archive on GitHub (see also https://github.blog/2023-02-21-update-on-the-future-stability-of-source-code-archives-and-hashes/ ).

Do you think we can unbundle G(oogle)test and use the port instead?
https://www.freshports.org/devel/googletest/

Best regards,
Daniel
Comment 2 dan.cherednik 2023-11-17 22:28:33 UTC
(In reply to Daniel Engberg from comment #1)

Thank you for your prompt reply.

About cgit. You right, tgz was being generated on the fly. I've changed the url and put file as static on my mirror. I will add a new shar. Thank you.

About github. I've already add static release archive. The url is https://github.com/dcherednik/atracdenc/releases/download/0.1.0/atracdenc-0.1.0.tar.gz  and as far as i know MASTER_SITES= https://github.com/dcherednik/atracdenc/releases/download/${DISTVERSION}/ should handle it (it works in my environment). Please let me known if I missing something.

About gtest. So... I can add a patch in to this port to use library from the ports tree... But do we really want it? Other option is to add gtest dependencies just in to the main repository (and remove gtest from source code), but it will make development on platforms without packet managers a bit more complicated.
I can make an Issue and replace gtest with some lightweight header only library (FCTX for example) in the next release of atracdenc. Probably it is the best way for me.



Kind regards.
Comment 3 dan.cherednik 2023-11-17 22:31:10 UTC
Created attachment 246380 [details]
atracdenc shar. Fixed MASTER_SITES url
Comment 4 Daniel Engberg freebsd_committer freebsd_triage 2023-11-18 15:11:05 UTC
(In reply to dan.cherednik from comment #2)
Nitpick about MASTER_SITES but I think it's better to default to GitHub due to availability and performance and fallback to your site if it fails.

Regarding gtest, the general recommendation is to follow Porters Handbook (https://docs.freebsd.org/en/books/porters-handbook/book/#bundled-libs).

You seem to be the upstream author so perhaps make CMake look for an installed version of gtest and fallback to builtin variant if not found?

While shar files are acceptable please consider submitting patch files instead.
Comment 5 dan.cherednik 2023-11-19 20:31:01 UTC
Created attachment 246431 [details]
Use gtest, change MASTER_SITES priority

Ok. Please consider the following patch. I have changed MASTER_SITES order, removed gtest from upstream, added devel/googletest instead.

PS: Are there any recommendations how to generate diff to make it easy to apply, for example use git format patch, or just diff between two folders is fine? 

Best regards.
Comment 6 Daniel Engberg freebsd_committer freebsd_triage 2023-11-20 23:38:59 UTC
Created attachment 246454 [details]
Patch for atracdenc

Remove menu option and a few other tweaks
Comment 7 Daniel Engberg freebsd_committer freebsd_triage 2023-11-20 23:53:22 UTC
(In reply to dan.cherednik from comment #5)

Hi,

If you supply one without any metadata (git diff) that's fine but you can also use git format.

Please make sure it applies cleanly and don't depend on any previous patches.

Best regards,
Daniel
Comment 8 dan.cherednik 2023-11-22 22:43:24 UTC
(In reply to Daniel Engberg from comment #6)
It works!
Comment 9 commit-hook freebsd_committer freebsd_triage 2023-11-24 17:39:11 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=5ee7d6a649a175c22e5321e9b0587ee2c0744a12

commit 5ee7d6a649a175c22e5321e9b0587ee2c0744a12
Author:     Daniil Cherednik <dan.cherednik@gmail.com>
AuthorDate: 2023-11-24 17:36:43 +0000
Commit:     Daniel Engberg <diizzy@FreeBSD.org>
CommitDate: 2023-11-24 17:36:51 +0000

    audio/atracdenc: New port: ATRAC1 decoder/encoder, ATRAC3 encoder

    Audio encoder that supports ATRAC1 and ATRAC3 formats, can decode ATRAC1
    and supports following containers: AEA, OMA, RIFF, RealMedia.

    WWW: https://github.com/dcherednik/atracdenc/

    PR:             275143

 audio/Makefile                  |  1 +
 audio/atracdenc/Makefile (new)  | 29 +++++++++++++++++++++++++++++
 audio/atracdenc/distinfo (new)  |  3 +++
 audio/atracdenc/pkg-descr (new) |  2 ++
 4 files changed, 35 insertions(+)
Comment 10 Daniel Engberg freebsd_committer freebsd_triage 2023-11-24 17:41:30 UTC
Committed, thanks!