Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/makesdna/intern/makesdna.c')
-rw-r--r--source/blender/makesdna/intern/makesdna.c16
1 files changed, 13 insertions, 3 deletions
diff --git a/source/blender/makesdna/intern/makesdna.c b/source/blender/makesdna/intern/makesdna.c
index 114c0b40407..5156203b71f 100644
--- a/source/blender/makesdna/intern/makesdna.c
+++ b/source/blender/makesdna/intern/makesdna.c
@@ -134,7 +134,7 @@ static const char *includefiles[] = {
"DNA_lightprobe_types.h",
"DNA_curveprofile_types.h",
"DNA_xr_types.h",
- "DNA_hair_types.h",
+ "DNA_curves_types.h",
"DNA_pointcloud_types.h",
"DNA_volume_types.h",
"DNA_simulation_types.h",
@@ -1555,8 +1555,18 @@ int main(int argc, char **argv)
base_directory = BASE_HEADER;
}
+ /* NOTE: #init_structDNA() in dna_genfile.c expects `sdna->data` is 4-bytes aligned.
+ * `DNAstr[]` buffer written by `makesdna` is used for this data, so make `DNAstr` forcefully
+ * 4-bytes aligned. */
+#ifdef __GNUC__
+# define FORCE_ALIGN_4 " __attribute__((aligned(4))) "
+#else
+# define FORCE_ALIGN_4 " "
+#endif
fprintf(file_dna, "extern const unsigned char DNAstr[];\n");
- fprintf(file_dna, "const unsigned char DNAstr[] = {\n");
+ fprintf(file_dna, "const unsigned char" FORCE_ALIGN_4 "DNAstr[] = {\n");
+#undef FORCE_ALIGN_4
+
if (make_structDNA(base_directory, file_dna, file_dna_offsets, file_dna_verify)) {
/* error */
fclose(file_dna);
@@ -1626,6 +1636,7 @@ int main(int argc, char **argv)
#include "DNA_constraint_types.h"
#include "DNA_curve_types.h"
#include "DNA_curveprofile_types.h"
+#include "DNA_curves_types.h"
#include "DNA_customdata_types.h"
#include "DNA_dynamicpaint_types.h"
#include "DNA_effect_types.h"
@@ -1634,7 +1645,6 @@ int main(int argc, char **argv)
#include "DNA_freestyle_types.h"
#include "DNA_gpencil_modifier_types.h"
#include "DNA_gpencil_types.h"
-#include "DNA_hair_types.h"
#include "DNA_image_types.h"
#include "DNA_ipo_types.h"
#include "DNA_key_types.h"