pykerberos: support for heimdal/linux #1

Closed
macosforgebot opened this Issue Aug 25, 2006 · 21 comments

2 participants

@macosforgebot

agx@… originally submitted this as ticket:37

  • Keywords: review

Hi, attached is a bunch of patches that adds support for linux/heimdal. They might not be as clean as possible but should show fairly well what to do. Please apply as approprioate. The patch order is:

  • printf-cleanups: generic cleanups
  • include-stdlib: include stdlib for definition of free(3)
  • kerberos-includes: fixup kerberos includes for non macosx
  • declare-nt-service: gss_krb5_nt_service_name is declared differently in heimdal
  • python-include: include "python.h"
  • fix-setup: detect "linux2" and pass correct linker flags

Cheers,

-- Guido

@macosforgebot

andrew@… originally submitted this as attachment:PyKerberos.patch:⁠ticket:37


Make the MacOS X specific includes more specific.

@macosforgebot

@wsanchez originally submitted this as comment:1:⁠ticket:37

  • Status changed from new to assigned
  • Priority changed from 5: Not set to 1: Blocker
  • Milestone set to Linux Port
@macosforgebot

@wsanchez originally submitted this as comment:2:⁠ticket:37

  • Keywords review added
@macosforgebot

agx@… originally submitted this as attachment:printf-cleanups:⁠ticket:37

@macosforgebot

agx@… originally submitted this as attachment:include-stdlib:⁠ticket:37


include stdlib.h for declaration of free(2)

@macosforgebot

agx@… originally submitted this as attachment:declare-nt-service:⁠ticket:37

@macosforgebot

agx@… originally submitted this as attachment:python-include:⁠ticket:37

@macosforgebot

agx@… originally submitted this as comment:3:⁠ticket:37


I've updated the patches so they apply against latest SVN. Please let me know about any issues with them.

@macosforgebot

@wsanchez originally submitted this as comment:4:⁠ticket:37


Where is C_MACOSX defined?

@macosforgebot

@wsanchez originally submitted this as comment:5:⁠ticket:37


printf-cleanups applied in r123

@macosforgebot

@wsanchez originally submitted this as comment:6:⁠ticket:37


include-stdlib applied in r124

@macosforgebot

@wsanchez originally submitted this as comment:7:⁠ticket:37


The #ifdef linux stuff is undesirable, and I think we can make it work without.

Specifically, in setup.py, we should find the framework and do the right -Ifoo magic so we don't need "Kerberos/" in the includes. Parking BSD stuff into frameworks is wonky, so we should use the "regular" includes in code and fix the OS X weirdness in setup.py. I think.

@macosforgebot

agx@… originally submitted this as attachment:kerberos-includes:⁠ticket:37


Remove Kerberos/ from the include statements

@macosforgebot

agx@… originally submitted this as comment:8:⁠ticket:37


I've updated fix-setup and kerberos-includes (as you suggested) to:

  • not use the Kerberos/ on OSX and gssapi/ prefixes on Linux
  • pass in the include patchs via setup.py
  • parse the correct link args on linux via krb5-config

declate-nt-service can be dropped since it's only needed for heimdal and I'm also building against MIT now. I'm not sure if the include patch is correct for Mac OSX, please modify if it isn't. Cheers,

-- Guido

@macosforgebot

@wsanchez originally submitted this as comment:9:⁠ticket:37


I put in a fix to setup.py in r200, which is based on your patch, but took out the sys.platform conditionals.  krb5-config should work on OS X also.

@macosforgebot

@wsanchez originally submitted this as comment:10:⁠ticket:37

  • Status changed from assigned to closed
  • Resolution set to fixed

python-include is covered in r201

@macosforgebot

@wsanchez originally submitted this as comment:11:⁠ticket:37

  • Status changed from closed to reopened
  • Resolution fixed deleted

kerberos-includes covered in r202

@macosforgebot

@wsanchez originally submitted this as comment:12:⁠ticket:37

  • Status changed from reopened to closed
  • Resolution set to fixed

I think r202 should work for you.  Let me know if anything else is needed.

@macosforgebot

agx@… originally submitted this as attachment:fix-setup:⁠ticket:37


Fix include path for linux

@macosforgebot

agx@… originally submitted this as comment:13:⁠ticket:37

  • Status changed from closed to reopened
  • Resolution fixed deleted

Looks almost fine now but "krb5-config --cflags" doesn't give anything reasonable on Linux either, that's why I hardcoded the include path previously. I've update "fix-setup" again. This one patch is all that's needed now, can it be applied?

@macosforgebot

@wsanchez originally submitted this as comment:14:⁠ticket:37

  • Status changed from reopened to closed
  • Resolution set to fixed

OK, I think the problem is actually that the #include is wrong, and OS X's krb5-config isn't broken either...

Try out r217 and let me know if that works.  (Thanks, Guido)

@macosforgebot macosforgebot added this to the Linux Port milestone Aug 4, 2016
@wsanchez wsanchez was unassigned by tomerd Aug 4, 2016
@wsanchez wsanchez was assigned by mocomoc Aug 4, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment