Skip to contentSkip to conversation

Fix linker library order

PATCH Mathieu Desnoyers 5 participants 11 messages May 12, 2013 – May 15, 2013 8 messages not in the archive

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

Mathieu Desnoyers

author Applied
#1 lore raw
Quoted 1 line · * Francis Giraldeau ([email protected]) wrote:

Libraries must be specified after the binary target.

merged, thanks!

Mathieu

Quoted 27 lines
---
 doc/examples/demo/Makefile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
doc/examples/demo/Makefile +1 -1
index 7ae6547..bbc8ccb 100644
@@ -55,7 +55,7 @@ demo.o: demo.c
 	$(CC) $(CPPFLAGS) $(CFLAGS) -c -o $@ $<
 
 demo: demo.o
-	$(CC) -o $@ $(LIBS) $^
+	$(CC) -o $@ $^ $(LIBS)
 
 .PHONY: clean
 clean:
Signature · 7 lines
1.8.1.2


_______________________________________________
lttng-dev mailing list
[email protected]
http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev
Signature · 3 lines
Mathieu Desnoyers
EfficiOS Inc.
http://www.efficios.com

A message that is not in the archive (sent off-list or not yet received): 20130512025917.GB405@Krystal

#3 lore raw
Quoted 5 lines · Mathieu Desnoyers
Quoted 1 line · * Francis Giraldeau ([email protected]) wrote:

Libraries must be specified after the binary target.

merged, thanks!

Mathieu

This seems to have broken the daily PPA packages:
https://launchpadlibrarian.net/139804087/buildlog_ubuntu-saucy-amd64.lttng-ust_2.2~pre-0%2Bbzr1574%2Bpack37%2B201305131247~saucy1_FAILEDTOBUILD.txt.gz

That package has no particular patches. If I build it locally from source it builds fine, but if I build the package locally (with dpkg-buildpackage), I get the same error. It could be related to the --as-needed problem we've had before...

Cheers,
Alex

Quoted 27 lines
Quoted 27 lines
---
 doc/examples/demo/Makefile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
doc/examples/demo/Makefile +1 -1
index 7ae6547..bbc8ccb 100644
@@ -55,7 +55,7 @@ demo.o: demo.c
 	$(CC) $(CPPFLAGS) $(CFLAGS) -c -o $@ $<
 
 demo: demo.o
-	$(CC) -o $@ $(LIBS) $^
+	$(CC) -o $@ $^ $(LIBS)
 
 .PHONY: clean
 clean:
Signature · 7 lines
1.8.1.2


_______________________________________________
lttng-dev mailing list
[email protected]
http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev

A message that is not in the archive (sent off-list or not yet received): [email protected]

#5 lore raw
Quoted 7 lines · * Alexandre Montplaisir ([email protected]) wrote:
Quoted 5 lines · Mathieu Desnoyers
Quoted 1 line · * Francis Giraldeau ([email protected]) wrote:

Libraries must be specified after the binary target.

merged, thanks!

Mathieu

Quoted 7 lines

This seems to have broken the daily PPA packages:
https://launchpadlibrarian.net/139804087/buildlog_ubuntu-saucy-amd64.lttng-ust_2.2~pre-0%2Bbzr1574%2Bpack37%2B201305131247~saucy1_FAILEDTOBUILD.txt.gz

That package has no particular patches. If I build it locally from source it builds fine, but if I build the package locally (with dpkg-buildpackage), I get the same error. It could be related to the --as-needed problem we've had before...

Francis, can you explain why your change was needed in the first place ?

Thanks,

Mathieu

Quoted 32 lines

Cheers,
Alex

Quoted 27 lines
Quoted 27 lines
---
 doc/examples/demo/Makefile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
doc/examples/demo/Makefile +1 -1
index 7ae6547..bbc8ccb 100644
@@ -55,7 +55,7 @@ demo.o: demo.c
 	$(CC) $(CPPFLAGS) $(CFLAGS) -c -o $@ $<
 
 demo: demo.o
-	$(CC) -o $@ $(LIBS) $^
+	$(CC) -o $@ $^ $(LIBS)
 
 .PHONY: clean
 clean:
Signature · 7 lines
1.8.1.2


_______________________________________________
lttng-dev mailing list
[email protected]
http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev
Signature · 3 lines
Mathieu Desnoyers
EfficiOS Inc.
http://www.efficios.com

A message that is not in the archive (sent off-list or not yet received): 20130514065244.GA5066@Krystal

#7 lore raw
Quoted 11 lines · * Mathieu Desnoyers ([email protected]) wrote:
Quoted 10 lines · * Alexandre Montplaisir ([email protected]) wrote:
Quoted 5 lines · Mathieu Desnoyers
Quoted 1 line · * Francis Giraldeau ([email protected]) wrote:

Libraries must be specified after the binary target.

merged, thanks!

Mathieu

This seems to have broken the daily PPA packages:
https://launchpadlibrarian.net/139804087/buildlog_ubuntu-saucy-amd64.lttng-ust_2.2~pre-0%2Bbzr1574%2Bpack37%2B201305131247~saucy1_FAILEDTOBUILD.txt.gz

Quoted 6 lines
Quoted 4 lines

That package has no particular patches. If I build it locally from source it builds fine, but if I build the package locally (with dpkg-buildpackage), I get the same error. It could be related to the --as-needed problem we've had before...

Francis, can you explain why your change was needed in the first place ?

Hrm, actually, these patches are wrong.

commit 725e63c5194bfdcde0a2a3507aca156ba36cf49f for instance:

"Libraries must be specified after the binary target."

demo: demo.o
- $(CC) -o $@ $(LIBS) $^
+ $(CC) -o $@ $^ $(LIBS)

the binary target here is "$@".

$^ is the source file name (demo.c).

this patch moves the source file name prior to the libraries, which is incorrect (ref: gcc(1)). The input files should appear last.

So it breaks builds where $(LIBS) is non-empty.

I will revert commits:

commit a51ac6d9a011ba10b0be396dc1e801b2fc829651

Author: Francis Giraldeau <[email protected]>
Date:   Sat May 11 22:59:21 2013 -0400

Fix (another) linker library order

Libraries must be specified after the binary target.

commit 725e63c5194bfdcde0a2a3507aca156ba36cf49f

Author: Francis Giraldeau <[email protected]>
Date:   Sat May 11 22:58:12 2013 -0400

Fix linker library order

Libraries must be specified after the binary target.

Thanks,

Mathieu

Quoted 47 lines

Thanks,

Mathieu

Quoted 32 lines

Cheers,
Alex

Quoted 27 lines
Quoted 27 lines
---
 doc/examples/demo/Makefile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
doc/examples/demo/Makefile +1 -1
index 7ae6547..bbc8ccb 100644
@@ -55,7 +55,7 @@ demo.o: demo.c
 	$(CC) $(CPPFLAGS) $(CFLAGS) -c -o $@ $<
 
 demo: demo.o
-	$(CC) -o $@ $(LIBS) $^
+	$(CC) -o $@ $^ $(LIBS)
 
 .PHONY: clean
 clean:
Signature · 7 lines
1.8.1.2


_______________________________________________
lttng-dev mailing list
[email protected]
http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev
Signature · 8 lines
Mathieu Desnoyers
EfficiOS Inc.
http://www.efficios.com

_______________________________________________
lttng-dev mailing list
[email protected]
http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev
Signature · 3 lines
Mathieu Desnoyers
EfficiOS Inc.
http://www.efficios.com

A message that is not in the archive (sent off-list or not yet received): 20130514123724.GA24238@Krystal

#9 lore raw
Quoted 13 lines · Mathieu Desnoyers
Quoted 11 lines · * Mathieu Desnoyers ([email protected]) wrote:
Quoted 10 lines · * Alexandre Montplaisir ([email protected]) wrote:
Quoted 5 lines · Mathieu Desnoyers
Quoted 1 line · * Francis Giraldeau ([email protected]) wrote:

Libraries must be specified after the binary target.

merged, thanks!

Mathieu

This seems to have broken the daily PPA packages:
https://launchpadlibrarian.net/139804087/buildlog_ubuntu-saucy-amd64.lttng-ust_2.2~pre-0%2Bbzr1574%2Bpack37%2B201305131247~saucy1_FAILEDTOBUILD.txt.gz

Quoted 8 lines
Quoted 6 lines
Quoted 4 lines

That package has no particular patches. If I build it locally from source it builds fine, but if I build the package locally (with dpkg-buildpackage), I get the same error. It could be related to the --as-needed problem we've had before...

