title: error: initializer element is not a compile-time constant
body: <p>I have been looking for answers but could not find anything to make this code run. I get <code>av[1]</code> highlighted by the compiler in the main function when declaring:</p>
  
  <pre><code>static char const *str = av[1];
  </code></pre>
  
  <p>Here is the code I tried to run with gcc:</p>
  
  <pre><code>#include &lt;stdio.h&gt;
  #include &lt;stdlib.h&gt;
  
  char    *ft_strjoin(char const *s1, char const *s2);
  
  void    fct(char **av)
  {
      static char const *str = av[1];
      str = ft_strjoin(av[1], av[1]);
      printf("%s\n", str);
  }
  
  int main(int ac, char **av)
  {
      fct(&amp;av[1]);
      fct(&amp;av[1]);
      fct(&amp;av[1]);
      fct(&amp;av[1]);
      fct(&amp;av[1]);
      fct(&amp;av[1]);
  }
  </code></pre>
  
  <p>I found <a href="https://groups.google.com/forum/embed/#!topic/comp.std.c/PPzxWT_Sxt0" rel="noreferrer">this</a>  interesting but I still don't get it and don't know how to run this code. </p>