Opened 15 years ago

Closed 15 years ago

Last modified 15 years ago

#17433 closed submission (fixed)

Add py25-jinja2 port

Reported by: arthur@… Owned by: macports-tickets@…
Priority: Normal Milestone:
Component: ports Version: 1.7.0
Keywords: Cc: MarcusCalhoun-Lopez (Marcus Calhoun-Lopez), blb@…
Port: py25-jinja2

Description

We already have Jinja 1 in ports but not Jinja 2. Both versions are maintained separately by the developers.

Attachments (4)

Portfile (1.1 KB) - added by arthur@… 15 years ago.
Version 2.1.1
Portfile.blb (1.2 KB) - added by blb@… 15 years ago.
updated Portfile
patch-setup.py.diff (413 bytes) - added by blb@… 15 years ago.
files/patch-setup.py.diff
Portfile.2 (1.2 KB) - added by arthur@… 15 years ago.
py-jinja2

Download all attachments as: .zip

Change History (12)

comment:1 Changed 15 years ago by MarcusCalhoun-Lopez (Marcus Calhoun-Lopez)

Cc: mcalhoun@… added

Cc Me!

Changed 15 years ago by arthur@…

Attachment: Portfile added

Version 2.1.1

comment:2 Changed 15 years ago by arthur@…

I've updated the Portfile to Jinja 2.1.1 and added a livecheck.

However, there's still a problem with the directory layout. The setup.py of Jinja2 installs the docs directly into /opt/local/docs:

Warning: violation by /opt/local/docs
Warning: py25-jinja2 violates the layout of the ports-filesystems!
Warning: Please fix or indicate this misbehavior (if it is intended), it will be an error in future releases!
$ port contents py25-jinja2
Port py25-jinja2 contains:
  /opt/local/docs/api.html
  /opt/local/docs/changelog.html
  /opt/local/docs/extensions.html
  /opt/local/docs/faq.html
  /opt/local/docs/genindex.html
  /opt/local/docs/index.html
  ...

I'm currently clueless. What would be a proper solution for this problem?

comment:3 Changed 15 years ago by nerdling (Jeremy Lavergne)

Version: 1.6.01.7.0

The easiest way to fix this is to move the docs directory to be what want if it was inside of ${prefix} and updating setup.py's documentation_path to reflect this. Who are our Python gurus?

comment:4 Changed 15 years ago by blb@…

Cc: blb@… added
Port: py25-jinja2 added

distutils uses the same path as that listed in data_files (in setup.py); since that's just using 'docs' it ends up in ${prefix}/docs. Attached is a setup.py patch and updated Portfile which should fix this (into ${prefix}/share/doc/${name} like most ports).

Changed 15 years ago by blb@…

Attachment: Portfile.blb added

updated Portfile

Changed 15 years ago by blb@…

Attachment: patch-setup.py.diff added

files/patch-setup.py.diff

Changed 15 years ago by arthur@…

Attachment: Portfile.2 added

py-jinja2

comment:5 Changed 15 years ago by arthur@…

Thanks blb, the patch works great. I attached a Portfile for python2.4, which uses the same patch.

comment:6 Changed 15 years ago by nerdling (Jeremy Lavergne)

Resolution: fixed
Status: newclosed

Submitted:

py25-jinja2: r48647

py-jinja2: r48648

comment:7 Changed 15 years ago by jmroot (Joshua Root)

Type: enhancementsubmission

comment:8 Changed 15 years ago by (none)

Milestone: Port Submissions

Milestone Port Submissions deleted

Note: See TracTickets for help on using tickets.