Created attachment 254519 [details] x11/sx: Start an X.Org Server sx is a simple alternative to both xinit(1) and startx(1) for starting an Xorg server. It started life as a proof of concept while attempting to learn how both xinit and startx worked while taking up the offer presented in startx: "Site administrators are STRONGLY urged to write nicer versions". It is not a direct replacement however as it provides a different, more limited, interface: * The server's command-line is hard coded and not exposed to the user. * The server doesn't listen on anything except unix domain sockets. * The server starts on the first available tty. * $DISPLAY is coupled to the tty user logged in on. * xauth entries are overwritten if the displayname is identical. * Corresponding xauth entries are unconditionally removed when the server exits. * The server uses the -noreset flag. * While $XAUTHORITY is still honoured, $XDG_DATA_HOME/sx/xauthority is used by default instead of $HOME/.Xauthority. * Very little proxy error checking is used preferring instead to let each tool speak for itself. * None of the typical /usr/local/etc/X11/xinit infrastructure is directly used. * Neither $XINITRC is honoured nor .xinitrc used. * The $XDG_CONFIG_HOME/sx/sxrc file is used instead of .xinitrc and is required to be executable. Author's design choice of coupling the tty number to Xorg's vt argument and $DISPLAY is patched in this FreeBSD port. See Earnestly/sx#7 for more details.
Created attachment 254641 [details] x11/sx: Add new port Fixed patch: * correct pkg-descr and commit message * remove commit message word-wrap * add "Signed-off-by" trailer
Very cool. I understand that ${DISTVERSION} is perferred over ${PORTVERSION}: https://docs.freebsd.org/en/books/porters-handbook/book/#makefile-versions You can use ${PLIST_FILES} directly in the Port's Makefile over creating pkg-plist, because the Port only installs "just a handful of files": https://docs.freebsd.org/en/books/porters-handbook/book/#porting-pkg-plist sx will need to be added to the parent directory Makefile: > SUBDIR += swaysettings > SUBDIR += sx > SUBDIR += sxhkd
Created attachment 254826 [details] x11/sx: Add new port (In reply to Alastair Hogge from comment #2) Thanks a lot. Here is the corrected patch. Let me ask a few questions: 1. When I created this, I noticed that I was not present in the CC List automatically, so I did it manually. Should I do this, or will I get emails about my reports anyway? 2. Why does pkg-plist in the previous attachments look like a modified file when it is actually a new file just like the others? I will upload a screenshot in the next attachment.
Created attachment 254827 [details] pkg-plist appearance
(In reply to Vlad Biley from comment #3) > 1. When I created this, I noticed that I was not present in the CC List automatically, so I did it manually. Should I do this, or will I get emails about my reports anyway? Good question, I have no idea; I think you have to add yourself, like you have concluded; it is a UX design pattern I do not understand. > 2. Why does pkg-plist in the previous attachments look like a modified file when it is actually a new file just like the others? I will upload a screenshot in the next attachment. Directly above the line: > 0- 1 The small NOTES section of sx(1) is a must-read. is the word "Added" (diff segment header), this is meant to indicate that the following is new, if you look at other bug reports, the modified header would be something like: > (-)b/port-category/fu-port/Makefile (-15 / +53 lines) > Lines 1-39 > minus this > add that Did you run your Port thru the various Port tools, portlint(1), portfmt(1), portclippy(1), and poudriere-testport(8)? I believe reviews.freebsd.org. is the preferred place for new Ports too.
The sx Makefile is also missing ${WWW} (https://docs.freebsd.org/en/books/porters-handbook/book/#porting-order-maintainer).
Created attachment 254912 [details] x11/sx: Add new port Fixed patch: * added WWW (see below) * added NO_ARCH (reported by poudriere-testport) * moved NO_BUILD (reported by portclippy) * formatted Makefile (used portfmt) (In reply to Alastair Hogge from comment #5) >the word "Added" (diff segment header), this is meant to indicate that the following is new Yes, but you may also see the two-pane (+/-) view with a blue background, rather than a single-pane (+) view with a green background like the others. >Did you run your Port thru the various Port tools, portlint(1), portfmt(1), portclippy(1), and poudriere-testport(8)? Only portlint. Now I have used all of this, thank you for the references. I have not yet had a time to study the full Porter's Handbook, where I see these tools are recommended. By the way, in my opinion, that whitespace alignment of Makefiles is debatable. But of course if there are rules, I will follow them. >I believe reviews.freebsd.org. is the preferred place for new Ports too. The Handbook recommends submitting ports here: https://docs.freebsd.org/en/books/porters-handbook/quick-porting/#porting-submitting Is that information out of date? (In reply to Alastair Hogge from comment #6) >The sx Makefile is also missing ${WWW}. I thought that with ports using GitHub the WWW is not required, as I discovered that in this case the framework automatically constructs WWW from GH_ACCOUNT/PORTNAME. There are also such ports in the tree, but I have just found that most of the ports specify WWW regardless of USE_GITHUB, so now I decided to add it too. Although this still seems a bit redundant to me.
Bump?