package/minicom: make default port and lock directory config options
PATCH 1/1 package/minicom: make default port and lock directory config options
Minicom's configure script will set values for the default port and lock directory based on the configuration of the host machine, which is not useful for cross-compiling, so make them config options that can be set to suit the target system.
--- package/minicom/Config.in | 16 ++++++++++++++++ package/minicom/minicom.mk | 3 +++ 2 files changed, 19 insertions(+)
package/minicom/Config.in +16 -0
@@ -14,3 +14,19 @@ config BR2_PACKAGE_MINICOM comment "minicom needs a toolchain w/ wchar" depends on BR2_USE_MMU depends on !BR2_USE_WCHAR + +if BR2_PACKAGE_MINICOM + +config BR2_PACKAGE_MINICOM_DFL_PORT + string "Default port" + default "/dev/ttyS1" + help + This option defines Minicom's default modem device. + +config BR2_PACKAGE_MINICOM_LOCK_DIR + string "Lock directory" + default "/var/lock" + help + This option defines the com line lock directory. + +endif
package/minicom/minicom.mk +3 -0
@@ -22,4 +22,7 @@ define MINICOM_MKDIR_M4 endef MINICOM_POST_PATCH_HOOKS += MINICOM_MKDIR_M4 +MINICOM_CONF_OPTS = --enable-dfl-port=$(BR2_PACKAGE_MINICOM_DFL_PORT) \ + --enable-lock-dir=$(BR2_PACKAGE_MINICOM_LOCK_DIR) + $(eval $(autotools-package))
Signature · 1 line
2.24.0
PATCH 1/1 package/minicom: make default port and lock directory config options
Hi James,
Quoted 4 lines · James Byrne
Minicom's configure script will set values for the default port and lock directory based on the configuration of the host machine, which is not useful for cross-compiling, so make them config options that can be set to suit the target system.
Good idea.
Quoted 1 line
Signed-off-by James Byrne <[email protected]>
Best regards
Signature · 2 lines
Giulio Benetti Benetti Engineering sas
Quoted 42 lines
--- package/minicom/Config.in | 16 ++++++++++++++++ package/minicom/minicom.mk | 3 +++ 2 files changed, 19 insertions(+)package/minicom/Config.in +16
-0@@ -14,3 +14,19 @@ config BR2_PACKAGE_MINICOM comment "minicom needs a toolchain w/ wchar" depends on BR2_USE_MMU depends on !BR2_USE_WCHAR + +if BR2_PACKAGE_MINICOM + +config BR2_PACKAGE_MINICOM_DFL_PORT + string "Default port" + default "/dev/ttyS1" + help + This option defines Minicom's default modem device. + +config BR2_PACKAGE_MINICOM_LOCK_DIR + string "Lock directory" + default "/var/lock" + help + This option defines the com line lock directory. + +endifpackage/minicom/minicom.mk +3
-0@@ -22,4 +22,7 @@ define MINICOM_MKDIR_M4 endef MINICOM_POST_PATCH_HOOKS += MINICOM_MKDIR_M4 +MINICOM_CONF_OPTS = --enable-dfl-port=$(BR2_PACKAGE_MINICOM_DFL_PORT) \ + --enable-lock-dir=$(BR2_PACKAGE_MINICOM_LOCK_DIR) + $(eval $(autotools-package))
PATCH 1/1 package/minicom: make default port and lock directory config options
In reply to James ByrneJames, All,
On 2019-11-21 15:30 +0000, James Byrne spake thusly:
Quoted 4 lines
Minicom's configure script will set values for the default port and lock directory based on the configuration of the host machine, which is not useful for cross-compiling, so make them config options that can be set to suit the target system.
Thnks for this patch.
However I wonder if it makes sense to have those configurable at all.
The man page of minicom states, for the lock dir, that it default to /var/lock on Linux ("GNU/Linux systems use /var/lock"), so we should probably set that. The user can provide an override in a system-wide config file (in /etc/minicom/).
Also, I think we should just set the default port (aka device in minicom terminology) do /dev/ttyS1, as written in the man page ("/dev/tty1 or /dev/ttyS1 for most people"). Ditto, users may override that with a system-wide config file.
So...
Quoted 20 lines
Signed-off-by James Byrne <[email protected]>--- package/minicom/Config.in | 16 ++++++++++++++++ package/minicom/minicom.mk | 3 +++ 2 files changed, 19 insertions(+)package/minicom/Config.in +6
-0@@ -14,3 +14,19 @@ config BR2_PACKAGE_MINICOM comment "minicom needs a toolchain w/ wchar" depends on BR2_USE_MMU depends on !BR2_USE_WCHAR + +if BR2_PACKAGE_MINICOM + +config BR2_PACKAGE_MINICOM_DFL_PORT + string "Default port" + default "/dev/ttyS1"
package/minicom/Config.in config BR2_PACKAGE_MINICOM · line 32
Quoted 10 lines
package/minicom/Config.in +10
-0+ help + This option defines Minicom's default modem device. + +config BR2_PACKAGE_MINICOM_LOCK_DIR + string "Lock directory" + default "/var/lock" + help + This option defines the com line lock directory. + +endif
... I would remove those options, and...
package/minicom/minicom.mk define MINICOM_MKDIR_M4 · line 26
Quoted 10 lines
package/minicom/minicom.mk +2
-0@@ -22,4 +22,7 @@ define MINICOM_MKDIR_M4 endef MINICOM_POST_PATCH_HOOKS += MINICOM_MKDIR_M4 +MINICOM_CONF_OPTS = --enable-dfl-port=$(BR2_PACKAGE_MINICOM_DFL_PORT) \ + --enable-lock-dir=$(BR2_PACKAGE_MINICOM_LOCK_DIR)
... just use the sane values here:
MINICOM_CONF_OPTS = \
--enable-dfl-port=/dev/ttyS1 \
--enable-lock-dir=/var/lockRegards,
Yann E. MORIN.
Quoted 8 lines
package/minicom/minicom.mk +0
-0$(eval $(autotools-package))Signature · 6 lines
2.24.0 _______________________________________________ buildroot mailing list buildroot at busybox.net http://lists.busybox.net/mailman/listinfo/buildroot
Signature · 6 lines
.-----------------.--------------------.------------------.--------------------. | Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: | | +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ | | +33 561 099 427 `------------.-------: X AGAINST | \e/ There is no | | http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. | '------------------------------^-------^------------------^--------------------'
PATCH 1/1 package/minicom: make default port and lock directory config options
Quoted 4 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
"Yann" == Yann E MORIN <[email protected]> writes:
James, All,
On 2019-11-21 15:30 +0000, James Byrne spake thusly:
Quoted 8 lines
Quoted 4 lines
Minicom's configure script will set values for the default port and lock directory based on the configuration of the host machine, which is not useful for cross-compiling, so make them config options that can be set to suit the target system.
Thnks for this patch.
However I wonder if it makes sense to have those configurable at all.
My thought exactly.
Quoted 9 lines
The man page of minicom states, for the lock dir, that it default to
/var/lockon Linux ("GNU/Linux systems use/var/lock"), so we should probably set that. The user can provide an override in a system-wide config file (in/etc/minicom/).Also, I think we should just set the default port (aka device in minicom terminology) do
/dev/ttyS1, as written in the man page ("/dev/tty1or/dev/ttyS1for most people"). Ditto, users may override that with a system-wide config file.
I wonder if ttyS0 wouldn't be a more sensible default. But ok, if you use /dev/ttyS0 for the Linux console, then ttyS1 is probably indeed a good default.
Signature · 1 line
Bye, Peter Korsgaard
PATCH v2 1/1 package/minicom: make default port and lock directory fixed defaults
In reply to James ByrneMinicom's configure script will set values for the default port and lock directory based on the configuration of the host machine, which is not useful for cross-compiling or reproducible builds, so instead set them to sensible default values.
---
Changes v1 -> v2:
- Use fixed default values instead of configurable ones.
--- package/minicom/minicom.mk | 2 ++ 1 file changed, 2 insertions(+)
package/minicom/minicom.mk +2 -0
@@ -22,4 +22,6 @@ define MINICOM_MKDIR_M4 endef MINICOM_POST_PATCH_HOOKS += MINICOM_MKDIR_M4 +MINICOM_CONF_OPTS = --enable-dfl-port=/dev/ttyS1 --enable-lock-dir=/var/lock + $(eval $(autotools-package))
Signature · 1 line
2.24.0
Thomas Petazzoni
AppliedPATCH v2 1/1 package/minicom: make default port and lock directory fixed defaults
Quoted 10 lines · On Tue, 26 Nov 2019 09:52:04 +0000 James Byrne <[email protected]>…
Minicom's configure script will set values for the default port and lock directory based on the configuration of the host machine, which is not useful for cross-compiling or reproducible builds, so instead set them to sensible default values.
Signed-off-by James Byrne <[email protected]>---
Changes v1 -> v2:
- Use fixed default values instead of configurable ones.
Applied to master, thanks.
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Bootlin Embedded Linux and Kernel engineering https://bootlin.com
PATCH v2 1/1 package/minicom: make default port and lock directory fixed defaults
In reply to James ByrneQuoted 7 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
"James" == James Byrne <[email protected]> writes:
Minicom's configure script will set values for the default port and lock directory based on the configuration of the host machine, which is not useful for cross-compiling or reproducible builds, so instead set them to sensible default values.
Quoted 5 lines
Signed-off-by James Byrne <[email protected]>---
Changes v1 -> v2:
- Use fixed default values instead of configurable ones.
Committed to 2019.02.x and 2019.08.x, thanks.
Signature · 1 line
Bye, Peter Korsgaard