mirror of
https://salsa.debian.org/freeipa-team/freeipa.git
synced 2025-02-25 18:55:28 -06:00
Prevent *.pyo and *.pyc multilib problems
Differences in the python byte code fails in a build validation
(rpmdiff) done on difference architecture of the same package.
This patch:
1) Ensures that timestamps of generated *.pyo and *.pyc files match
2) Python integer literals greater or equal 2^32 and lower than 2^64
are converted to long right away to prevent different type of
the integer on architectures with different size of int
https://fedorahosted.org/freeipa/ticket/3858
This commit is contained in:
2
Makefile
2
Makefile
@@ -122,6 +122,7 @@ version-update: release-update
|
||||
> ipatests/setup.py
|
||||
perl -pi -e "s:__NUM_VERSION__:$(IPA_NUM_VERSION):" ipapython/version.py
|
||||
perl -pi -e "s:__API_VERSION__:$(IPA_API_VERSION_MAJOR).$(IPA_API_VERSION_MINOR):" ipapython/version.py
|
||||
touch -r ipapython/version.py.in ipapython/version.py
|
||||
sed -e s/__VERSION__/$(IPA_VERSION)/ daemons/ipa-version.h.in \
|
||||
> daemons/ipa-version.h
|
||||
perl -pi -e "s:__NUM_VERSION__:$(IPA_NUM_VERSION):" daemons/ipa-version.h
|
||||
@@ -135,6 +136,7 @@ version-update: release-update
|
||||
if [ "$(SUPPORTED_PLATFORM)" != "" ]; then \
|
||||
sed -e s/SUPPORTED_PLATFORM/$(SUPPORTED_PLATFORM)/ ipapython/services.py.in \
|
||||
> ipapython/services.py; \
|
||||
touch -r ipapython/services.py.in ipapython/services.py; \
|
||||
fi
|
||||
|
||||
if [ "$(SKIP_API_VERSION_CHECK)" != "yes" ]; then \
|
||||
|
||||
@@ -20,6 +20,7 @@ AC_HEADER_STDC
|
||||
AM_CONDITIONAL([HAVE_GCC], [test "$ac_cv_prog_gcc" = yes])
|
||||
|
||||
AC_SUBST(VERSION)
|
||||
AC_SUBST([INSTALL_DATA], ['$(INSTALL) -m 644 -p'])
|
||||
|
||||
dnl ---------------------------------------------------------------------------
|
||||
dnl - Check for NSPR/NSS
|
||||
|
||||
@@ -18,6 +18,7 @@ AM_MAINTAINER_MODE
|
||||
#AC_HEADER_STDC
|
||||
|
||||
AC_SUBST(VERSION)
|
||||
AC_SUBST([INSTALL_DATA], ['$(INSTALL) -m 644 -p'])
|
||||
|
||||
AC_PROG_MKDIR_P
|
||||
AC_PROG_AWK
|
||||
|
||||
@@ -22,6 +22,7 @@ AC_HEADER_STDC
|
||||
AM_CONDITIONAL([HAVE_GCC], [test "$ac_cv_prog_gcc" = yes])
|
||||
|
||||
AC_SUBST(VERSION)
|
||||
AC_SUBST([INSTALL_DATA], ['$(INSTALL) -m 644 -p'])
|
||||
|
||||
dnl ---------------------------------------------------------------------------
|
||||
dnl - Check for KRB5
|
||||
|
||||
@@ -561,7 +561,7 @@ sides.
|
||||
base_id = DEFAULT_RANGE_SIZE + (
|
||||
pysss_murmur.murmurhash3(
|
||||
dom_sid,
|
||||
len(dom_sid), 0xdeadbeef
|
||||
len(dom_sid), 0xdeadbeefL
|
||||
) % 10000
|
||||
) * DEFAULT_RANGE_SIZE
|
||||
|
||||
|
||||
@@ -398,7 +398,7 @@ def dogtag_start_tracking(ca, nickname, pin, pinfile, secdir, pre_command,
|
||||
|
||||
if pre_command is not None:
|
||||
if not os.path.isabs(pre_command):
|
||||
if sys.maxsize > 2**32:
|
||||
if sys.maxsize > 2**32L:
|
||||
libpath = 'lib64'
|
||||
else:
|
||||
libpath = 'lib'
|
||||
@@ -408,7 +408,7 @@ def dogtag_start_tracking(ca, nickname, pin, pinfile, secdir, pre_command,
|
||||
|
||||
if post_command is not None:
|
||||
if not os.path.isabs(post_command):
|
||||
if sys.maxsize > 2**32:
|
||||
if sys.maxsize > 2**32L:
|
||||
libpath = 'lib64'
|
||||
else:
|
||||
libpath = 'lib'
|
||||
|
||||
@@ -540,7 +540,7 @@ class CertDB(object):
|
||||
/usr/lib[64]/ipa/certmonger.
|
||||
"""
|
||||
if command is not None and not os.path.isabs(command):
|
||||
if sys.maxsize > 2**32:
|
||||
if sys.maxsize > 2**32L:
|
||||
libpath = 'lib64'
|
||||
else:
|
||||
libpath = 'lib'
|
||||
|
||||
@@ -561,7 +561,7 @@ class Backup(admintool.AdminTool):
|
||||
if instance != 'PKI-IPA':
|
||||
return os.path.join('/var/lib/dirsrv', 'scripts-%s' % instance)
|
||||
else:
|
||||
if sys.maxsize > 2**32:
|
||||
if sys.maxsize > 2**32L:
|
||||
libpath = 'lib64'
|
||||
else:
|
||||
libpath = 'lib'
|
||||
|
||||
@@ -593,7 +593,7 @@ class Restore(admintool.AdminTool):
|
||||
if instance != 'PKI-IPA':
|
||||
return os.path.join('/var/lib/dirsrv', 'scripts-%s' % instance)
|
||||
else:
|
||||
if sys.maxsize > 2**32:
|
||||
if sys.maxsize > 2**32L:
|
||||
libpath = 'lib64'
|
||||
else:
|
||||
libpath = 'lib'
|
||||
|
||||
@@ -1254,7 +1254,7 @@ class test_dns(Declarative):
|
||||
|
||||
dict(
|
||||
desc='Set SOA serial of zone %r to high number' % dnszone1,
|
||||
command=('dnszone_mod', [dnszone1], {'idnssoaserial': 4294967295}),
|
||||
command=('dnszone_mod', [dnszone1], {'idnssoaserial': 4294967295L}),
|
||||
expected={
|
||||
'value': dnszone1,
|
||||
'summary': None,
|
||||
|
||||
Reference in New Issue
Block a user