Can I build from source using just the PKGBUILD file, or do I have to checkout the whole source tree?

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP












0















I want to build Vim from source in Arch Linux to get various non-standard features in the resulting binary. I notice that the PKGBUILD file has URLs in it. Does this mean I can do the build with just this file?



$ asp export vim
(modify PKGBUILD as needed)
$ sudo makepkg


...or do I need to checkout the whole source tree?










share|improve this question


























    0















    I want to build Vim from source in Arch Linux to get various non-standard features in the resulting binary. I notice that the PKGBUILD file has URLs in it. Does this mean I can do the build with just this file?



    $ asp export vim
    (modify PKGBUILD as needed)
    $ sudo makepkg


    ...or do I need to checkout the whole source tree?










    share|improve this question
























      0












      0








      0








      I want to build Vim from source in Arch Linux to get various non-standard features in the resulting binary. I notice that the PKGBUILD file has URLs in it. Does this mean I can do the build with just this file?



      $ asp export vim
      (modify PKGBUILD as needed)
      $ sudo makepkg


      ...or do I need to checkout the whole source tree?










      share|improve this question














      I want to build Vim from source in Arch Linux to get various non-standard features in the resulting binary. I notice that the PKGBUILD file has URLs in it. Does this mean I can do the build with just this file?



      $ asp export vim
      (modify PKGBUILD as needed)
      $ sudo makepkg


      ...or do I need to checkout the whole source tree?







      arch-linux compiling pkgbuild






      share|improve this question













      share|improve this question











      share|improve this question




      share|improve this question










      asked Jan 7 at 9:52









      Tyler DurdenTyler Durden

      1,59242050




      1,59242050




















          2 Answers
          2






          active

          oldest

          votes


















          0














          Yes. PKGBUILD file is enough for makepkg to build a package. But url= parameter is not the one that holds the sources location. It is the source= parameter.



          • PKGBUILD Wiki - source


          An array of files needed to build the package. It must contain the
          location of the software source, which in most cases is a full HTTP or
          FTP URL. The previously set variables pkgname and pkgver can be used
          effectively here; e.g.
          source=("https://example.com/$pkgname-$pkgver.tar.gz").



          Files can also be supplied in the same directory where the PKGBUILD is
          located, and their names added to this array. Before the actual build
          process starts, all the files referenced in this array will be
          downloaded or checked for existence, and makepkg will not proceed if
          any is missing.



          .install files are recognized automatically by makepkg and should not
          be included in the source array. Files in the source array with
          extensions .sig, .sign, or .asc are recognized by makepkg as PGP
          signatures and will be automatically used to verify the integrity of
          the corresponding source file.




          The url parameter is just the upstream package site.



          As an exampke, take a look at the vim-git package from AUR and it's PKGBUILD file. This AUR package will be built based on git tree for those who need bleeding-edge features.






          share|improve this answer

























          • When I use the command "asp export vim-git" I get the error "unknown package: vim-git"

            – Tyler Durden
            Jan 11 at 4:19











          • That's because asp is a tool to customize/build packages that are on Arch Linux repos, not on AUR. If you want to build from AUR, you will need to use another method - wiki.archlinux.org/index.php/… - I used vim-git from AUR as an example and because it's easier to see its PKGBUILD from web.

            – nwildner
            Jan 11 at 9:44



















          0














          With asp, you have two options, both documented in the man page. The first is to just grab the build files: export:




          export TARGET...

          Dump the build source files for each target into a directory of the target’s name in $PWD. Targets can be specified
          simply as package to check
          out the source files at HEAD, or in repository/package format to checkout the source files which were used to push the
          package which exists in
          repository.




          And checkout also acquires the build files but initialises a git repository in the process.




          checkout TARGET...

          Create a new git repository containing the full source and history for each of the given targets. The new repository will pull
          from the
          repository in $ASPROOT and must be updated separately after using asp update. If a checkout occurs on the same filesystem as
          $ASPROOT, most of
          the metadata can be hard linked, making this a relatively cheap copy.







          share|improve this answer






















            Your Answer








            StackExchange.ready(function()
            var channelOptions =
            tags: "".split(" "),
            id: "106"
            ;
            initTagRenderer("".split(" "), "".split(" "), channelOptions);

            StackExchange.using("externalEditor", function()
            // Have to fire editor after snippets, if snippets enabled
            if (StackExchange.settings.snippets.snippetsEnabled)
            StackExchange.using("snippets", function()
            createEditor();
            );

            else
            createEditor();

            );

            function createEditor()
            StackExchange.prepareEditor(
            heartbeatType: 'answer',
            autoActivateHeartbeat: false,
            convertImagesToLinks: false,
            noModals: true,
            showLowRepImageUploadWarning: true,
            reputationToPostImages: null,
            bindNavPrevention: true,
            postfix: "",
            imageUploader:
            brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
            contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
            allowUrls: true
            ,
            onDemand: true,
            discardSelector: ".discard-answer"
            ,immediatelyShowMarkdownHelp:true
            );



            );













            draft saved

            draft discarded


















            StackExchange.ready(
            function ()
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f492958%2fcan-i-build-from-source-using-just-the-pkgbuild-file-or-do-i-have-to-checkout-t%23new-answer', 'question_page');

            );

            Post as a guest















            Required, but never shown

























            2 Answers
            2






            active

            oldest

            votes








            2 Answers
            2






            active

            oldest

            votes









            active

            oldest

            votes






            active

            oldest

            votes









            0














            Yes. PKGBUILD file is enough for makepkg to build a package. But url= parameter is not the one that holds the sources location. It is the source= parameter.



            • PKGBUILD Wiki - source


            An array of files needed to build the package. It must contain the
            location of the software source, which in most cases is a full HTTP or
            FTP URL. The previously set variables pkgname and pkgver can be used
            effectively here; e.g.
            source=("https://example.com/$pkgname-$pkgver.tar.gz").



            Files can also be supplied in the same directory where the PKGBUILD is
            located, and their names added to this array. Before the actual build
            process starts, all the files referenced in this array will be
            downloaded or checked for existence, and makepkg will not proceed if
            any is missing.



            .install files are recognized automatically by makepkg and should not
            be included in the source array. Files in the source array with
            extensions .sig, .sign, or .asc are recognized by makepkg as PGP
            signatures and will be automatically used to verify the integrity of
            the corresponding source file.




            The url parameter is just the upstream package site.



            As an exampke, take a look at the vim-git package from AUR and it's PKGBUILD file. This AUR package will be built based on git tree for those who need bleeding-edge features.






            share|improve this answer

























            • When I use the command "asp export vim-git" I get the error "unknown package: vim-git"

              – Tyler Durden
              Jan 11 at 4:19











            • That's because asp is a tool to customize/build packages that are on Arch Linux repos, not on AUR. If you want to build from AUR, you will need to use another method - wiki.archlinux.org/index.php/… - I used vim-git from AUR as an example and because it's easier to see its PKGBUILD from web.

              – nwildner
              Jan 11 at 9:44
















            0














            Yes. PKGBUILD file is enough for makepkg to build a package. But url= parameter is not the one that holds the sources location. It is the source= parameter.



            • PKGBUILD Wiki - source


            An array of files needed to build the package. It must contain the
            location of the software source, which in most cases is a full HTTP or
            FTP URL. The previously set variables pkgname and pkgver can be used
            effectively here; e.g.
            source=("https://example.com/$pkgname-$pkgver.tar.gz").



            Files can also be supplied in the same directory where the PKGBUILD is
            located, and their names added to this array. Before the actual build
            process starts, all the files referenced in this array will be
            downloaded or checked for existence, and makepkg will not proceed if
            any is missing.



            .install files are recognized automatically by makepkg and should not
            be included in the source array. Files in the source array with
            extensions .sig, .sign, or .asc are recognized by makepkg as PGP
            signatures and will be automatically used to verify the integrity of
            the corresponding source file.




            The url parameter is just the upstream package site.



            As an exampke, take a look at the vim-git package from AUR and it's PKGBUILD file. This AUR package will be built based on git tree for those who need bleeding-edge features.






            share|improve this answer

























            • When I use the command "asp export vim-git" I get the error "unknown package: vim-git"

              – Tyler Durden
              Jan 11 at 4:19











            • That's because asp is a tool to customize/build packages that are on Arch Linux repos, not on AUR. If you want to build from AUR, you will need to use another method - wiki.archlinux.org/index.php/… - I used vim-git from AUR as an example and because it's easier to see its PKGBUILD from web.

              – nwildner
              Jan 11 at 9:44














            0












            0








            0







            Yes. PKGBUILD file is enough for makepkg to build a package. But url= parameter is not the one that holds the sources location. It is the source= parameter.



            • PKGBUILD Wiki - source


            An array of files needed to build the package. It must contain the
            location of the software source, which in most cases is a full HTTP or
            FTP URL. The previously set variables pkgname and pkgver can be used
            effectively here; e.g.
            source=("https://example.com/$pkgname-$pkgver.tar.gz").



            Files can also be supplied in the same directory where the PKGBUILD is
            located, and their names added to this array. Before the actual build
            process starts, all the files referenced in this array will be
            downloaded or checked for existence, and makepkg will not proceed if
            any is missing.



            .install files are recognized automatically by makepkg and should not
            be included in the source array. Files in the source array with
            extensions .sig, .sign, or .asc are recognized by makepkg as PGP
            signatures and will be automatically used to verify the integrity of
            the corresponding source file.




            The url parameter is just the upstream package site.



            As an exampke, take a look at the vim-git package from AUR and it's PKGBUILD file. This AUR package will be built based on git tree for those who need bleeding-edge features.






            share|improve this answer















            Yes. PKGBUILD file is enough for makepkg to build a package. But url= parameter is not the one that holds the sources location. It is the source= parameter.



            • PKGBUILD Wiki - source


            An array of files needed to build the package. It must contain the
            location of the software source, which in most cases is a full HTTP or
            FTP URL. The previously set variables pkgname and pkgver can be used
            effectively here; e.g.
            source=("https://example.com/$pkgname-$pkgver.tar.gz").



            Files can also be supplied in the same directory where the PKGBUILD is
            located, and their names added to this array. Before the actual build
            process starts, all the files referenced in this array will be
            downloaded or checked for existence, and makepkg will not proceed if
            any is missing.



            .install files are recognized automatically by makepkg and should not
            be included in the source array. Files in the source array with
            extensions .sig, .sign, or .asc are recognized by makepkg as PGP
            signatures and will be automatically used to verify the integrity of
            the corresponding source file.




            The url parameter is just the upstream package site.



            As an exampke, take a look at the vim-git package from AUR and it's PKGBUILD file. This AUR package will be built based on git tree for those who need bleeding-edge features.







            share|improve this answer














            share|improve this answer



            share|improve this answer








            edited Jan 7 at 12:37

























            answered Jan 7 at 12:29









            nwildnernwildner

            14.2k14176




            14.2k14176












            • When I use the command "asp export vim-git" I get the error "unknown package: vim-git"

              – Tyler Durden
              Jan 11 at 4:19











            • That's because asp is a tool to customize/build packages that are on Arch Linux repos, not on AUR. If you want to build from AUR, you will need to use another method - wiki.archlinux.org/index.php/… - I used vim-git from AUR as an example and because it's easier to see its PKGBUILD from web.

              – nwildner
              Jan 11 at 9:44


















            • When I use the command "asp export vim-git" I get the error "unknown package: vim-git"

              – Tyler Durden
              Jan 11 at 4:19











            • That's because asp is a tool to customize/build packages that are on Arch Linux repos, not on AUR. If you want to build from AUR, you will need to use another method - wiki.archlinux.org/index.php/… - I used vim-git from AUR as an example and because it's easier to see its PKGBUILD from web.

              – nwildner
              Jan 11 at 9:44

















            When I use the command "asp export vim-git" I get the error "unknown package: vim-git"

            – Tyler Durden
            Jan 11 at 4:19





            When I use the command "asp export vim-git" I get the error "unknown package: vim-git"

            – Tyler Durden
            Jan 11 at 4:19













            That's because asp is a tool to customize/build packages that are on Arch Linux repos, not on AUR. If you want to build from AUR, you will need to use another method - wiki.archlinux.org/index.php/… - I used vim-git from AUR as an example and because it's easier to see its PKGBUILD from web.

            – nwildner
            Jan 11 at 9:44






            That's because asp is a tool to customize/build packages that are on Arch Linux repos, not on AUR. If you want to build from AUR, you will need to use another method - wiki.archlinux.org/index.php/… - I used vim-git from AUR as an example and because it's easier to see its PKGBUILD from web.

            – nwildner
            Jan 11 at 9:44














            0














            With asp, you have two options, both documented in the man page. The first is to just grab the build files: export:




            export TARGET...

            Dump the build source files for each target into a directory of the target’s name in $PWD. Targets can be specified
            simply as package to check
            out the source files at HEAD, or in repository/package format to checkout the source files which were used to push the
            package which exists in
            repository.




            And checkout also acquires the build files but initialises a git repository in the process.




            checkout TARGET...

            Create a new git repository containing the full source and history for each of the given targets. The new repository will pull
            from the
            repository in $ASPROOT and must be updated separately after using asp update. If a checkout occurs on the same filesystem as
            $ASPROOT, most of
            the metadata can be hard linked, making this a relatively cheap copy.







            share|improve this answer



























              0














              With asp, you have two options, both documented in the man page. The first is to just grab the build files: export:




              export TARGET...

              Dump the build source files for each target into a directory of the target’s name in $PWD. Targets can be specified
              simply as package to check
              out the source files at HEAD, or in repository/package format to checkout the source files which were used to push the
              package which exists in
              repository.




              And checkout also acquires the build files but initialises a git repository in the process.




              checkout TARGET...

              Create a new git repository containing the full source and history for each of the given targets. The new repository will pull
              from the
              repository in $ASPROOT and must be updated separately after using asp update. If a checkout occurs on the same filesystem as
              $ASPROOT, most of
              the metadata can be hard linked, making this a relatively cheap copy.







              share|improve this answer

























                0












                0








                0







                With asp, you have two options, both documented in the man page. The first is to just grab the build files: export:




                export TARGET...

                Dump the build source files for each target into a directory of the target’s name in $PWD. Targets can be specified
                simply as package to check
                out the source files at HEAD, or in repository/package format to checkout the source files which were used to push the
                package which exists in
                repository.




                And checkout also acquires the build files but initialises a git repository in the process.




                checkout TARGET...

                Create a new git repository containing the full source and history for each of the given targets. The new repository will pull
                from the
                repository in $ASPROOT and must be updated separately after using asp update. If a checkout occurs on the same filesystem as
                $ASPROOT, most of
                the metadata can be hard linked, making this a relatively cheap copy.







                share|improve this answer













                With asp, you have two options, both documented in the man page. The first is to just grab the build files: export:




                export TARGET...

                Dump the build source files for each target into a directory of the target’s name in $PWD. Targets can be specified
                simply as package to check
                out the source files at HEAD, or in repository/package format to checkout the source files which were used to push the
                package which exists in
                repository.




                And checkout also acquires the build files but initialises a git repository in the process.




                checkout TARGET...

                Create a new git repository containing the full source and history for each of the given targets. The new repository will pull
                from the
                repository in $ASPROOT and must be updated separately after using asp update. If a checkout occurs on the same filesystem as
                $ASPROOT, most of
                the metadata can be hard linked, making this a relatively cheap copy.








                share|improve this answer












                share|improve this answer



                share|improve this answer










                answered Jan 7 at 18:20









                jasonwryanjasonwryan

                49.6k14134185




                49.6k14134185



























                    draft saved

                    draft discarded
















































                    Thanks for contributing an answer to Unix & Linux Stack Exchange!


                    • Please be sure to answer the question. Provide details and share your research!

                    But avoid


                    • Asking for help, clarification, or responding to other answers.

                    • Making statements based on opinion; back them up with references or personal experience.

                    To learn more, see our tips on writing great answers.




                    draft saved


                    draft discarded














                    StackExchange.ready(
                    function ()
                    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f492958%2fcan-i-build-from-source-using-just-the-pkgbuild-file-or-do-i-have-to-checkout-t%23new-answer', 'question_page');

                    );

                    Post as a guest















                    Required, but never shown





















































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown

































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown






                    Popular posts from this blog

                    How to check contact read email or not when send email to Individual?

                    Bahrain

                    Postfix configuration issue with fips on centos 7; mailgun relay