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

Package SynoCLI-file #3598

Merged
merged 5 commits into from
Sep 17, 2019
Merged

Package SynoCLI-file #3598

merged 5 commits into from
Sep 17, 2019

Conversation

m4tt075
Copy link
Contributor

@m4tt075 m4tt075 commented Jan 26, 2019

Motivation: Provide supplementary package of file management tools for the Synology Command Line Interface, i.e.

  • less (credits to alt219 for initial PR)
  • tree (credits to MrSpoocy for initial PR)
  • jdupes (credits to jbruchon for initial PR)
  • rhash (credits to fredrike for initial PR)
  • mc
  • nano
  • ncdu

Linked issues: #3250, and reference contained therein, i.e. #2075, #2818, #3242, #2257, #3030, #2823 #2944

Checklist

  • Build rule all-supported completed successfully
  • Package upgrade completed successfully
  • New installation of package completed successfully

@m4tt075 m4tt075 force-pushed the synocli-files branch 2 times, most recently from 3d9251c to ae55955 Compare January 27, 2019 11:14
@m4tt075 m4tt075 requested a review from ymartin59 January 27, 2019 11:14
@m4tt075 m4tt075 self-assigned this Jan 27, 2019
@m4tt075 m4tt075 force-pushed the synocli-files branch 2 times, most recently from 36be8e8 to b0ebacc Compare January 28, 2019 22:14
@m4tt075
Copy link
Contributor Author

m4tt075 commented Jan 28, 2019

rename has been added and tested. Should work.
rhash has issues. Need to inquire further. For another day...

@m4tt075
Copy link
Contributor Author

m4tt075 commented Jan 30, 2019

@ymartin59 I think I've fixed rhash. I somehow could not get it to link with its own shared library. Linking statically, it works.

I'd like to pick your brain on some design questions with this package:

  1. We could include nano in this package and remove its spk: Yes or no?
  2. We could include mc in this package and remove its spk: Yes or no?
  3. We could include synogear install in service-setup.sh. With that, those commands would automatically be available to users. That would be nice, as the vast majority of users won't know about it. However, those commands are not only related to synocli-files, but -net and others as well. What do you think?
  4. Lastly, yes, I've made rename work, but I sympathize with @MatthiasLohr 's comment on synocli-net: We introduce the perl dependency and overhead for the package "just" for that. Really not sure this is worthwhile: Keep or remove again?

Any other suggestions or comments more than welcome, too.

@ymartin59
Copy link
Contributor

@m4tt075 You have same questions than me... Here are my proposals:

  1. Include nano in synocli-file
  2. Include mc in synocli-file
  3. That is not so easy, command will install an additional package and most tools there require to switch as root... I consider it is for "really advanced" users. We will see later
  4. I would like to avoid Perl dependency here. Either we find a relevant place where to include "rename" (a package already requiring Perl - mosh?) or create a dedicated package for it

@ymartin59
Copy link
Contributor

@m4tt075 Here again, some changes in configure will be required before merging after #3595 is ready.

@m4tt075
Copy link
Contributor Author

m4tt075 commented Feb 10, 2019

@ymartin59 I've integrated ncdu, as requested. I still need to factor in your framework changes. But I've also encountered another issue, I'd like to ask your opinion on:

  • The less package (and others) depended on ncursesw.
  • The nano package depended on ncurses.
  • The way the ncurses(w) packages are designed, only the first ncurses(w) cross dependency is built. In my case that was ncursesw.
  • ncurses later assumes it was built already. The non-w libraries are missing and the stripping fails.

I have now simply "fixed" this by aligning the 'nano' dependency to 'ncursesw'. Now the ncurses depedency is gone and the compilation succeeds. I just don't know what the implications are. Is this a valid "fix" or should we need to tackle the design of the ncurses and ncursesw packages really?

@ymartin59
Copy link
Contributor

@m4tt075 I really wonder what was the initial need to split ncurses/ncursesw. For a reason I do not explain I had to switch Python 3 from ncurses to ncursesw (and so readline) to get it build over latest master - #3562
With impact on "readline", probably many other packages will follow the same move, with question to know if it is still relevant to keep both ncurses and ncursesw.
Have you got any opinion about it?

@ymartin59
Copy link
Contributor

Part of the answer, "cross/ncursesw" has been introduced in 2012 for Midnight Commander.

@m4tt075
Copy link
Contributor Author

m4tt075 commented Feb 12, 2019

@ymartin59 I have no idea unfortunately, just used "trial and error" to see what compiles...
I've found some information here: https://invisible-island.net/ncurses/ncurses.faq.html. Not sure about the implications, but it says:
"The normal ncurses libraries support 8-bit characters. The ncurses library can also be configured (--enable-widec) to support wide-characters (for instance Unicode and the UTF-8 encoding). The corresponding wide-character ncursesw libraries are source-compatible with the normal applications. That is, applications must be compiled and linked against the ncursesw library."
The ncurses 5.3 release provides UTF-8 support. The special cases of Linux console and screen were addressed in development patches completed at the end of 2002."

For an overview of what we currently have, here the dependencies in master:

ncurses (no w) ncursesw
alsa-utils mc
bash mutt
erlang ncdu
htop zsh
irssi
mosh
nano
pinentry
procps-ng
python3
python
readline
rtorrent

@m4tt075
Copy link
Contributor Author

m4tt075 commented Feb 12, 2019

@ymartin59 History repeating: See #2121. I haven't found the referenced PR though...

@m4tt075
Copy link
Contributor Author

m4tt075 commented Feb 28, 2019

@ymartin59 Just looked at this again but still stuck. Any further thoughts from you on how to proceed here based on the additional information I referenced above?
@chickenandpork Or from you? Any advice appreciated!

@ymartin59
Copy link
Contributor

ymartin59 commented Mar 3, 2019

@m4tt075 Sure I will help as soon as I am available for it... Problem is that Python 3.6 is on fire right now.

- jdupes 1.13.2
- less 530
- tree 1.8.0
- rhash 1.3.8
- mc 4.8.23
- ncdu 1.14.1
- nano 4.4
- change nano dependency from ncurses to ncursesw
- some fixes
@hgy59
Copy link
Contributor

hgy59 commented Sep 15, 2019

@ymartin59 How shall I create my pull request?

I have my work in progress already finished that implements the synocli-file package with some enhancements over this PR.

  • contains all the packages of this PR
  • has a redesign of ncursesw to allow mixed package dependencies on ncurses and ncursesw
  • includes rnm 4.0.6 (rename-tool that does not depend on other packages like perl) for archs with GCC >= 4.8 (not for ARM5 and PPC except qoriq)
  • includes file tool 5.30
  • with symlinks to /usr/local/bin for all tools (links are created on install and removed on uninstall)

How can I apply my changes to this PR? - or shall I create a new PR? - or shall I wait until this PR is merged and then create a new PR?

Appreciate any hint.

@m4tt075
Copy link
Contributor Author

m4tt075 commented Sep 15, 2019

AFAIC, feel free to open a new PR and just close mine, if you want to...

@ymartin59 ymartin59 merged commit 5df16e1 into SynoCommunity:master Sep 17, 2019
@ymartin59
Copy link
Contributor

@hgy59 I have just merged to master to keep track of all contributions included in that package.

You should be able to rebase your own branch over it and submit a PR from the result.
Then I will review, build and package...

@m4tt075
Copy link
Contributor Author

m4tt075 commented Sep 17, 2019

Very kind. Thanks @ymartin59.

@paugarube
Copy link

Great project! What about including the latest version of jdupes? ;-)

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.

7 participants