Created attachment 248269 [details] sources This "bug" introduces a new utility - in the spirit of posixshmcontrol - for managing POSIX message queues. Included in tarball are - one C source file, one man-page, and several (sh) test scripts from regression. Summary of features: 1 create one or more new queues with the following in common: * maximum message size. * maximum queue depth. * mode bits (rwx). * group and user ownership (by ID or name). * blocking or non-blocking I/O. 2. update all of the above attributes to existing queues. 3. inspect the above attributes on one or more existing queues. 4. send one or more messages to one or more named queues with optional priority. 5. receive a message from a named queue. 6. remove one or more named queues. This utility requires the mqueuefs kernel module to be loaded. It does NOT require or make use of a mounted mqueuefs. Justification * Create all required queues following boot. * De-couple queue administration from application code. * Queue depthing monitoring. * Access control management with or without a mounted mqueuefs file system. More details can be found in the manual page. Steps for a convenient way to view the manual page: gzip -k posixmqcontrol.1 mkdir man1 mv -f posixmqcontrol.1.gz man1/ man -M . posixmqcontrol
Suggest you make a port for this.
I suggest you make a port of this first. Once it's demonstrated it can replace rcorder a decision by the community of developers to move it to src would probably happen. This is how mergemaster, etcupdate, and other utilities managed to make it into base. How about we do that first?
Will do Cy! Thanks for your input.
I suggest you host the sources in a github repo and use the ports github plumbing to fetch the tarballs for your port. Once the port is ready, I'll give it a once-over and commit it.
This isn't a replacement for rcorder but would be a new tool. It should probably just go straight into base without being a port. It is probably easier to do code review for a change like this as a patch against the src repository either on reviews.freebsd.org or as a PR against GitHub.com/freebsd/freebsd-src.
(In reply to John Baldwin from comment #5) I can put it into /usr/bin then.
Created attachment 248292 [details] posixmqcontrol as a port Checking back here after creating a GH repo and port style patch. I'll do another patch for base so you can choose which ever is best.
Created attachment 248293 [details] Fixed build errors, ready for commit. Fixed build errors and ready for commit. Do we want to do a review for this? I think so.
Comment on attachment 248293 [details] Fixed build errors, ready for commit. Thanks Cy!
Comment on attachment 248292 [details] posixmqcontrol as a port I think the port is a good thing too, because prior releases of FreeBSD can install the port.
Port builds clean. The proposed commit builds clean.
(In reply to unitrunker from comment #9) Can you please submit the src version I just uploaded for review at https://reviews.freebsd.org/. Add jhb, imp, emaste, and myself as reviewers. Also take a look at the three changes I made to make it build. I had to rename a couple of variables. You may want to replace the names I picked with other names. Also review the commit log message in the patch above. I'd rather you use your words than mine. The port doesn't need a review. I'll review it and commit it as is.
Done. https://reviews.freebsd.org/D43813 This is a slightly tweaked version from the attached (variable rename). I also updated the GH repo - with the same changes - which is now at version v0.0.5. The port patch needs a new Makefile and 'make makesum'.
Created attachment 248296 [details] posixmqcontrol as a port Ports patch file updated to v0.0.5 (variable renamed).
So far, GH repo is up to v0.0.6 - mostly from kib's feedback. Need to update both sets of patches.
Created attachment 248340 [details] posixmqcontrol as a port v0.0.7 Mostly applies checkstyle9.pl feedback.
Created attachment 248383 [details] posixmqcontrol as a port v0.0.10 Updated with more feedback from kib.
Created attachment 248384 [details] posixmqcontrol as a port v0.0.11 more style(9) fixes