Francis, can you explain why your change was needed in the first place ?

Hrm, actually, these patches are wrong.

I believe these patches are correct.

Quoted 9 lines

commit 725e63c5194bfdcde0a2a3507aca156ba36cf49f for instance:

"Libraries must be specified after the binary target."

demo: demo.o

(quoted diff) +1 -1
-       $(CC) -o $@ $(LIBS) $^
+       $(CC) -o $@ $^ $(LIBS)
Quoted 8 lines

the binary target here is "$@".

$^ is the source file name (demo.c).

this patch moves the source file name prior to the libraries, which is incorrect (ref: gcc(1)). The input files should appear last.

So it breaks builds where $(LIBS) is non-empty.

Actually, $^ here is "demo.o", not "demo. Also, the libs should appear after the objects on the command line. See the "-l" section in
http://gcc.gnu.org/onlinedocs/gcc/Link-Options.html. On most setup this doesn't matter, since -Wl,--no-as-needed was the default pretty much everywhere. Ubuntu decided to use -Wl,--as-needed to avoid unnecessary dependencies, so the order becomes important. If you try to manual build on a recent Ubuntu you will get undefined references to dlopen and such. So this patch is good.

If you read carefully the log sent by Alexandre, you see that it is when building the shared libs in this directory (lttng-ust-provider-ust-tests-demo.so) that the build fails. I don't know why it fails, but Alexandre hinted that passing "-fPIE -pie" to build a shared library is weird (it is usually -fPIC -pic). I am not sure where that comes from. This behaviour only happens when building the package, not when building manually.

Quoted 87 lines

I will revert commits:

commit a51ac6d9a011ba10b0be396dc1e801b2fc829651

Author: Francis Giraldeau <[email protected]>
Date:   Sat May 11 22:59:21 2013 -0400

Fix (another) linker library order

Libraries must be specified after the binary target.

commit 725e63c5194bfdcde0a2a3507aca156ba36cf49f

Author: Francis Giraldeau <[email protected]>
Date:   Sat May 11 22:58:12 2013 -0400

Fix linker library order

Libraries must be specified after the binary target.

Thanks,

Mathieu

Quoted 43 lines

Thanks,

Mathieu

Quoted 27 lines

Cheers,
Alex

Quoted 23 lines
Quoted 23 lines
---
 doc/examples/demo/Makefile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
doc/examples/demo/Makefile +1 -2
index 7ae6547..bbc8ccb 100644
@@ -55,7 +55,7 @@ demo.o: demo.c
         $(CC) $(CPPFLAGS) $(CFLAGS) -c -o $@ $<
 
 demo: demo.o
-        $(CC) -o $@ $(LIBS) $^
+        $(CC) -o $@ $^ $(LIBS)
 
 .PHONY: clean
 clean:
--

1.8.1.2

Quoted 5 lines
Quoted 4 lines
Quoted 4 lines

_______________________________________________
lttng-dev mailing list
[email protected]
http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev

--
Mathieu Desnoyers
EfficiOS Inc.
http://www.efficios.com

Quoted 4 lines

_______________________________________________
lttng-dev mailing list
[email protected]
http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev

--
Mathieu Desnoyers
EfficiOS Inc.
http://www.efficios.com

_______________________________________________
lttng-dev mailing list
[email protected]
http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev

A message that is not in the archive (sent off-list or not yet received): CAFXXi0nvJhHiiMK_FE=_OMkT4yK+0_WLv8h=Nanvh3g0E1re3g@mail.gmail.com

#11 lore raw
Quoted 46 lines · Simon Marchi
Quoted 11 lines · Mathieu Desnoyers
Quoted 10 lines · * Mathieu Desnoyers ([email protected]) wrote:
Quoted 9 lines · * Alexandre Montplaisir ([email protected]) wrote:
Quoted 5 lines · Mathieu Desnoyers
Quoted 1 line · * Francis Giraldeau ([email protected]) wrote:

Libraries must be specified after the binary target.

merged, thanks!

Mathieu

This seems to have broken the daily PPA packages:
https://launchpadlibrarian.net/139804087/buildlog_ubuntu-saucy-amd64.lttng-ust_2.2~pre-0%2Bbzr1574%2Bpack37%2B201305131247~saucy1_FAILEDTOBUILD.txt.gz

Quoted 6 lines
Quoted 5 lines
Quoted 4 lines

That package has no particular patches. If I build it locally from source it builds fine, but if I build the package locally (with dpkg-buildpackage), I get the same error. It could be related to the --as-needed problem we've had before...

Francis, can you explain why your change was needed in the first place ?

Hrm, actually, these patches are wrong.

I believe these patches are correct.

Quoted 8 lines

commit 725e63c5194bfdcde0a2a3507aca156ba36cf49f for instance:

"Libraries must be specified after the binary target."

demo: demo.o

(quoted diff) +1 -1
-       $(CC) -o $@ $(LIBS) $^
+       $(CC) -o $@ $^ $(LIBS)
Quoted 8 lines

the binary target here is "$@".

$^ is the source file name (demo.c).

this patch moves the source file name prior to the libraries, which is incorrect (ref: gcc(1)). The input files should appear last.

So it breaks builds where $(LIBS) is non-empty.

Actually, $^ here is "demo.o", not "demo. Also, the libs should appear after the objects on the command line. See the "-l" section in
http://gcc.gnu.org/onlinedocs/gcc/Link-Options.html. On most setup this doesn't matter, since -Wl,--no-as-needed was the default pretty much everywhere. Ubuntu decided to use -Wl,--as-needed to avoid unnecessary dependencies, so the order becomes important. If you try to manual build on a recent Ubuntu you will get undefined references to dlopen and such. So this patch is good.

Quoted 7 lines

If you read carefully the log sent by Alexandre, you see that it is when building the shared libs in this directory (lttng-ust-provider-ust-tests-demo.so) that the build fails. I don't know why it fails, but Alexandre hinted that passing "-fPIE -pie" to build a shared library is weird (it is usually -fPIC -pic). I am not sure where that comes from. This behaviour only happens when building the package, not when building manually.

It seems quite right. Here is what happens with prior library order:

$ cd lttng-ust/doc/examples/demo
$ make
gcc -o demo -ldl     demo.o
demo.o: In function `__tracepoint__init_urcu_sym':
demo.c:(.text+0x20): undefined reference to `dlsym'

By inverting library order as specified in patches, the compilation succeeds:

$ make
gcc -o demo demo.o -ldl

So, reverting the patches will break the build. We should look at the other problem related to packaging and fix it.

Thanks,

Francis

_______________________________________________
lttng-dev mailing list
[email protected]
http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev

#12 lore raw
In reply to a message not in the archive
Quoted 9 lines · Simon Marchi

[...]

If you read carefully the log sent by Alexandre, you see that it is when building the shared libs in this directory (lttng-ust-provider-ust-tests-demo.so) that the build fails. I don't know why it fails, but Alexandre hinted that passing "-fPIE -pie" to build a shared library is weird (it is usually -fPIC -pic). I am not sure where that comes from. This behaviour only happens when building the package, not when building manually.

