cal(1) on Solnix vs Linux and the BSDs

On Solnix, cal is the illumos cal at /usr/bin/cal. Its synopsis is only cal [ [month] year ], with no options at all. Scripts that use -y, -j, -3, -m, -h or a month name will fail or behave differently, because Linux and the BSDs all add options.

What Solnix runs

A default Solnix system runs the illumos cal at /usr/bin/cal. No other variants are shipped. It is not the util-linux cal that Linux uses, and it is not the FreeBSD cal/ncal pair.

Differences

Compared withTopicWhat differs
all fourno optionsSolnix cal takes no options: the synopsis is cal [ [month] year ]. Linux, FreeBSD, OpenBSD and NetBSD all document options such as -j and -y. An invocation like cal -y or cal -j is not described by the Solnix page.
Source: Solnix cal(1) SYNOPSIS; Linux cal(1) OPTIONS; FreeBSD cal(1) SYNOPSIS; OpenBSD cal(1) SYNOPSIS; NetBSD cal(1) SYNOPSIS
Linux, FreeBSD, OpenBSDmonth namesSolnix month must be a decimal integer from 1 to 12. Linux, FreeBSD and OpenBSD also accept a month name or abbreviation, and a single month-name argument. NetBSD documents only numeric months (1 - 12).
Source: Solnix cal(1) OPERANDS month; Linux cal(1) DESCRIPTION; FreeBSD cal(1) DESCRIPTION; OpenBSD cal(1) DESCRIPTION; NetBSD cal(1) DESCRIPTION
Linux, FreeBSD, OpenBSD-m meaningSolnix has no -m. On Linux and OpenBSD, -m makes Monday the first day of the week. On FreeBSD, -m month selects a month, and Monday-first is -M. NetBSD has no -m; it uses -d day-of-week (0-6).
Source: Linux cal(1) -m, --monday; OpenBSD cal(1) -m; FreeBSD cal(1) -m, -M; NetBSD cal(1) -d; Solnix cal(1) SYNOPSIS
Linux, FreeBSD, NetBSD-h meaningSolnix has no -h. On Linux, -h prints help and exits. On FreeBSD it toggles highlighting of today. On NetBSD it highlights the current day. OpenBSD has no -h.
Source: Linux cal(1) -h, --help; FreeBSD cal(1) -h; NetBSD cal(1) -h; OpenBSD cal(1) SYNOPSIS
all fourJulian day numbers (-j)Solnix has no -j to number days from January 1. Linux, FreeBSD, OpenBSD and NetBSD all provide -j for day-of-year numbering.
Source: Linux cal(1) -j; FreeBSD cal(1) -j; OpenBSD cal(1) -j; NetBSD cal(1) -j; Solnix cal(1) SYNOPSIS
Linux, FreeBSD, NetBSDseveral months and whole-year flagsSolnix cal shows one month, or a whole year when the year operand is given alone. Linux has -3, -n, -S and -Y; FreeBSD has -3, -A, -B; NetBSD has -3, -A, -B, -C to show surrounding months.
Source: Solnix cal(1) DESCRIPTION; Linux cal(1) -3, -n, -S, -Y; FreeBSD cal(1) -3, -A, -B; NetBSD cal(1) -3, -A, -B, -C
all fourJulian/Gregorian switchSolnix NOTES say September 1752 looks unusual because 11 days were skipped, and the page offers no way to change the switch date. Linux has --reform, FreeBSD ncal has -s country_code, and NetBSD has -R reform-spec. OpenBSD documents no way to change it.
Source: Solnix cal(1) NOTES; Linux cal(1) --reform; FreeBSD cal(1) -s; NetBSD cal(1) -R; OpenBSD cal(1) DESCRIPTION
Linuxoperand formsSolnix accepts at most [month] year. Linux also accepts a leading day operand ([[day] month] year) and a timestamp or month name as a single argument.
Source: Solnix cal(1) SYNOPSIS; Linux cal(1) SYNOPSIS
NetBSDsingle-argument ISO formOn NetBSD a single parameter can be year and month in ISO format, as in cal 2007-12. The Solnix page documents a single operand only as the year.
Source: NetBSD cal(1) DESCRIPTION; Solnix cal(1) DESCRIPTION and OPERANDS
Linux, FreeBSDweek numbers, Easter, vertical layoutSolnix cal has no week numbers, Easter dates or vertical layout. FreeBSD ncal adds -w and -e/-o (Easter). OpenBSD cal -w prints week numbers. Linux has -w and -v, which is ncal-style output.
Source: FreeBSD cal(1) -w, -e, -o; OpenBSD cal(1) -w; Linux cal(1) -w, -v; Solnix cal(1) SYNOPSIS
FreeBSDcurrent date and TZThe Solnix page says TZ determines the timezone used to calculate the current month. FreeBSD says month and year default to the system clock and time zone. The other counterpart pages do not say.
Source: Solnix cal(1) ENVIRONMENT VARIABLES (TZ); FreeBSD cal(1) DESCRIPTION

Standards

  • POSIX: cal is a POSIX.1-2024 utility.
  • Solnix: Interface Stability: Standard.
  • FreeBSD: cal is compliant with the X/Open System Interfaces option of IEEE Std 1003.1-2008 (“POSIX.1”). The flags [-3ehJMopwy], and a month name as a single argument, are extensions.
  • OpenBSD: cal is compliant with the X/Open System Interfaces option of the specification. The flags [-jmwy], and a month name as a single argument, are extensions.

Writing portable scripts

  • Use only cal [[month] year] with a numeric month and a fully written four-digit year; every system in the bundle accepts that form.
  • Avoid cal options in portable scripts: -m, -h and -j differ in meaning across systems or are missing on Solnix.

Every difference here is taken from the manual pages linked above: Solnix's published page, Linux (man-pages and the GNU and util-linux manuals), FreeBSD, OpenBSD and NetBSD. Each row names its source. Where a manual is silent, this page is too. Compiled 2026-10-26. Found a mistake? Mail hackers@lists.solnix.io.