I had some problems with C++ typedef such as ptrdiff_t using xcode command line tools version 2384. My gcc is 4.2.1 and my clang is 12.0.5.
In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/c++/v1/memory:674:
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/c++/v1/iterator:562:13: error: unknown type name 'ptrdiff_t'
typedef ptrdiff_t difference_type;
Since I am out of ideas on how to solve it, I wanted to hear from you if you faced a similar problem or if you want to share a line of thought about it, I would be glad to read it.
Waf: Leaving directory `/Users/nath/workspace/ns-3-allinone/ns-3.33/build'
Build commands will be stored in build/compile_commands.json
'build' finished successfully (3m26.110s)
Leaving directory `/Users/nath/workspace/ns-3-allinone/./ns-3.33'
% ./waf --run hello-simulator
Waf: Entering directory `/Users/nath/workspace/ns-3-allinone/ns-3.33/build'
Waf: Leaving directory `/Users/nath/workspace/ns-3-allinone/ns-3.33/build'
Build commands will be stored in build/compile_commands.json
'build' finished successfully (0.507s)
Hello Simulator
BTW, how i can apply the patch file you have provided above?
Output:
Entering directory `/Users/abcd/ns-allinone-3.32/./ns-3.32'
=> /usr/local/opt/pyt...@3.11/bin/python3.11 waf configure --enable-examples --enable-tests --with-pybindgen ../pybindgen-0.21.0
Waf: The wscript in '/Users/abcd/ns-allinone-3.32/ns-3.32' is unreadable
Traceback (most recent call last):
File "/Users/abcd/ns-allinone-3.32/ns-3.32/.waf3-2.0.18-ff4ae9f5cc05353d3dc3aeff8854ae69/waflib/Scripting.py", line 102, in waf_entry_point
set_main_module(wscript)
File "/Users/abcd/ns-allinone-3.32/ns-3.32/.waf3-2.0.18-ff4ae9f5cc05353d3dc3aeff8854ae69/waflib/Scripting.py", line 142, in set_main_module
Context.g_module=Context.load_module(file_path)