We build the daily packages with all Debian security options (this is kind of a future-proofing to find problems like this one, I don't think the "real" Debian packages use it).

See
http://wiki.debian.org/Hardening#DEB_BUILD_HARDENING_PIE_.28gcc.2Fg.2B-.2B-_-fPIE_-pie.29

So far it handled the autotools-powered Makefiles correctly (libraries are built with -fPIC, binaries with -fPIE), but it seems to cause problems with hand-written Makefiles like the one in doc/examples/demo.

We could fix it with a package-specific patch, either by using autotools to build this directory, or maybe not building it at all, since it's just an example that we don't install...

Thanks all,
Alex

A message that is not in the archive (sent off-list or not yet received): [email protected]

#14 lore raw

Francis has already submitted a patch but we could also add a "--disable-examples" switch to configure if hand-crafted Makefiles become a problem.

Quoted 34 lines · Alexandre Montplaisir
Quoted 9 lines · Simon Marchi

[...]

If you read carefully the log sent by Alexandre, you see that it is when building the shared libs in this directory (lttng-ust-provider-ust-tests-demo.so) that the build fails. I don't know why it fails, but Alexandre hinted that passing "-fPIE -pie" to build a shared library is weird (it is usually -fPIC -pic). I am not sure where that comes from. This behaviour only happens when building the package, not when building manually.

We build the daily packages with all Debian security options (this is kind of a future-proofing to find problems like this one, I don't think the "real" Debian packages use it).

See
http://wiki.debian.org/Hardening#DEB_BUILD_HARDENING_PIE_.28gcc.2Fg.2B-.2B-_-fPIE_-pie.29

So far it handled the autotools-powered Makefiles correctly (libraries are built with -fPIC, binaries with -fPIE), but it seems to cause problems with hand-written Makefiles like the one in doc/examples/demo.

We could fix it with a package-specific patch, either by using autotools to build this directory, or maybe not building it at all, since it's just an example that we don't install...

Thanks all,
Alex

_______________________________________________
lttng-dev mailing list
[email protected]
http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev

Signature · 3 lines
Jérémie Galarneau
EfficiOS Inc.
http://www.efficios.com
#15 lore raw
In reply to a message not in the archive
Quoted 18 lines · * Alexandre Montplaisir ([email protected]) wrote:
Quoted 9 lines · Simon Marchi

[...]

If you read carefully the log sent by Alexandre, you see that it is when building the shared libs in this directory (lttng-ust-provider-ust-tests-demo.so) that the build fails. I don't know why it fails, but Alexandre hinted that passing "-fPIE -pie" to build a shared library is weird (it is usually -fPIC -pic). I am not sure where that comes from. This behaviour only happens when building the package, not when building manually.

We build the daily packages with all Debian security options (this is kind of a future-proofing to find problems like this one, I don't think the "real" Debian packages use it).

See
http://wiki.debian.org/Hardening#DEB_BUILD_HARDENING_PIE_.28gcc.2Fg.2B-.2B-_-fPIE_-pie.29

Quoted 7 lines

So far it handled the autotools-powered Makefiles correctly (libraries are built with -fPIC, binaries with -fPIE), but it seems to cause problems with hand-written Makefiles like the one in doc/examples/demo.

We could fix it with a package-specific patch, either by using autotools to build this directory, or maybe not building it at all, since it's just an example that we don't install...

has this been fixed by the recent revert ?

Quoted 4 lines

Thanks all,
Alex

Signature · 3 lines
Mathieu Desnoyers
EfficiOS Inc.
http://www.efficios.com

A message that is not in the archive (sent off-list or not yet received): 20130514214608.GA9634@Krystal

#17 lore raw
Quoted 23 lines · * Mathieu Desnoyers ([email protected]) wrote:
Quoted 22 lines · * Alexandre Montplaisir ([email protected]) wrote:
Quoted 9 lines · Simon Marchi

[...]

If you read carefully the log sent by Alexandre, you see that it is when building the shared libs in this directory (lttng-ust-provider-ust-tests-demo.so) that the build fails. I don't know why it fails, but Alexandre hinted that passing "-fPIE -pie" to build a shared library is weird (it is usually -fPIC -pic). I am not sure where that comes from. This behaviour only happens when building the package, not when building manually.

We build the daily packages with all Debian security options (this is kind of a future-proofing to find problems like this one, I don't think the "real" Debian packages use it).

See
http://wiki.debian.org/Hardening#DEB_BUILD_HARDENING_PIE_.28gcc.2Fg.2B-.2B-_-fPIE_-pie.29

So far it handled the autotools-powered Makefiles correctly (libraries are built with -fPIC, binaries with -fPIE), but it seems to cause problems with hand-written Makefiles like the one in doc/examples/demo.

Quoted 5 lines
Quoted 3 lines

We could fix it with a package-specific patch, either by using autotools to build this directory, or maybe not building it at all, since it's just an example that we don't install...

has this been fixed by the recent revert ?

ok, I read the rest of my mailbox. Let's discuss this tomorrow when my head is straightened up.

Thanks,

Mathieu

Quoted 15 lines
Quoted 5 lines

Thanks all,
Alex

Signature · 8 lines
Mathieu Desnoyers
EfficiOS Inc.
http://www.efficios.com

_______________________________________________
lttng-dev mailing list
[email protected]
http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev
Signature · 3 lines
Mathieu Desnoyers
EfficiOS Inc.
http://www.efficios.com
#18 lore raw
In reply to a message not in the archive
Quoted 53 lines · * Simon Marchi ([email protected]) wrote:
Quoted 13 lines · Mathieu Desnoyers
Quoted 11 lines · * Mathieu Desnoyers ([email protected]) wrote:
Quoted 10 lines · * Alexandre Montplaisir ([email protected]) wrote:
Quoted 5 lines · Mathieu Desnoyers
Quoted 1 line · * Francis Giraldeau ([email protected]) wrote:

Libraries must be specified after the binary target.

merged, thanks!

Mathieu

This seems to have broken the daily PPA packages:
https://launchpadlibrarian.net/139804087/buildlog_ubuntu-saucy-amd64.lttng-ust_2.2~pre-0%2Bbzr1574%2Bpack37%2B201305131247~saucy1_FAILEDTOBUILD.txt.gz

Quoted 8 lines
Quoted 6 lines
Quoted 4 lines

That package has no particular patches. If I build it locally from source it builds fine, but if I build the package locally (with dpkg-buildpackage), I get the same error. It could be related to the --as-needed problem we've had before...

Francis, can you explain why your change was needed in the first place ?

Hrm, actually, these patches are wrong.

I believe these patches are correct.

Quoted 9 lines

commit 725e63c5194bfdcde0a2a3507aca156ba36cf49f for instance:

"Libraries must be specified after the binary target."

demo: demo.o

(quoted diff) +1 -1
-       $(CC) -o $@ $(LIBS) $^
+       $(CC) -o $@ $^ $(LIBS)
Quoted 8 lines

the binary target here is "$@".

$^ is the source file name (demo.c).

this patch moves the source file name prior to the libraries, which is incorrect (ref: gcc(1)). The input files should appear last.

So it breaks builds where $(LIBS) is non-empty.

Actually, $^ here is "demo.o", not "demo. Also, the libs should appear after the objects on the command line. See the "-l" section in
http://gcc.gnu.org/onlinedocs/gcc/Link-Options.html. On most setup this doesn't matter, since -Wl,--no-as-needed was the default pretty much everywhere. Ubuntu decided to use -Wl,--as-needed to avoid unnecessary dependencies, so the order becomes important. If you try to manual build on a recent Ubuntu you will get undefined references to dlopen and such. So this patch is good.

Quoted 7 lines

If you read carefully the log sent by Alexandre, you see that it is when building the shared libs in this directory (lttng-ust-provider-ust-tests-demo.so) that the build fails. I don't know why it fails, but Alexandre hinted that passing "-fPIE -pie" to build a shared library is weird (it is usually -fPIC -pic). I am not sure where that comes from. This behaviour only happens when building the package, not when building manually.

OK, I'm reverting the 2 reverts (now that's clumsy) ;-).

I'm adding your explanation to the changelog of those reverts.

Thanks,

Mathieu

Quoted 88 lines
Quoted 88 lines

I will revert commits:

commit a51ac6d9a011ba10b0be396dc1e801b2fc829651

Author: Francis Giraldeau <[email protected]>
Date:   Sat May 11 22:59:21 2013 -0400

Fix (another) linker library order

Libraries must be specified after the binary target.

commit 725e63c5194bfdcde0a2a3507aca156ba36cf49f

Author: Francis Giraldeau <[email protected]>
Date:   Sat May 11 22:58:12 2013 -0400

Fix linker library order

Libraries must be specified after the binary target.

Thanks,

Mathieu

Quoted 43 lines

Thanks,

Mathieu

Quoted 27 lines

Cheers,
Alex

Quoted 23 lines
Quoted 23 lines
---
 doc/examples/demo/Makefile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
doc/examples/demo/Makefile +1 -2
index 7ae6547..bbc8ccb 100644
@@ -55,7 +55,7 @@ demo.o: demo.c
         $(CC) $(CPPFLAGS) $(CFLAGS) -c -o $@ $<
 
 demo: demo.o
-        $(CC) -o $@ $(LIBS) $^
+        $(CC) -o $@ $^ $(LIBS)
 
 .PHONY: clean
 clean:
--

1.8.1.2

Quoted 5 lines
Quoted 4 lines
Quoted 4 lines

_______________________________________________
lttng-dev mailing list
[email protected]
http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev

--
Mathieu Desnoyers
EfficiOS Inc.
http://www.efficios.com

Quoted 4 lines

_______________________________________________
lttng-dev mailing list
[email protected]
http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev

--
Mathieu Desnoyers
EfficiOS Inc.
http://www.efficios.com

_______________________________________________
lttng-dev mailing list
[email protected]
http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev

Signature · 3 lines
Mathieu Desnoyers
EfficiOS Inc.
http://www.efficios.com