gtk2/gtk/gen-rc.py
Chun-wei Fan 1cd99d63d1 meson: Build the .rc files on Windows
This will ensure that the version info is easily visible from the
GDK/GTK+ DLLs, and ensure that the print dialogs will have a more modern
look and feel.
2019-04-11 16:45:36 +02:00

21 lines
515 B
Python

#! /usr/bin/env python3
# -*- coding: utf-8 -*-
import sys
import os
out_file = sys.argv[1]
in_file = sys.argv[2]
old_msvc = sys.argv[3]
with open(out_file, 'w') as o:
if old_msvc is not None and old_msvc == "1":
o.write("#define ISOLATION_AWARE_ENABLED 1\n")
o.write('#include <winuser.h>\n')
with open(in_file, 'r') as f:
for line in f:
o.write(line)
o.write('\n')
o.write('ISOLATIONAWARE_MANIFEST_RESOURCE_ID RT_MANIFEST libgtk3.manifest')