tmate-io / tmate

Instant Terminal Sharing

Home Page:https://tmate.io/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

`-Wno-null-pointer-arithmetic` should not be used with GCC

barracuda156 opened this issue · comments

gcc-4.2 errs out on this:

--->  Building tmate
Executing:  cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_sysutils_tmate/tmate/work/tmate-2.4.0" && /usr/bin/make -j6 -w all 
make: Entering directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_sysutils_tmate/tmate/work/tmate-2.4.0'
  CC       alerts.o
  CC       arguments.o
  CC       attributes.o
  CC       cfg.o
  CC       client.o
  CC       cmd-attach-session.o
cc1: error: unrecognized command line option "-Wno-null-pointer-arithmetic"
cc1: error: unrecognized command line option "-Wno-null-pointer-arithmetic"
cc1: error: unrecognized command line option "-Wno-null-pointer-arithmetic"
cc1: error: unrecognized command line option "-Wno-null-pointer-arithmetic"
make: *** [arguments.o] Error 1

But otherwise builds it, when flag is removed.

gcc-13.2.0 does not err out, but does not recognize the flag either, showing a warning.

There are also a number of warnings during the build:

  CC       tmate-env.o
tmate-encoder.c: In function ‘tmate_write_uname’:
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:25: warning: called from here
tmate-encoder.c: In function ‘tmate_write_header’:
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:11: warning: called from here
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:12: warning: called from here
tmate-encoder.c: In function ‘tmate_write_ready’:
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:36: warning: called from here
tmate-encoder.c: In function ‘tmate_status’:
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:294: warning: called from here
  CC       tmate-msg.o
tmate-encoder.c: In function ‘tmate_failed_cmd’:
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:280: warning: called from here
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:281: warning: called from here
tmate-encoder.c: In function ‘__tmate_exec_cmd_args’:
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:247: warning: called from here
  CC       tmate-msgpack.o
  CC       tmate-session.o
  CC       tmux.o
tmate-encoder.c: In function ‘tmate_pty_data’:
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:139: warning: called from here
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:140: warning: called from here
tmate-encoder.c: In function ‘tmate_sync_layout’:
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:78: warning: called from here
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:80: warning: called from here
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:81: warning: called from here
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:96: warning: called from here
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:106: warning: called from here
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:107: warning: called from here
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:108: warning: called from here
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:109: warning: called from here
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:110: warning: called from here
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:118: warning: called from here
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:124: warning: called from here
  CC       tty-acs.o
tmate-encoder.c: In function ‘tmate_send_reconnection_state’:
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:469: warning: called from here
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:436: warning: called from here
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:408: warning: called from here
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:413: warning: called from here
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:414: warning: called from here
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:419: warning: called from here
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:420: warning: called from here
  CC       tty-keys.o
tmate-encoder.c: In function ‘tmate_write_fin’:
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:354: warning: called from here
tmate-encoder.c: In function ‘tmate_write_copy_mode’:
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:346: warning: called from here
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:347: warning: called from here
tmate-encoder.c: In function ‘tmate_sync_copy_mode’:
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:309: warning: called from here
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:311: warning: called from here
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:319: warning: called from here
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:321: warning: called from here
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:322: warning: called from here
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:323: warning: called from here
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:327: warning: called from here
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:328: warning: called from here
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:330: warning: called from here
/opt/local/include/msgpack/pack_template.h:437: warning: inlining failed in call to ‘msgpack_pack_int’: --param max-inline-insns-single limit reached
tmate-encoder.c:336: warning: called from here
  CC       tty-term.o
  CC       tty.o
  CC       utf8.o
  CC       window-choose.o
  CC       window-clock.o
  CC       window-copy.o
  CC       window.o
  CC       xmalloc.o
  CC       xterm-keys.o
  CC       osdep-darwin.o
  CC       compat/imsg.o
  CC       compat/closefrom.o
  CC       compat/imsg-buffer.o
  CC       compat/vis.o
  CC       compat/unvis.o
  CC       compat/strtonum.o
  CC       compat/openat.o
  CC       compat/reallocarray.o
compat/openat.c: In function ‘openat’:
compat/openat.c:33: warning: ‘mode_t’ is promoted to ‘int’ when passed through ‘...’
compat/openat.c:33: warning: (so you should pass ‘int’ not ‘mode_t’ to ‘va_arg’)
compat/openat.c:33: note: if this code is reached, the program will abort
  CCLD     tmate
ld: warning: directory 'lib' following -L not found

Not sure if these are of concern.