Xcode Build Settings based on makefile

  • I have a makefile that successfully compiles and links without error, and
    I'm trying to accomplish the same thing by using the proper Build Settings
    in Xcode. So far I've been unsuccessful. Can this forum be used to help me
    with solve this problem?
  • On Apr 14, 2013, at 11:37 PM, Paul Johnson wrote:

    > I have a makefile that successfully compiles and links without error, and I'm trying to accomplish the same thing by using the proper Build Settings in Xcode. So far I've been unsuccessful. Can this forum be used to help me with solve this problem?

    You could have Xcode use the Makefile itself.  As long as you implement some specific target names (build, clean, etc), it should integrate nicely.  Add a new target, use "External Build System", and select 'make'.

    HTH -
    Andrew Keller
  • Thanks, Andrew. I'll look at just using the makefile. However,
    theoretically it should be easy to just do the compile/link without
    resorting to make. It just seems more aesthetically pleasing to not have to
    mess with additional tools unnecessarily.

    On Sun, Apr 14, 2013 at 10:37 PM, Paul Johnson <paul...> wrote:

    > I have a makefile that successfully compiles and links without error, and
    > I'm trying to accomplish the same thing by using the proper Build Settings
    > in Xcode. So far I've been unsuccessful. Can this forum be used to help me
    > with solve this problem?
    >
  • I've done the opposite (gone from Xcode build to makefile build) in a cross platform project. Xcode is good in that everything it does during the build can be replicated on the command line, so I suggest, if you are set on doing this, that you compare closely the command line generated from the makefile with the command line generated by Xcode (you can expand the build output so it shows the full commands).

    If the project is small it shouldn't be hard to switch between them, larger projects however…

    Good luck!

    Nick

    On 16/04/2013, at 6:38 AM, Paul Johnson wrote:

    Thanks, Andrew. I'll look at just using the makefile. However, theoretically it should be easy to just do the compile/link without resorting to make. It just seems more aesthetically pleasing to not have to mess with additional tools unnecessarily.

    On Sun, Apr 14, 2013 at 10:37 PM, Paul Johnson <paul...><mailto:<paul...>> wrote:
    I have a makefile that successfully compiles and links without error, and I'm trying to accomplish the same thing by using the proper Build Settings in Xcode. So far I've been unsuccessful. Can this forum be used to help me with solve this problem?
  • Thanks, Nick. Can you tell me how to expand Xcode output so it shows the
    full commands. (I've added a "-v" switch but that doesn't quite do it.)

    On Mon, Apr 15, 2013 at 4:44 PM, Nick Blievers
    <nblievers...>wrote:

    > I've done the opposite (gone from Xcode build to makefile build) in a
    > cross platform project. Xcode is good in that everything it does during the
    > build can be replicated on the command line, so I suggest, if you are set
    > on doing this, that you compare closely the command line generated from the
    > makefile with the command line generated by Xcode (you can expand the build
    > output so it shows the full commands).
    >
    > If the project is small it shouldn't be hard to switch between them,
    > larger projects however…
    >
    >
    >
    > Good luck!
    >
    > Nick
    >
    > On 16/04/2013, at 6:38 AM, Paul Johnson wrote:
    >
    > Thanks, Andrew. I'll look at just using the makefile. However,
    > theoretically it should be easy to just do the compile/link without
    > resorting to make. It just seems more aesthetically pleasing to not have to
    > mess with additional tools unnecessarily.
    >
    >
    > On Sun, Apr 14, 2013 at 10:37 PM, Paul Johnson <paul...> wrote:
    >
    >> I have a makefile that successfully compiles and links without error, and
    >> I'm trying to accomplish the same thing by using the proper Build Settings
    >> in Xcode. So far I've been unsuccessful. Can this forum be used to help me
    >> with solve this problem?
    >>
    >
    > _______________________________________________
    > Do not post admin requests to the list. They will be ignored.
    > Xcode-users mailing list      (<Xcode-users...>)
    > Help/Unsubscribe/Update your Subscription:
    >
    > https://lists.apple.com/mailman/options/xcode-users/<nblievers...>
    x.com

    >
    > This email sent to <nblievers...>
    >
    >
    >
  • If you click on the log navigator, and select a build and select a "Compile filename.c" line, you can expand this using the icon on the far right, you should then see the full compile line (it will be long!).

    Nick

    On 16/04/2013, at 10:41 AM, Paul Johnson wrote:

    Thanks, Nick. Can you tell me how to expand Xcode output so it shows the full commands. (I've added a "-v" switch but that doesn't quite do it.)

    On Mon, Apr 15, 2013 at 4:44 PM, Nick Blievers <nblievers...><mailto:<nblievers...>> wrote:
    I've done the opposite (gone from Xcode build to makefile build) in a cross platform project. Xcode is good in that everything it does during the build can be replicated on the command line, so I suggest, if you are set on doing this, that you compare closely the command line generated from the makefile with the command line generated by Xcode (you can expand the build output so it shows the full commands).

    If the project is small it shouldn't be hard to switch between them, larger projects however…

    Good luck!

    Nick

    On 16/04/2013, at 6:38 AM, Paul Johnson wrote:

    Thanks, Andrew. I'll look at just using the makefile. However, theoretically it should be easy to just do the compile/link without resorting to make. It just seems more aesthetically pleasing to not have to mess with additional tools unnecessarily.

    On Sun, Apr 14, 2013 at 10:37 PM, Paul Johnson <paul...><mailto:<paul...>> wrote:
    I have a makefile that successfully compiles and links without error, and I'm trying to accomplish the same thing by using the proper Build Settings in Xcode. So far I've been unsuccessful. Can this forum be used to help me with solve this problem?
  • This isn't impossible as I've done it with a small open source lib.  Sorta as it was good enough for me at the time.  That was also a few XCode revisions ago.

    If the the makefile is building an open source program or lib I have to wonder if it is even a good idea to turn it into an XCode project.  Each revision would be a integration problem.  If it is internal or something you control that is a different matter.  Basically you will need to duplicate the makefiles build steps within XCode.

    Unfortunately this stuff just doesn't jump out at you in XCode so you have to learn about the various project settings that impact the build of a project.

    On Apr 15, 2013, at 4:38 PM, Paul Johnson <paul...> wrote:

    > Thanks, Andrew. I'll look at just using the makefile. However, theoretically it should be easy to just do the compile/link without resorting to make. It just seems more aesthetically pleasing to not have to mess with additional tools unnecessarily.
    >
    >
    > On Sun, Apr 14, 2013 at 10:37 PM, Paul Johnson <paul...> wrote:
    > I have a makefile that successfully compiles and links without error, and I'm trying to accomplish the same thing by using the proper Build Settings in Xcode. So far I've been unsuccessful. Can this forum be used to help me with solve this problem?
    >
    > _______________________________________________
    > Do not post admin requests to the list. They will be ignored.
    > Xcode-users mailing list      (<Xcode-users...>)
    > Help/Unsubscribe/Update your Subscription:
    > https://lists.apple.com/mailman/options/xcode-users/<websterindustro...>
    om

    >
    > This email sent to <websterindustro...>
previous month april 2013 next month
MTWTFSS
1 2 3 4 5 6 7
8 9 10 11 12 13 14
15 16 17 18 19 20 21
22 23 24 25 26 27 28
29 30          
Go to today