bpo-26836: Add ifdefs for all MFD_HUGE* constants (GH-13666)

https://bugs.python.org/issue26836
This commit is contained in:
Zackery Spytz 2019-05-29 14:43:50 -06:00 committed by Miss Islington (bot)
parent ada319bb6d
commit e70bfa95e6
1 changed files with 28 additions and 0 deletions

View File

@ -14046,19 +14046,47 @@ all_ins(PyObject *m)
if (PyModule_AddIntMacro(m, MFD_ALLOW_SEALING)) return -1; if (PyModule_AddIntMacro(m, MFD_ALLOW_SEALING)) return -1;
#ifdef MFD_HUGETLB #ifdef MFD_HUGETLB
if (PyModule_AddIntMacro(m, MFD_HUGETLB)) return -1; if (PyModule_AddIntMacro(m, MFD_HUGETLB)) return -1;
#endif
#ifdef MFD_HUGE_SHIFT
if (PyModule_AddIntMacro(m, MFD_HUGE_SHIFT)) return -1; if (PyModule_AddIntMacro(m, MFD_HUGE_SHIFT)) return -1;
#endif
#ifdef MFD_HUGE_MASK
if (PyModule_AddIntMacro(m, MFD_HUGE_MASK)) return -1; if (PyModule_AddIntMacro(m, MFD_HUGE_MASK)) return -1;
#endif
#ifdef MFD_HUGE_64KB
if (PyModule_AddIntMacro(m, MFD_HUGE_64KB)) return -1; if (PyModule_AddIntMacro(m, MFD_HUGE_64KB)) return -1;
#endif
#ifdef MFD_HUGE_512KB
if (PyModule_AddIntMacro(m, MFD_HUGE_512KB)) return -1; if (PyModule_AddIntMacro(m, MFD_HUGE_512KB)) return -1;
#endif
#ifdef MFD_HUGE_1MB
if (PyModule_AddIntMacro(m, MFD_HUGE_1MB)) return -1; if (PyModule_AddIntMacro(m, MFD_HUGE_1MB)) return -1;
#endif
#ifdef MFD_HUGE_2MB
if (PyModule_AddIntMacro(m, MFD_HUGE_2MB)) return -1; if (PyModule_AddIntMacro(m, MFD_HUGE_2MB)) return -1;
#endif
#ifdef MFD_HUGE_8MB
if (PyModule_AddIntMacro(m, MFD_HUGE_8MB)) return -1; if (PyModule_AddIntMacro(m, MFD_HUGE_8MB)) return -1;
#endif
#ifdef MFD_HUGE_16MB
if (PyModule_AddIntMacro(m, MFD_HUGE_16MB)) return -1; if (PyModule_AddIntMacro(m, MFD_HUGE_16MB)) return -1;
#endif
#ifdef MFD_HUGE_32MB
if (PyModule_AddIntMacro(m, MFD_HUGE_32MB)) return -1; if (PyModule_AddIntMacro(m, MFD_HUGE_32MB)) return -1;
#endif
#ifdef MFD_HUGE_256MB
if (PyModule_AddIntMacro(m, MFD_HUGE_256MB)) return -1; if (PyModule_AddIntMacro(m, MFD_HUGE_256MB)) return -1;
#endif
#ifdef MFD_HUGE_512MB
if (PyModule_AddIntMacro(m, MFD_HUGE_512MB)) return -1; if (PyModule_AddIntMacro(m, MFD_HUGE_512MB)) return -1;
#endif
#ifdef MFD_HUGE_1GB
if (PyModule_AddIntMacro(m, MFD_HUGE_1GB)) return -1; if (PyModule_AddIntMacro(m, MFD_HUGE_1GB)) return -1;
#endif
#ifdef MFD_HUGE_2GB
if (PyModule_AddIntMacro(m, MFD_HUGE_2GB)) return -1; if (PyModule_AddIntMacro(m, MFD_HUGE_2GB)) return -1;
#endif
#ifdef MFD_HUGE_16GB
if (PyModule_AddIntMacro(m, MFD_HUGE_16GB)) return -1; if (PyModule_AddIntMacro(m, MFD_HUGE_16GB)) return -1;
#endif #endif
#endif #endif