Description of Problem: mysql is built with these extra flags: -O2 -fsigned-char -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE But only -D_GNU_SOURCE is used is used while compiling db3 in the bdb directory. Besides the missing optimization, linking together objects with different notions of eg. off_t scares me. Version-Release number of selected component (if applicable): 3.23.49-2 How Reproducible: Always Steps to Reproduce: 1. rpmbuild --rebuild mysql-3.23.49-2.src.rpm 2. 3. Actual Results: Expected Results: Additional Information:
The regression tests on bdb succeeds with the current set of flags, and it seems to work fine with manual tests, too. The tests for bdb fail when I trick it into using these flags, so I won't do that for now. (adding CPPFLAGS do the trick)
Would you mind telling me which bdb regression tests fail? I'm tracking a strange failure (bdb-deadlock aborts the server) on PPC.
Created attachment 52811 [details] Fix gcc-2.96 miscompilation of db3
Ah, I remember now. This is most probably a miscompilation by gcc-2.96-109, a patch went into gcc-3.0.3. Recompile gcc-2.96-109 with the attached patch and then recompile mysql with it. Hmm, I wonder why Jakub didn't apply the patch to gcc-2.96, I notified him back then. Cause even if mysql is currently not affected because it builds db3 with optimization, the standalone db3 package is still affected.
Bugs/patches against gcc need to be filed against gcc.... building mysql now to find out which test failed, I overwrite those logfiles ('foo' isn't exactly intended for long time storage :).
analyse 0.01 0.04 0.06 [ pass ] auto_increment 0.03 0.02 0.08 [ pass ] backup 0.02 0.02 0.07 [ pass ] bdb-crash 0.02 0.04 0.22 [ pass ] bdb-deadlock 0.02 0.02 0.23 [ pass ] bdb .... .... .... [ fail ] >> Error at line 129: query 'insert into t1 values (4)' failed: 1062: Duplicate entry '4' for key 1 << Aborting. To continue, re-run with '--force'. Ending Tests
Could you please retry with gcc-2.96-110 yourself? It works for me now with the appended patch (the lazy configure-only patch :-) ) to mysql.
Created attachment 53746 [details] Correctly handle CFLAGS during configure in mysql/bdb