Page MenuHomeFreeBSD

[new port] print/miktex: cross-platform implementation of TeX/LaTeX and related programs
ClosedPublic

Authored by arrowd on Jan 20 2019, 9:50 AM.
Tags
None
Referenced Files
Unknown Object (File)
Sun, Nov 24, 3:42 PM
Unknown Object (File)
Sun, Nov 24, 3:42 PM
Unknown Object (File)
Sun, Nov 24, 3:42 PM
Unknown Object (File)
Thu, Nov 21, 10:55 AM
Unknown Object (File)
Tue, Nov 19, 4:59 PM
Unknown Object (File)
Sat, Nov 16, 10:18 AM
Unknown Object (File)
Oct 30 2024, 6:43 PM
Unknown Object (File)
Oct 30 2024, 6:43 PM

Details

Summary

Open problems:

  • Not sure what to put into LICENSE var. MiKTeX COPYING.md file states MiKTeX has neither a single copyright holder nor a single license covering its entire contents, since it is a collection of many independent packages.
  • To actually use installed package, user have to run miktexsetup finish, which would install additional files into ~/bin. Running this command as root would install into /usr/local/bin. There is no way to override these directories until https://github.com/MiKTeX/miktex/issues/195 is fixed.

Diff Detail

Repository
rP FreeBSD ports repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

Hello.

I've updated to 2.9.6975, added some OPTIONS, and shut portlint. There are more OPTIONS opportunities like INSTALL_MIKTEX_HEADERS (fail to build with some Linux file missing) and WITH_LUA54TEX (lua54 is not in ports yet).

You could avail adding OPTIONS to LINK_EVERYTHING_STATICALLY and INSTALL_STATIC_LIBRARIES. :-)

[EDITED]
https://termbin.com/ott7
[EDITED]

The only downside of MiKTex would be the necessity to modify bsd.tex.mk in order to avoid Tex-Live ports installed for ports with USE_TEX.

Thank you! \o/

tcberner added inline comments.
print/miktex/Makefile
19 ↗(On Diff #53034)

^ when in doubt, leave it out :D

40 ↗(On Diff #53034)

^ I would prefer

USE_QT= core concurrent gui printsupport script scripttools uitools xml \
        buildtools_build qmake_build
print/miktex/pkg-plist
194 ↗(On Diff #53034)

^ these probably should not use %%DATADIR%%

From the Handbook:

LICENSE= UNKNOWN
LICENSE_NAME= unknown
LICENSE_TEXT= This program is NOT in public domain. It can be freely distributed for non-commercial purposes only.
LICENSE_PERMS= dist-mirror no-dist-sell pkg-mirror no-pkg-sell auto-accept

mat added inline comments.
print/miktex/pkg-plist
192 ↗(On Diff #53034)

DATADIR is a directory which means, it must always be %%DATADIR%%/.

There is a problem with luatex:

FATAL error while preloading lua module luatex_url_lua_open(L)Process 45975 stopped
* thread #1, name = 'miktex-luatex', stop reason = signal SIGABRT
    frame #0: 0x00000008011ac17a libc.so.7`__sys_thr_kill at thr_kill.S:3
   1   	#include "compat.h"
   2   	#include "SYS.h"
-> 3   	RSYSCALL(thr_kill)
   4   		.section .note.GNU-stack,"",%progbits
linimon retitled this revision from Add port for MiKTeX. to [new port] print/miktex: cross-platform implementation of TeX/LaTeX and related programs.Feb 18 2019, 2:51 AM
arrowd marked 4 inline comments as done.
  • Update to 2.9.6980.
  • Incorporate changes by @rigoletto
  • Address comments

miktex-luatex requires net/luasocket for Lua 5.3, but there are no FLAVORS for Lua, so I can't depend on that. @mat, any thoughts how to workaround it?

print/miktex/Makefile
74–79 ↗(On Diff #54067)

Please use options helpers.

arrowd marked an inline comment as done.
  • Use option helpers for UIQT.

The question about net/luasocket stays open.

print/miktex/Makefile
20 ↗(On Diff #55829)

Please remove this. poudriere will build this without a problem, it has auto-accept. If you are testing a restricted port, sipmly add DISABLE_LICENSES=yes the make.conf.

arrowd marked an inline comment as done.
  • Update to 7000, remove license hack.

So, I need net/luasocket for LUA 5.3. Should I open a PR requesting lua flavorization, or just create a net/luasocket53?

So, I need net/luasocket for LUA 5.3. Should I open a PR requesting lua flavorization, or just create a net/luasocket53?

I do not think anyone has plans to write flavors for USES=lua so openning a PR requesting it would probably be pointless.

In D18903#433045, @mat wrote:

I do not think anyone has plans to write flavors for USES=lua so openning a PR requesting it would probably be pointless.

I need a way forward. Should I start looking into flavorizing LUA, switching everything to lua 5.3 or creating a net/luasocket53?

In D18903#433045, @mat wrote:

I do not think anyone has plans to write flavors for USES=lua so openning a PR requesting it would probably be pointless.

I need a way forward. Should I start looking into flavorizing LUA, switching everything to lua 5.3 or creating a net/luasocket53?

I have no idea if having flavors for lua makes sense. I think the best way to move forward would be a luasocket53 port for now.

  • Properly install symlinks.

It turned out that miktex uses internal LUA and luasocket, so the new port isn't needed. Bad news is that I cannot figure out where the error comes from. Any help with debugging this would be welcome.

Upstream has fixed the LUA bug and it will be present in the next release.

The LUA bug have not been fixed and upstream seem to be reluctant to fix it.

  • Workaround LUA problem by using GCC to compile the port.

The port is ready to be committed. I'll wait for couple of days in case someone wants to review it.

It seems, it still would be skipped by poudriere due to

Ignored: License NONE needs confirmation, but BATCH is defined

If I want miktex to be present in FreeBSD packages, what should I do?

  • Refresh distfiles and host them on LOCAL, as they tend to change over time.
  • Disable UIQT and SYNCTEX options, as these are causing compilation failures with GCC. Fix plist for DOCS and CONTEXT options.

Too many bugs, postponing this for later.

  • Update to 20.10. The ports seem to be working now.
  • Update to 20.11. The ports seem to be working now.
  • Properly handle all OPTIONS.
  • Add pkg-message.

I have battle-tested this port and it works for me. Any last comments before I commit it?

This revision was not accepted when it landed; it landed in state Needs Review.Nov 5 2020, 8:10 PM
This revision was automatically updated to reflect the committed changes.