Irssi core bugs

Notice: Undefined index: tasklist_type in /var/www/ : eval()'d code on line 85 Notice: Undefined index: tasklist_type in /var/www/ : eval()'d code on line 90
  • Status Researching
  • Percent Complete
  • Task Type Bug Report
  • Category core
  • Assigned To No-one
  • Operating System Mac OS
  • Severity High
  • Priority Normal
  • Reported Version Irssi 0.8.12
  • Due in Version Undecided
  • Due Date Undecided
  • Votes 0
  • Private No
Attached to Project: Irssi core bugs
Opened by Greg Leffler (gleffler) - 2007-11-03
Last edited by Geert Hauwaerts (Geert) - 2007-11-11

FS#543 - Irssi does not build on Mac OS X 10.5

`make' fails while building the Perl plugin interface on Mac OS X 10.5 with the newly-released irssi 0.8.12:

gcc -DHAVE_CONFIG_H -I. -I. -I../.. -I../../src -I../../src/core -I../../src/fe-common/core -I/sw/include/glib-2.0 -I/sw/lib/glib-2.0/include -DSCRIPTDIR=\"/usr/local/share/irssi/scripts\" -DPERL_USE_LIB=\"\" -DPERL_STATIC_LIBS=0 -arch i386 -arch ppc -g -pipe -fno-common -DPERL_DARWIN -no-cpp-precomp -fno-strict-aliasing -Wdeclaration-after-statement -I/usr/local/include -I/System/Library/Perl/5.8.8/darwin-thread-multi-2level/CORE -g -O2 -Wall -I/sw/include -MT perl-core.lo -MD -MP -MF .deps/perl-core.Tpo -c perl-core.c -fno-common -DPIC -o .libs/perl-core.o
gcc-4.0: -E, -S, -save-temps and -M options are not allowed with multiple -arch flags

I tried hacking out the "-arch ppc" argument from the PERL_CFLAGS and PERL_LINK_FLAGS in the src/perl/Makefile, as I have an Intel system and therefore don't care about the PPC arch, but then the process fails while running `lipo' (I'm assuming because it can't create the PPC executable since it didn't build it:)

Undefined symbols for architecture ppc:
"_main", referenced from:
start in crt1.10.5.o
ld: symbol(s) not found for architecture ppc
collect2: ld returned 1 exit status
lipo: can't open input file: /var/folders/x-/x-WNknFpEcCORZP4LCx53k+++TI/-Tmp-//ccDmXcZ9.out (No such file or directory)

This task does not depend on any other tasks.

Greg Leffler (gleffler)
Sunday, 04 November 2007, 00:09 GMT
Also, running:

find . -type f -exec sed -i "" -e "s/-arch ppc//g" {} \;

in the root directory of the distribution DOES successfully create an Intel version, so I must've missed a Makefile somewhere. Regardless, I think you should know :)
Jilles Tjoelker (jilles)
Sunday, 04 November 2007, 00:51 GMT
An apple site recommends passing --disable-dependency-tracking to configure,
which should stop the Makefiles trying to use -M options.
Geert Hauwaerts (Geert)
Friday, 23 November 2007, 10:34 GMT
./configure --prefix=$HOME/irssi-test --enable-perl --libdir=/sw/lib --disable-dependency-tracking --libdir=$HOME/irssi-test-lib
find . -type f -exec sed -i "" -e "s/-arch ppc//g" {} \;

make install

I tested this on "Darwin 9.1.0 Darwin Kernel Version 9.1.0: Wed Oct 31 17:46:22 PDT 2007; root:xnu-1228.0.2~1/RELEASE_I386 i386"
Sigurd Foshaug (gusto)
Wednesday, 28 November 2007, 09:05 GMT
/configure --prefix=$HOME/irssi-test --enable-perl --disable-dependency-tracking --libdir=$HOME/irssi-test-lib
find . -type f -exec sed -i "" -e "s/-arch ppc//g" {} \;

This configures fine, but fails during make:

d: warning in gui-entry.o, file is not of required architecture
ld: warning in gui-expandos.o, file is not of required architecture


ProductName: Mac OS X
ProductVersion: 10.5.1
BuildVersion: 9B18

Drakx (Drakx)
Thursday, 10 January 2008, 19:10 GMT
irssi does build under OS X 10.5 and has since the WWDC release, I wrote a script to help build it for more info also you may download this to help
Emanuele Giaquinta (ayin)
Sunday, 16 March 2008, 16:02 GMT
To build irssi on leopard configure with "ARCHFLAGS='' ./configure".
The problem is that the default value for ARCHFLAGS is "-arch i386 -arch ppc". Since it is a general problem, I am more inclined to just document it in INSTALL.
See for more information.
Cavin (charmedguy18)
Thursday, 07 January 2010, 07:55 GMT
What I did was tedious but it worked:

I used spotlight search in Finder to search for the term "ppc" in the root irssi source folder and throughout its subfolders. I then used TextMate to edit each of those files (TextMate isn't required obviously, it just is easier for multiple files than TextEdit) and remove "-arch i386 -arch pcc"... I was compiling in x86_64 by the way (./configure --build=x86_64-apple-darwin10.2.0 --disable-dependency-tracking). They were MOSTLY Makefiles, but there were some other files (such as config.status) and ONE .xs file (I think it was irssi_config.xs)... I'd look through all of them just to be sure though. It doesn't take long with ctl+f and then ctl+g searching for pcc through all the files. I am sure there's an automated way to do this, but I don't know it. Forgive me. Although, at least we know this will build x64 AND I'm pretty sure i386 with the above tips ^^....

And then I wrote this before reading emanuele's comment. I don't think his syntax is right, but yeah, I think there's the way I could have saved 20 minutes using. Either way, there we have it. -_-
Cavin (charmedguy18)
Thursday, 07 January 2010, 08:01 GMT
yep, it works
my configure was:
--build=x86_64-apple-darwin10.2.0 ARCHFLAGS="-arch x86_64"

And that's it! Thanks emanuele! lol