fmw42 wrote:have you tried a smaller jpg or some other image type such as gif or png?
do you have enough memory?
are the permission set to write for the directory you are using to save the jpg?
did you check for any errors in the compile of libjpeg or IM or check the config.log for errors?
1. Haven't tried a smaller image, I can try to locate something else to try and test it.
2. Plenty of memory, system has 1.5G available, OS is using some of it for buffers, but it shouldn't be an issue. The old version (OS provided) worked just fine.
3. Permissions are not an issue, I'm converting from files owned by me in my home directory to files converted by me in my home directory. chown -R works wonders for straightening out trivial issues like permissions.
4. Config.log on libjpeg showed:
configure:7544: ./conftest
configure:7548: $? = 1
configure: program exited with status 1
configure: failed program was:
| /* confdefs.h. */
| #define PACKAGE_NAME "libjpeg"
| #define PACKAGE_TARNAME "libjpeg"
| #define PACKAGE_VERSION "7.0"
| #define PACKAGE_STRING "libjpeg 7.0"
| #define PACKAGE_BUGREPORT ""
| #define PACKAGE "libjpeg"
| #define VERSION "7.0"
| #define PROTOTYPES 1
| #define __PROTOTYPES 1
| #define STDC_HEADERS 1
| #define HAVE_SYS_TYPES_H 1
| #define HAVE_SYS_STAT_H 1
| #define HAVE_STDLIB_H 1
| #define HAVE_STRING_H 1
| #define HAVE_MEMORY_H 1
| #define HAVE_STRINGS_H 1
| #define HAVE_INTTYPES_H 1
| #define HAVE_STDINT_H 1
| #define HAVE_UNISTD_H 1
| #define HAVE_STRING_H 1
| #define HAVE_PROTOTYPES 1
| #define HAVE_STDDEF_H 1
| #define HAVE_STDLIB_H 1
| #define HAVE_LOCALE_H 1
| #define HAVE_UNSIGNED_CHAR 1
| #define HAVE_UNSIGNED_SHORT 1
| #define INLINE __inline__
| /* end confdefs.h. */
|
| #ifdef HAVE_PROTOTYPES
| int is_shifting_signed (long arg)
| #else
| int is_shifting_signed (arg)
| long arg;
| #endif
| /* See whether right-shift on a long is signed or not. */
| {
| long res = arg >> 4;
|
| if (res == -0x7F7E80CL) { /* expected result for signed shift */
| return 1; /* right shift is signed */
| }
| /* see if unsigned-shift hack will fix it. */
| /* we can't just test exact value since it depends on width of long... */
| res |= (~0L) << (32-4);
| if (res == -0x7F7E80CL) { /* expected result now? */
| return 0; /* right shift is unsigned */
| }
| printf("Right shift isn't acting as I expect it to.\n");
| printf("I fear the JPEG software will not work at all.\n\n");
| return 0; /* try it with unsigned anyway */
| }
| int main() {
| exit(is_shifting_signed(-0x7F7E80B1L));
| }
It seemed to build anyway, and configure did not fail, neither did make test:
make[1]: Leaving directory `/usr/local/src/jpeg-7'
[root@pythagoras jpeg-7]# make test
rm -f testout*
./djpeg -dct int -ppm -outfile testout.ppm ./testorig.jpg
./djpeg -dct int -bmp -colors 256 -outfile testout.bmp ./testorig.jpg
./cjpeg -dct int -outfile testout.jpg ./testimg.ppm
./djpeg -dct int -ppm -outfile testoutp.ppm ./testprog.jpg
./cjpeg -dct int -progressive -opt -outfile testoutp.jpg ./testimg.ppm
./jpegtran -outfile testoutt.jpg ./testprog.jpg
cmp ./testimg.ppm testout.ppm
cmp ./testimg.bmp testout.bmp
cmp ./testimg.jpg testout.jpg
cmp ./testimg.ppm testoutp.ppm
cmp ./testimgp.jpg testoutp.jpg
cmp ./testorig.jpg testoutt.jpg
[root@pythagoras jpeg-7]#
Interestingly though, I get another (fatal?) seemingly non-fatal error from configure for IM 6.5.6-9:
conftest.c:58: error: expected ';', ',' or ')' before 'text'
conftest.c: In function 'main':
conftest.c:112: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'newvar'
conftest.c:112: error: 'newvar' undeclared (first use in this function)
conftest.c:112: error: (Each undeclared identifier is reported only once
conftest.c:112: error: for each function it appears in.)
conftest.c:122: error: 'for' loop initial declaration used outside C99 mode
configure:4622: $? = 1
configure: failed program was:
| /* confdefs.h. */
| #define PACKAGE_NAME "ImageMagick"
And another:
conftest.c:8:28: error: ac_nonexistent.h: No such file or directory
configure:4889: $? = 1
configure: failed program was:
| /* confdefs.h. */
None of these seemed to indicate there was a fatal error of any type, and continued to build seemingly appropriately.
Peter