New Ticket     Wiki     Browse Source     Timeline     Roadmap     Ticket Reports     Search

Ticket #12190 (closed submission: fixed)

Opened 5 years ago

Last modified 3 years ago

NEW: lang/omega

Reported by: ggreif@… Owned by: macports-tickets@…
Priority: Normal Milestone:
Component: ports Version:
Keywords: Cc:
Port:

Description

I am contributing my second port.

Attachments

Omega-port.tgz Download (1.2 KB) - added by ggreif@… 5 years ago.
Portfile and files/ (lang/omega/._Portfile is resource fork?)
Omega-port2.tgz Download (1.2 KB) - added by heisenbug 5 years ago.
updated version

Change History

Changed 5 years ago by ggreif@…

Portfile and files/ (lang/omega/._Portfile is resource fork?)

Changed 5 years ago by jmpp@…

I was ready to commit this port until I saw something a bit disturbing in the patchfile:

+PREFIX           = /usr/local

Which I cannot understand in light of destroot declaration in the Portfile:

destroot.args           PREFIX=${destroot}${prefix}

First off, hardcoding the prefix anywhere is bad practice. And even that put aside, choosing /usr/local as a prefix is even worse. What are each of these two lines for?

In case you want to provide a prefix declaration in the Makefile without hardcoding anything, a good approach is:

+PREFIX           = __PREFIX__

And then in the Portfile:

post-patch {
    reinplace "s/__PREFIX__/${prefix}/" path-to-file-you-want-to-edit
}

But in this case I just don't understand how prefix in the Makefile and destroot.args interplay. Please explain!

Regards,...

-jmpp

Changed 5 years ago by ggreif@…

The reason why I do it this way is simply because I do not know what the good practice is.

How do I tell to the install target in the makefile where to put the build result?

OTOH if I use $(PREFIX) in the makefile I consider it important to have a declaration of the make variable at least.

What is the recommended practice?

Changed 5 years ago by heisenbug

updated version

Changed 5 years ago by ggreif@…

new patched Makefile now makes use of DESTDIR var Portfile provides destroot.destdir, otherwise we are pretty standard now :-)

Please ignore lang/omega/._Portfile in the tarball!

Changed 5 years ago by jmpp@…

  • status changed from new to closed
  • resolution set to fixed

Committed in r26579 with some minor fixes, see the commit log for details. Thanks for the contribution, keep it flowing!

-jmpp

Changed 5 years ago by ggreif@…

Any specific reason why you checked it in under lang/Omega instead of lang/omega?

(Almost) All the other ports use a small letter.

Changed 5 years ago by jmpp@…

From looking at the project homepage I realized it's named Omega, not omega, so we should be consistent with that: I made both portname and portfir uppercase. I checked it in with the correct casing to begin with because modifying it later on when we realize "ohh, this should have been uppercase!" can be a pain. If there are ports that aren't consisten with their casing... then it'll be a pain renaming them ;-)

-jmpp

Changed 5 years ago by jmpp@…

  • milestone changed from New Ports to Port Submissions

Milestone New Ports deleted

Changed 5 years ago by nox@…

  • priority changed from Expected to Normal
  • version 1.4.40 deleted
  • type changed from contribution to enhancement
  • summary changed from new port: lang/omega to NEW: lang/omega

Changed 3 years ago by jmr@…

  • type changed from enhancement to submission

Changed 3 years ago by anonymous

  • milestone Port Submissions deleted

Milestone Port Submissions deleted

Note: See TracTickets for help on using tickets.