ical-3.0.2: can't compile on ubuntu 12.04 32 bit

Bug #1008994 reported by Persio on 2012-06-05
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Ical
Undecided
Unassigned

Bug Description

Configure ok with:
./configure --with-tclconfig=/usr/lib/tcl8.5 --with-tkconfig=/usr/lib/tk8.5 CFLAGS=-i/usr/include/tcl8.5

When making, I got this error:
g++ -DHAVE_CONFIG_H -I. -I./types -I./time -g -O2 -MT libcalendar_a-calfile.o -MD -MP -MF .deps/libcalendar_a-calfile.Tpo -c -o libcalendar_a-calfile.o `test -f 'calendar/calfile.C' || echo './'`calendar/calfile.C
calendar/calfile.C: In function ‘int fsync(int)’:
calendar/calfile.C:30:21: error: ‘int fsync(int)’ was declared ‘extern’ and later ‘static’ [-fpermissive]
/usr/include/unistd.h:980:12: error: previous declaration of ‘int fsync(int)’ [-fpermissive]
calendar/calfile.C: In member function ‘int CalFile::WriteNew(long int)’:
calendar/calfile.C:160:31: warning: ignoring return value of ‘int link(const char*, const char*)’, declared with attribute warn_unused_result [-Wunused-result]
make[1]: *** [libcalendar_a-calfile.o] Error 1
make[1]: Leaving directory `/home/persio/temp/ical-3.0.2'
make: *** [all] Error 2

Revision history for this message
Persio (persiobarros) wrote :

Could compile with
./configure --with-tclconfig=/usr/lib/tcl8.5 --with-tkconfig=/usr/lib/tk8.5 CXXFLAGS='-g -O2 -I/usr/include/tcl8.5'
and commenting out lines 27, 29, 30 and 31 in file calfile.C

Revision history for this message
Michal Szymanski (msz-astrouw) wrote :

I did not have any problems with calfile.C on Linux Mint 13 64bit, gcc version 4.6.3 (Ubuntu/Linaro 4.6.3-1ubuntu5).

Still, I had to manually add
--with-tclconfig=/usr/lib/tcl8.5 --with-tkconfig=/usr/lib/tk8.5 CPPFLAGS=-I/usr/include/tcl8.5
to configure. I think it deserves an update to deal automatically with (apparently changed) file tree structure in Tcl/Tk 8.5.

Also, the requirement to add CPPFLAGS manually seems to be a bug - the Makefile generated even w/o this option includes
TCL_INCLUDE_SPEC = -I/usr/include/tcl8.5
line from tclConfig.sh but does not seem to use it.

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers