示例#1
0
    def testAddFlags(self):
        project = XcodeProject(self.obj)
        project.add_flags('flag', '-flag')

        self.assertEqual(project.objects['5'].buildSettings.flag, '-flag')
        self.assertEqual(project.objects['6'].buildSettings.flag, '-flag')
        self.assertEqual(project.objects['7'].buildSettings.flag, '-flag')
        self.assertEqual(project.objects['8'].buildSettings.flag, '-flag')
示例#2
0
    def testAddFlags(self):
        project = XcodeProject(self.obj)
        project.add_flags('flag', '-flag')

        self.assertEqual(project.objects['5'].buildSettings.flag, '-flag')
        self.assertEqual(project.objects['6'].buildSettings.flag, '-flag')
        self.assertEqual(project.objects['7'].buildSettings.flag, '-flag')
        self.assertEqual(project.objects['8'].buildSettings.flag, '-flag')
                print("Removed extra oF app resources script.")
        # if (build_phase.shellScript.startswith("COMPANY_NAME")) or (build_phase.shellScript.startswith('mkdir -p "$TARGET_BUILD_DIR/$PRODUCT_NAME.app/Contents/Resources/"')):
        #     print("found the script!")
        #     print(build_phase.shellScript)
        #     build_phase.shellScript = finalscript
        #     foundScript = True
        # else:
        #     print("this script doesn't start with companyname:", build_phase.shellScript)
        id += 1

if not foundScript:
    project.add_run_script(script=finalscript)

# adding preprocessor macros for murka

project.add_flags('GCC_PREPROCESSOR_DEFINITIONS', 'MURKA_OF')
project.add_flags('GCC_PREPROCESSOR_DEFINITIONS', 'MURKA_OFFSCREEN')

# removing extra files

project.remove_files_by_path("src/ofApp.cpp")
project.remove_files_by_path("src/ofApp.h")
project.remove_files_by_path("src/main.cpp")

# adding files

group = project.get_or_create_group('hotjuice_source')
project.add_folder(hotjuice_path + "/src", parent=group)

# add additional sources
for filePath in include_files: