LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 06-27-2015, 06:23 AM   #1
Dieselchair
LQ Newbie
 
Registered: Mar 2013
Location: /bin/bash
Distribution: Slackware
Posts: 27

Rep: Reputation: 0
Issue building gimp-normalmap-1.2.3 on slackware 14.1


Trying to add a normal map plugin to gimp but having some trouble trying to get it to build. Running 64bit Slackware 14.1 with 32bit multlibs installed. It seems like a 32bit-64bit lib issue but I'm unsure of how to get it to build.

The source for gimp-normalmap-1.2.3 is here
https://code.google.com/p/gimp-normalmap/

Just running make without editing the makefile.linux
Code:
:$ make
gcc  normalmap.o preview3d.o scale.o `pkg-config --libs gtk+-2.0 gtkglext-1.0 gimp-2.0 gimpui-2.0` -L/usr/X11R6/lib -lGLEW -o normalmap
/usr/lib64/gcc/x86_64-slackware-linux/4.8.2/../../../../x86_64-slackware-linux/bin/ld: skipping incompatible /usr/X11R6/lib/libGLU.so when searching for -lGLU
/usr/lib64/gcc/x86_64-slackware-linux/4.8.2/../../../../x86_64-slackware-linux/bin/ld: skipping incompatible /usr/X11R6/lib/libGL.so when searching for -lGL
/usr/lib64/gcc/x86_64-slackware-linux/4.8.2/../../../../x86_64-slackware-linux/bin/ld: skipping incompatible /usr/X11R6/lib/libXmu.so when searching for -lXmu
/usr/lib64/gcc/x86_64-slackware-linux/4.8.2/../../../../x86_64-slackware-linux/bin/ld: skipping incompatible /usr/X11R6/lib/libXt.so when searching for -lXt
/usr/lib64/gcc/x86_64-slackware-linux/4.8.2/../../../../x86_64-slackware-linux/bin/ld: skipping incompatible /usr/X11R6/lib/libSM.so when searching for -lSM
/usr/lib64/gcc/x86_64-slackware-linux/4.8.2/../../../../x86_64-slackware-linux/bin/ld: skipping incompatible /usr/X11R6/lib/libICE.so when searching for -lICE
/usr/lib64/gcc/x86_64-slackware-linux/4.8.2/../../../../x86_64-slackware-linux/bin/ld: skipping incompatible /usr/X11R6/lib/libX11.so when searching for -lX11
/usr/lib64/gcc/x86_64-slackware-linux/4.8.2/../../../../x86_64-slackware-linux/bin/ld: skipping incompatible /usr/X11R6/lib/libgmodule-2.0.so when searching for -lgmodule-2.0
/usr/lib64/gcc/x86_64-slackware-linux/4.8.2/../../../../x86_64-slackware-linux/bin/ld: skipping incompatible /usr/X11R6/lib/libgtk-x11-2.0.so when searching for -lgtk-x11-2.0
/usr/lib64/gcc/x86_64-slackware-linux/4.8.2/../../../../x86_64-slackware-linux/bin/ld: skipping incompatible /usr/X11R6/lib/libgdk-x11-2.0.so when searching for -lgdk-x11-2.0
/usr/lib64/gcc/x86_64-slackware-linux/4.8.2/../../../../x86_64-slackware-linux/bin/ld: skipping incompatible /usr/X11R6/lib/libatk-1.0.so when searching for -latk-1.0
/usr/lib64/gcc/x86_64-slackware-linux/4.8.2/../../../../x86_64-slackware-linux/bin/ld: skipping incompatible /usr/X11R6/lib/libgio-2.0.so when searching for -lgio-2.0
/usr/lib64/gcc/x86_64-slackware-linux/4.8.2/../../../../x86_64-slackware-linux/bin/ld: skipping incompatible /usr/X11R6/lib/libpangoft2-1.0.so when searching for -lpangoft2-1.0
/usr/lib64/gcc/x86_64-slackware-linux/4.8.2/../../../../x86_64-slackware-linux/bin/ld: skipping incompatible /usr/X11R6/lib/libpangocairo-1.0.so when searching for -lpangocairo-1.0
/usr/lib64/gcc/x86_64-slackware-linux/4.8.2/../../../../x86_64-slackware-linux/bin/ld: skipping incompatible /usr/X11R6/lib/libgdk_pixbuf-2.0.so when searching for -lgdk_pixbuf-2.0
/usr/lib64/gcc/x86_64-slackware-linux/4.8.2/../../../../x86_64-slackware-linux/bin/ld: skipping incompatible /usr/X11R6/lib/libcairo.so when searching for -lcairo
/usr/lib64/gcc/x86_64-slackware-linux/4.8.2/../../../../x86_64-slackware-linux/bin/ld: skipping incompatible /usr/X11R6/lib/libpango-1.0.so when searching for -lpango-1.0
/usr/lib64/gcc/x86_64-slackware-linux/4.8.2/../../../../x86_64-slackware-linux/bin/ld: skipping incompatible /usr/X11R6/lib/libfreetype.so when searching for -lfreetype
/usr/lib64/gcc/x86_64-slackware-linux/4.8.2/../../../../x86_64-slackware-linux/bin/ld: skipping incompatible /usr/X11R6/lib/libfontconfig.so when searching for -lfontconfig
/usr/lib64/gcc/x86_64-slackware-linux/4.8.2/../../../../x86_64-slackware-linux/bin/ld: skipping incompatible /usr/X11R6/lib/libgobject-2.0.so when searching for -lgobject-2.0
/usr/lib64/gcc/x86_64-slackware-linux/4.8.2/../../../../x86_64-slackware-linux/bin/ld: skipping incompatible /usr/X11R6/lib/libglib-2.0.so when searching for -lglib-2.0
/usr/lib64/gcc/x86_64-slackware-linux/4.8.2/../../../../x86_64-slackware-linux/bin/ld: skipping incompatible /usr/X11R6/lib/libGLEW.so when searching for -lGLEW
/usr/lib64/gcc/x86_64-slackware-linux/4.8.2/../../../../x86_64-slackware-linux/bin/ld: skipping incompatible /usr/X11R6/lib/libGLEW.a when searching for -lGLEW
/usr/lib64/gcc/x86_64-slackware-linux/4.8.2/../../../../x86_64-slackware-linux/bin/ld: skipping incompatible /usr/X11R6/lib/libgcc_s.so when searching for -lgcc_s
/usr/lib64/gcc/x86_64-slackware-linux/4.8.2/../../../../x86_64-slackware-linux/bin/ld: skipping incompatible /usr/X11R6/lib/libpthread.so when searching for -lpthread
/usr/lib64/gcc/x86_64-slackware-linux/4.8.2/../../../../x86_64-slackware-linux/bin/ld: skipping incompatible /usr/X11R6/lib/libpthread.a when searching for -lpthread
/usr/lib64/gcc/x86_64-slackware-linux/4.8.2/../../../../x86_64-slackware-linux/bin/ld: skipping incompatible /usr/X11R6/lib/libc.so when searching for -lc
/usr/lib64/gcc/x86_64-slackware-linux/4.8.2/../../../../x86_64-slackware-linux/bin/ld: skipping incompatible /usr/X11R6/lib/libc.a when searching for -lc
/usr/lib64/gcc/x86_64-slackware-linux/4.8.2/../../../../x86_64-slackware-linux/bin/ld: skipping incompatible /usr/X11R6/lib/libgcc_s.so when searching for -lgcc_s
/usr/lib64/gcc/x86_64-slackware-linux/4.8.2/../../../../x86_64-slackware-linux/bin/ld: normalmap.o: undefined reference to symbol 'sqrtf@@GLIBC_2.2.5'
/usr/lib64/gcc/x86_64-slackware-linux/4.8.2/../../../../x86_64-slackware-linux/bin/ld: note: 'sqrtf@@GLIBC_2.2.5' is defined in DSO /lib64/libm.so.6 so try adding it to the linker command line
/lib64/libm.so.6: could not read symbols: Invalid operation
collect2: error: ld returned 1 exit status
make: *** [normalmap] Error 1
Makefile.linux
Code:
GIMPTOOL=gimptool-2.0

