Project

General

Profile

Actions

Correction #10849

closed

Suggestions to improve docs related to package development

Added by Louis B over 3 years ago. Updated over 3 years ago.

Status:
Rejected
Priority:
Normal
Assignee:
-
Category:
Packages
Target version:
-
Start date:
08/23/2020
Due date:
% Done:

0%

Estimated time:

Description

I have been modifying the pfSense-pkg-pimd package, in order to support the upcoming pimd-version-3 release (still in beta, not yet publicly available). So same status for an upcomming pfSense-pkg-pimd-v3.

During that process I was facing a couple of documentation issues.

Please take care of the following documentation points:

a) https://docs.netgate.com/pfsense/en/latest/development/developing-packages.html#repository-branches
does not work: git clone git@github.com:pfsense/FreeBSD-ports.git pfSense-ports
should be: git clone https://github.com/pfsense/FreeBSD-ports.git pfSense-ports

b) NetGate is using git/github that is perfectly ok, however could you describe how that relates to the traditional FreeBSD ports, in relation pfSense of cause:
- /var/git/pfSense-ports/<cat>/<package> <> /usr/ports/<cat>/<package>
- gnu-auto-tools <> port commands
- git distribution-file => ports/distfiles > package <> git => make package => package

c) https://docs.netgate.com/pfsense/en/latest/development/developing-packages.html#repository-branches
Manifest File: description is probably not up to date
- a shell script is generated and placed in the "packet" directory
- I assume that that is the start/restart/stop script
- the scriptgenerator is called by write_rcfile(array("file" => "pimd.sh", "start" => $rc_file_start, "stop" => $rc_file_stop)
- I cannot find the script generator code related to “write_rcfile” in the git repository

d) “write_rcfile” is called from “<git/port>/<cat>/<packagename>/files/usr/local/pkg/<packagename>.inc”
- “<packagename>.inc” is generating the parameter values as needed by “write_rcfile”, however ... to do that you need package knowledge.
- so I am very surprises that “<packagename>.inc” has a big warning inside “This file was created by an automatic configuration generator.” Where 1) I can not locate that generator in the git directory and
2) …… independent of that magical generator, it does need input to do its work ….. and I could not find any file inside the package having that info …. Apart from the file “<packagename>.inc” itself !!??

e) Please indicate the directorys used / to use. I Assume:
- the packet gui-directory seems to be “/use/local/pkg/<packetname>/”
- the socket directory seems to be “/var/run/”
- start/stop/restart/script “/usr/local/etc/rc.d/”
- packet config /var/etc/<packetname>/

Sincerely,

Louis

Actions #1

Updated by Louis B over 3 years ago

Second line under c) "- a shell script" is a new subject "c2/d". sorry for the typo

Actions #2

Updated by Jim Pingle over 3 years ago

  • Status changed from New to Rejected
  • Assignee deleted (Jim Pingle)
  • Target version deleted (2.5.0)

a) is correct for those who have direct commit access to that repo. Others should be cloning their own fork, not that repo.

b) The relationship is fairly obvious to anyone doing development, and FreeBSD is also now using git for ports. The other notes make no sense. Discuss it on the forum.

c) The notes here also do not make any sense. Discuss it on the forum.
d) The notes here also do not make any sense. Discuss it on the forum. (There is no such warning in the .inc about the .inc, it's just a string put into config files to tell people not to touch them)

e) Unless noted otherwise, directories are those from hier(7) on FreeBSD, not specific to pfSense.

These docs will likely be revised in the near future but I doubt they will gain significant in-depth detail.

Actions

Also available in: Atom PDF