Opened 14 years ago

Closed 14 years ago

Last modified 9 years ago

#29445 closed submission (fixed)

jslint port

Reported by: tael67@… Owned by: ryandesign (Ryan Carsten Schmidt)
Priority: Normal Milestone:
Component: ports Version: 1.9.2
Keywords: Cc:
Port: jslint

Description

Here is a port for jslint (http://jslint.com/)

Attachments (3)

Portfile (1.1 KB) - added by tael67@… 14 years ago.
Portfile.2 (1.1 KB) - added by tael67@… 14 years ago.
patch-jslint.js.diff (1.1 KB) - added by tael67@… 14 years ago.

Download all attachments as: .zip

Change History (7)

Changed 14 years ago by tael67@…

Attachment: Portfile added

comment:1 Changed 14 years ago by ryandesign (Ryan Carsten Schmidt)

Some observations:

  • This is different from the existing javascript-lint port, yes?
  • Pin the fetch down to a specific revision (git.branch...)
  • Does this port install architecture-specific files? (supported_archs...)
  • You cannot run "js" in pre-fetch; the dependencies might not have been built by then (they will have been built by pre-configure)
  • Don't put a slash before ${prefix} (${prefix} already starts with a slash)
  • Don't put "/opt/local" in the patchfile (use "@PREFIX@")

comment:2 in reply to:  1 Changed 14 years ago by tael67@…

Replying to ryandesign@…:

Some observations:

  • This is different from the existing javascript-lint port, yes?
  • Pin the fetch down to a specific revision (git.branch...)
  • Does this port install architecture-specific files? (supported_archs...)
  • You cannot run "js" in pre-fetch; the dependencies might not have been built by then (they will have been built by pre-configure)
  • Don't put a slash before ${prefix} (${prefix} already starts with a slash)
  • Don't put "/opt/local" in the patchfile (use "@PREFIX@")
  • Yes, they are too different (although similar) software.
  • OK, sorry.
  • No, it is entirely in JavaScript.

I will test what you suggested and upload an updated portfile.

Last edited 9 years ago by ryandesign (Ryan Carsten Schmidt) (previous) (diff)

Changed 14 years ago by tael67@…

Attachment: Portfile.2 added

Changed 14 years ago by tael67@…

Attachment: patch-jslint.js.diff added

comment:3 Changed 14 years ago by ryandesign (Ryan Carsten Schmidt)

Owner: changed from macports-tickets@… to ryandesign@…
Status: newassigned

Thanks.

comment:4 Changed 14 years ago by ryandesign (Ryan Carsten Schmidt)

Resolution: fixed
Status: assignedclosed

Committed in r78580 with these changes:

  • fixed whitespace (tabs to spaces, indent to multiple of 4 spaces, as the modeline says)
  • added "supported_archs noarch" since there are no architecture-specific files installed
  • do the reinplace of @PREFIX@ to ${prefix} in the patch phase
  • instead of "use_configure no" and a pre-configure block, just write a configure block
  • specify absolute path to js, just in case
  • use "return -code error" (not "error") to error out
  • tweaked wording of error message
  • switched spidermonkey depends_run to depends_lib, since it is needed at build time (namely in the check in the configure phase)

On my system, "js -e "new File();"" crashes with a segmentation fault, so the port tells me I need to install spidermonkey with the +fileobject variant, though I already have. Here's hoping other users don't see that.

Note: See TracTickets for help on using tickets.