CC=gcc
CFLAGS=-O3 -Wall `pkg-config --cflags gtk+-2.0 gtkglext-1.0 gimp-2.0`

TARGET=normalmap

OBJS=normalmap.o preview3d.o scale.o

LIBS=`pkg-config --libs gtk+-2.0 gtkglext-1.0 gimp-2.0 gimpui-2.0` \
-L/usr/X11R6/lib -lGLEW


all: $(TARGET)

$(TARGET): $(OBJS)
	$(CC) $(LDFLAGS) $(OBJS) $(LIBS) -o $(TARGET)
		 
clean:
	rm -f *.o $(TARGET)
	
install: all
	$(GIMPTOOL) --install-bin $(TARGET)
		
.c.o:
	$(CC) -c $(CFLAGS) $<
	  
normalmap.o: normalmap.c scale.h preview3d.h Makefile
preview3d.o: preview3d.c scale.h  objects/cube.h objects/quad.h \
objects/sphere.h objects/torus.h objects/teapot.h pixmaps/object.xpm \
pixmaps/light.xpm pixmaps/scene.xpm pixmaps/full.xpm Makefile
scale.o: scale.c Makefile
Thank you for any help that you can give me.
 
Old 06-27-2015, 09:19 AM   #2
Drakeo
Senior Member
 
Registered: Jan 2008
Location: Urbana IL
Distribution: Slackware, Slacko,
Posts: 3,716
Blog Entries: 3

Rep: Reputation: 483Reputation: 483Reputation: 483Reputation: 483Reputation: 483
Quote:
incompatible /usr/X11R6/lib/libpthread.a when searching for
I run into this problem all the time building stuff on my multi-lib system. some programs read the wrong pkgconfig or they are just going to run ld and then grab the first one to link to my work around for building 64 bit durring this type of situation is to rename /usr/lib to /usr/lib~ then when all done change it back or you will not have 32 bit support.
 
1 members found this post helpful.
Old 06-27-2015, 12:05 PM   #3
Dieselchair
LQ Newbie
 
Registered: Mar 2013
Location: /bin/bash
Distribution: Slackware
Posts: 27

Original Poster
Rep: Reputation: 0
Renaming /usr/lib did make a change, but it still spits out the libm.so.6 error

Code:
:$ make
gcc  normalmap.o preview3d.o scale.o `pkg-config --libs gtk+-2.0 gtkglext-1.0 gimp-2.0 gimpui-2.0` -L/usr/X11R6/lib -lGLEW  -o normalmap
/usr/lib64/gcc/x86_64-slackware-linux/4.8.2/../../../../x86_64-slackware-linux/bin/ld: normalmap.o: undefined reference to symbol 'sqrtf@@GLIBC_2.2.5'
/usr/lib64/gcc/x86_64-slackware-linux/4.8.2/../../../../x86_64-slackware-linux/bin/ld: note: 'sqrtf@@GLIBC_2.2.5' is defined in DSO /lib64/libm.so.6 so try adding it to the linker command line
/lib64/libm.so.6: could not read symbols: Invalid operation
collect2: error: ld returned 1 exit status
make: *** [normalmap] Error 1
 
Old 06-27-2015, 12:19 PM   #4
Dieselchair
LQ Newbie
 
Registered: Mar 2013
Location: /bin/bash
Distribution: Slackware
Posts: 27

Original Poster
Rep: Reputation: 0
Got it to build with
Code:
export LDFLAGS="$LDFLAGS -lm"
Thank you very much!

On a side note, it's a good thing it only installed into /root/.gimp-2.8/plug-ins

Code:
root@Deepblue:$ make install DESTDIR=/tmp/tomi/
gimptool-2.0 --install-bin normalmap
cp normalmap /root/.gimp-2.8/plug-ins
root@Deepblue:$ ls /tmp/tomi/
root@Deepblue:$ lal /tmp/tomi/
total 8
drwxr-xr-x  2 root root 4096 Jun 27 12:14 ./
drwxrwxrwt 15 root root 4096 Jun 27 12:14 ../
 
Old 06-27-2015, 01:29 PM   #5
Drakeo
Senior Member
 
Registered: Jan 2008
Location: Urbana IL
Distribution: Slackware, Slacko,
Posts: 3,716
Blog Entries: 3

Rep: Reputation: 483Reputation: 483Reputation: 483Reputation: 483Reputation: 483
yes your right looking at the Makefile.linux

here I had to re-write the Makefile.linux
here just copy paste mine. it built fine.
Code:
GIMPTOOL=gimptool-2.0

CC=gcc -lm
CFLAGS= -O2 -fPIC -Wall `pkg-config --cflags   gtk+-2.0 gtkglext-1.0 gimp-2.0 `

TARGET=normalmap

OBJS=normalmap.o preview3d.o scale.o

LIBS=`pkg-config --libs gtk+-2.0 gtkglext-1.0 gimp-2.0 gimpui-2.0` \
-L/usr/X11R6/lib64 -lGLEW

all: $(TARGET)

$(TARGET): $(OBJS)
	$(CC) $(LDFLAGS) $(OBJS) $(LIBS) -o $(TARGET)
		 
clean:
	rm -f *.o $(TARGET)
	
install: all
	$(GIMPTOOL) --install-bin $(TARGET)
		
.c.o:
	$(CC) -c $(CFLAGS) $<
	  
normalmap.o: normalmap.c scale.h preview3d.h Makefile
preview3d.o: preview3d.c scale.h  objects/cube.h objects/quad.h \
objects/sphere.h objects/torus.h objects/teapot.h pixmaps/object.xpm \
pixmaps/light.xpm pixmaps/scene.xpm pixmaps/full.xpm Makefile
scale.o: scale.c Makefile
the -lm tells the gcc compiler to use the math.h then the "-O2 -fPIC " is standard for compiling 64 bit.
then we need to use the 64 bit X11. I will put this on my git or bitbuckit and see if otheres want it.
remeber do a make clean then a make.

Last edited by Drakeo; 06-27-2015 at 02:39 PM. Reason: spelling
 
Old 06-27-2015, 02:38 PM   #6
Drakeo
Senior Member
 
Registered: Jan 2008
Location: Urbana IL
Distribution: Slackware, Slacko,
Posts: 3,716
Blog Entries: 3

Rep: Reputation: 483Reputation: 483Reputation: 483Reputation: 483Reputation: 483
Thank you for bringing this up I use gimp all the time. so here is the github with the fixes.
https://github.com/Drakeo/gimp-normalmap
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Issue with GIMP image editor venugopal59 Linux - Newbie 11 07-08-2011 02:10 AM
LXer: GIMP Painter And GIMP Paint Studio Transform GIMP Into The Ultimate Painting Tool LXer Syndicated Linux News 0 02-08-2011 06:40 PM
[SOLVED] Slackware 13 - Gimp 2.6 mobjr Slackware 8 01-27-2010 03:22 AM
GIMP on slackware 10.2 chemichael Slackware 4 02-10-2006 09:09 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 03:52 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration