{"action":"created","issue":{"url":"https://api.github.com/repos/swig/swig/issues/394","labels_url":"https://api.github.com/repos/swig/swig/issues/394/labels{/name}","comments_url":"https://api.github.com/repos/swig/swig/issues/394/comments","events_url":"https://api.github.com/repos/swig/swig/issues/394/events","html_url":"https://github.com/swig/swig/issues/394","id":70732324,"number":394,"title":"%ignore for preprocessor or command line arg to ignore unknown preprocessor directive?","user":{"login":"danomatika","id":480637,"avatar_url":"https://avatars.githubusercontent.com/u/480637?v=3","gravatar_id":"","url":"https://api.github.com/users/danomatika","html_url":"https://github.com/danomatika","followers_url":"https://api.github.com/users/danomatika/followers","following_url":"https://api.github.com/users/danomatika/following{/other_user}","gists_url":"https://api.github.com/users/danomatika/gists{/gist_id}","starred_url":"https://api.github.com/users/danomatika/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/danomatika/subscriptions","organizations_url":"https://api.github.com/users/danomatika/orgs","repos_url":"https://api.github.com/users/danomatika/repos","events_url":"https://api.github.com/users/danomatika/events{/privacy}","received_events_url":"https://api.github.com/users/danomatika/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2015-04-24T16:24:25Z","updated_at":"2015-04-30T01:41:39Z","closed_at":"2015-04-30T01:41:39Z","body":"EDIT: I'm using SWIG 3.0.5.\r\n\r\nI'm wrapping a C++ library that includes conditional Obj-C++ preprocessor file #imports (aka Obj-C specific \"#include\") in a C++ header. As of SWIG 3.0.3 & the fix for #217, generating wrappers with SWIG now fails due to:\r\n\r\n    ../../../libs/openFrameworks/utils/ofConstants.h:199: Error: Unknown SWIG preprocessor directive: import (if this is a block of target language code, delimit it with %{ and %})\r\n    ../../../libs/openFrameworks/utils/ofConstants.h:200: Error: Unknown SWIG preprocessor directive: import (if this is a block of target language code, delimit it with %{ and %})\r\n    ../../../libs/openFrameworks/utils/ofConstants.h:202: Error: Unknown SWIG preprocessor directive: import (if this is a block of target language code, delimit it with %{ and %})\r\n    ../../../libs/openFrameworks/utils/ofConstants.h:203: Error: Unknown SWIG preprocessor directive: import (if this is a block of target language code, delimit it with %{ and %})\r\n\r\nin the following file: [ofConstants.h](https://github.com/openframeworks/openFrameworks/blob/master/libs/openFrameworks/utils/ofConstants.h#L209).\r\n\r\nIs there some way to tell the SWIG preprocessor to ignore \"#import\"? I've been looking through the documentation but haven't found anything yet. Also, is there a command line argument to reenable the \"silently ignore unknown preprocessor directives\" behavior? The generated wrappers are working fine from versions of SWIG before 3.0.3.\r\n\r\nThanks!"},"comment":{"url":"https://api.github.com/repos/swig/swig/issues/comments/97629929","html_url":"https://github.com/swig/swig/issues/394#issuecomment-97629929","issue_url":"https://api.github.com/repos/swig/swig/issues/394","id":97629929,"user":{"login":"ojwb","id":164061,"avatar_url":"https://avatars.githubusercontent.com/u/164061?v=3","gravatar_id":"","url":"https://api.github.com/users/ojwb","html_url":"https://github.com/ojwb","followers_url":"https://api.github.com/users/ojwb/followers","following_url":"https://api.github.com/users/ojwb/following{/other_user}","gists_url":"https://api.github.com/users/ojwb/gists{/gist_id}","starred_url":"https://api.github.com/users/ojwb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ojwb/subscriptions","organizations_url":"https://api.github.com/users/ojwb/orgs","repos_url":"https://api.github.com/users/ojwb/repos","events_url":"https://api.github.com/users/ojwb/events{/privacy}","received_events_url":"https://api.github.com/users/ojwb/received_events","type":"User","site_admin":false},"created_at":"2015-04-30T01:41:39Z","updated_at":"2015-04-30T01:41:39Z","body":"Fixed in d26a505dad5fce497364a1d04ee3fb9bc9f122a8."}}