[MacPorts] #65561: Need help with Port - unalz

MacPorts noreply at macports.org
Fri Jul 29 00:21:27 UTC 2022


#65561: Need help with Port - unalz
---------------------+--------------------
  Reporter:  RobK88  |      Owner:  (none)
      Type:  defect  |     Status:  new
  Priority:  Normal  |  Milestone:
 Component:  ports   |    Version:  2.7.2
Resolution:          |   Keywords:
      Port:  unalz   |
---------------------+--------------------
Description changed by RobK88:

Old description:

> I need some help with fixing an old and abandoned port -- unalz.
>
> It is broken in Macports.  I have fixed the port and it will build on
> most systems just fine. One big step forward.
>
> But on older Mac systems, I get the dreaded `unalz is using libstdc++
> (this installation is configured to use libc++)`.
>
> I have patched the Makefile accordingly so the CFLAGS, CXXFLAGS and
> LDFLAGS set by Macports are honoured and appended to the flags in the
> Makefile.
>
> But it looks like the default compiler on old Macs (e.g. g++ 4.2 on Lion)
> does not understand the `-stdlib=libc++` flag.  e.g. `cc1plus: error:
> unrecognized command line option "-stdlib=libc++"`
>
> Of course, I can get around this by specifying `configure.compiler
> =macports-clang-9.0` when installing or upgrading this port using
> macports.
>
> Attached is the patched Makefile and the draft portfile. (I know I need
> to fix the formatting etc in the draft portfile).
>
> Any help would be greatly appreciated.
> Is there a way to get the old Apple compilers to understand
> "-stdlib=libc++"?
> Maybe I need to specify the compiler in the portfile. e.g. clang-9.0 or
> greater.  How would I do that?
>
> P.S. As recently as 2015, the Debian Project has fixed a number of bugs
> (including buffer overflow bugs) in unalz.  I will need to add the Debian
> patches to this portfile.   But I want to address the compiler and stdc++
> issue first.  See https://sources.debian.org/patches/unalz/0.65-8/ and
> https://packages.debian.org/source/stable/unalz

New description:

 I need some help with fixing an old and abandoned port -- unalz.

 It is broken in Macports.  I have fixed the port and it will build on most
 systems just fine. One big step forward.

 But on older Mac systems, I get the dreaded `unalz is using libstdc++
 (this installation is configured to use libc++)`.

 I have patched the Makefile accordingly so the CFLAGS, CXXFLAGS and
 LDFLAGS set by Macports are honoured and appended to the flags in the
 Makefile.

 I can tell that "-stdlib=libc++" command line option is being passed to
 the compiler.  But it looks like the default compiler on old Macs (e.g.
 g++ 4.2 on Lion) does not understand the `-stdlib=libc++` command line
 option.  e.g. `cc1plus: error: unrecognized command line option
 "-stdlib=libc++"`

 Of course, I can get around this by specifying `configure.compiler
 =macports-clang-9.0` when installing or upgrading this port using
 macports.

 Attached is the patched Makefile and the draft portfile. (I know I need to
 fix the formatting etc in the draft portfile).

 Any help would be greatly appreciated.
 Is there a way to get the old Apple compilers to understand the
 "-stdlib=libc++" command line option?
 Maybe I need to specify the compiler in the portfile. e.g. clang-9.0 or
 greater.  How would I do that?

 P.S. As recently as 2015, the Debian Project has fixed a number of bugs
 (including buffer overflow bugs) in unalz.  I will need to add the Debian
 patches to this portfile.   But I want to address the compiler and stdc++
 issue first.  See https://sources.debian.org/patches/unalz/0.65-8/ and
 https://packages.debian.org/source/stable/unalz

--

-- 
Ticket URL: <https://trac.macports.org/ticket/65561#comment:4>
MacPorts <https://www.macports.org/>
Ports system for macOS


More information about the macports-tickets mailing list